English | 简体中文

api-docs / org.ktorm.logging / ConsoleLogger

ConsoleLogger

class ConsoleLogger : Logger (source code)

Simple Logger implementation printing logs to the console. While messages at WARN or ERROR levels are printed to
System.err, others are printed to System.out.

Constructors

NameSummary

<init>

ConsoleLogger(threshold: LogLevel)

Simple Logger implementation printing logs to the console. While messages at WARN or ERROR levels are printed to
System.err, others are printed to System.out.

Properties

NameSummary

threshold

val threshold: LogLevel

a threshold controlling which log levels are enabled.

Functions

NameSummary

debug

fun debug(msg: String, e: Throwable?): Unit

Log a message at the DEBUG level.

error

fun error(msg: String, e: Throwable?): Unit

Log a message at the ERROR level.

info

fun info(msg: String, e: Throwable?): Unit

Log a message at the INFO level.

isDebugEnabled

fun isDebugEnabled(): Boolean

Check if the logger instance enabled for the DEBUG level.

isErrorEnabled

fun isErrorEnabled(): Boolean

Check if the logger instance enabled for the ERROR level.

isInfoEnabled

fun isInfoEnabled(): Boolean

Check if the logger instance enabled for the INFO level.

isTraceEnabled

fun isTraceEnabled(): Boolean

Check if the logger instance enabled for the TRACE level.

isWarnEnabled

fun isWarnEnabled(): Boolean

Check if the logger instance enabled for the WARN level.

trace

fun trace(msg: String, e: Throwable?): Unit

Log a message at the TRACE level.

warn

fun warn(msg: String, e: Throwable?): Unit

Log a message at the WARN level.

Extension Functions

NameSummary

eq

infix fun <T : Any> T.eq(
    expr: ColumnDeclaring<T>
): BinaryExpression<Boolean>

Equal operator, translated to = in SQL.

neq

infix fun <T : Any> T.neq(
    expr: ColumnDeclaring<T>
): BinaryExpression<Boolean>

Not-equal operator, translated to <> in SQL.

notEq

infix fun <T : Any> T.notEq(
    expr: ColumnDeclaring<T>
): BinaryExpression<Boolean>

Not-equal operator, translated to <> in SQL.