trace

open fun trace(message: () -> Any?)
open fun trace(throwable: Throwable?, message: () -> Any?)
open fun trace(throwable: Throwable?, marker: Marker?, message: () -> Any?)

Lazy add a log message if isTraceEnabled is true


open fun trace(marker: Marker?, msg: () -> Any?)

Deprecated

use trace instead

Replace with

trace(null, marker, msg)

open fun trace(marker: Marker?, t: Throwable?, msg: () -> Any?)

Deprecated

use trace instead

Replace with

trace(t, marker, msg)

open fun trace(msg: String?)

Deprecated

Use trace {} instead

Replace with

trace { "$msg"}

Log a message at the TRACE level.

Parameters

msg

the message string to be logged


open fun trace(msg: String?, arg: Any?)

Deprecated

Use trace {} instead

Replace with

trace { "$msg $arg"}

Log a message at the TRACE level according to the specified msg and argument.

This form avoids superfluous object creation when the logger is disabled for the TRACE level.

Parameters

msg

the msg string

arg

the argument


open fun trace(msg: String?, arg1: Any?, arg2: Any?)

Deprecated

Use trace {} instead

Replace with

trace { "$msg $arg1 $arg2"}

Log a message at the TRACE level according to the specified msg and arguments.

This form avoids superfluous object creation when the logger is disabled for the TRACE level.

Parameters

msg

the msg string

arg1

the first argument

arg2

the second argument


open fun trace(msg: String?, vararg arguments: Any?)

Deprecated

Use trace {} instead

Replace with

trace { "$msg $arguments"}

Log a message at the TRACE level according to the specified msg and arguments.

This form avoids superfluous string concatenation when the logger is disabled for the TRACE level. However, this variant incurs the hidden (and relatively small) cost of creating an Object[] before invoking the method, even if this logger is disabled for TRACE. The variants taking .trace and .trace arguments exist solely in order to avoid this hidden cost.

Parameters

msg

the msg string

arguments

a list of 3 or more arguments


open fun trace(msg: String?, t: Throwable?)

Deprecated

Use trace {} instead

Replace with

trace(t) { "$msg"}

Log an exception (throwable) at the TRACE level with an accompanying message.

Parameters

msg

the message accompanying the exception

t

the exception (throwable) to log


open fun trace(marker: Marker?, msg: String?)

Deprecated

Use trace {} instead

Replace with

trace(marker) { "$msg"}

Log a message with the specific Marker at the TRACE level.

Parameters

marker

the marker data specific to this log statement

msg

the message string to be logged


open fun trace(marker: Marker?, msg: String?, arg: Any?)

Deprecated

Use trace {} instead

Replace with

trace(marker) { "$msg $arg"}

This method is similar to .trace method except that the marker data is also taken into consideration.

Parameters

marker

the marker data specific to this log statement

msg

the msg string

arg

the argument


open fun trace(marker: Marker?, msg: String?, arg1: Any?, arg2: Any?)

Deprecated

Use trace {} instead

Replace with

trace(marker) { "$msg $arg1 $arg2"}

This method is similar to .trace method except that the marker data is also taken into consideration.

Parameters

marker

the marker data specific to this log statement

msg

the msg string

arg1

the first argument

arg2

the second argument


open fun trace(marker: Marker?, msg: String?, vararg arguments: Any?)

Deprecated

Use trace {} instead

Replace with

trace(marker) { "$msg $arguments"}

This method is similar to .trace method except that the marker data is also taken into consideration.

Parameters

marker

the marker data specific to this log statement

msg

the msg string

arguments

an array of arguments


open fun trace(marker: Marker?, msg: String?, t: Throwable?)

Deprecated

Use trace {} instead

Replace with

trace(t, marker) { "$msg"}

This method is similar to .trace method except that the marker data is also taken into consideration.

Parameters

marker

the marker data specific to this log statement

msg

the message accompanying the exception

t

the exception (throwable) to log