All Downloads are FREE. Search and download functionalities are using the official Maven repository.

logging.LoggerPort.kt Maven / Gradle / Ivy

The newest version!
package com.hexagonkt.logging

/**
 * A Logger is used to log messages for a specific system or application component.
 */
interface LoggerPort {

    /**
     * Log a message, with associated exception information.
     *
     * @param level One of the message level identifiers, e.g., TRACE.
     * @param exception The exception associated with log message.
     * @param message The required message to log.
     */
    fun  log(level: LoggingLevel, exception: E, message: (E) -> Any?)

    /**
     * Log a message.
     *
     * @param level One of the message level identifiers, e.g., TRACE.
     * @param message The required message to log.
     */
    fun log(level: LoggingLevel, message: () -> Any?)
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy