struct LogRecord
source · line 30public
public struct LogRecord(val level: LogLevel, val target: String, val message: String, val location: SourceLocation, val cause: Throwable? = None, val messageFailure: Throwable? = None)
An evaluated log event. Exception fields retain their original objects; they are not deep snapshots of mutable exception state.
field target
source · line 34public
val target: String
The caller-selected category.
field level
source · line 32public
val level: LogLevel
The requested event severity, including when message evaluation fails.
field cause
source · line 40public
val cause: Throwable? = None
An optional application exception supplied by the caller.
field messageFailure
source · line 42public
val messageFailure: Throwable? = None
The original exception thrown by the message function, if any.
constructor constructor
source · line 30public
constructor(val level: LogLevel, val target: String, val message: String, val location: SourceLocation, val cause: Throwable? = None, val messageFailure: Throwable? = None)
parameter level
source · line 32public
val level: LogLevel
parameter messageFailure
source · line 42public
val messageFailure: Throwable? = None
parameter target
source · line 34public
val target: String
parameter message
source · line 36public
val message: String
parameter location
source · line 38public
val location: SourceLocation
parameter cause
source · line 40public
val cause: Throwable? = None
field message
source · line 36public
val message: String
The evaluated message or a message-evaluation failure description.
field location
source · line 38public
val location: SourceLocation
The original logging call's source location.
function equals
source · line 30publiccompiler-derived
operator fun equals(other: LogRecord): Boolean
This derived operation is available when each field or payload type supports same-type equality. Required types: LogLevel, String, SourceLocation, Option<Throwable>.