Logger

The Logs a message with the specified log level, tag, message, and optional throwable.

The Logs a message with the specified log level, tag, message, and optional throwable.

Syntax: open override fun log(level: LogLevel, tag: String?, msg: String?, tr: Throwable?)

Parameters

ParameterTypeDescription
levelLogLevelThe log level of the message.
tagStringThe tag for the log message.
msgStringThe log message.
trThrowableThe optional throwable is associated with the log message.

shouldLog

Check if the logger should log a message with the specified log level.

Syntax: open override fun shouldLog(level: LogLevel): Boolean

Return True if the logger should log the message, false otherwise.

Parameters

ParameterTypeDescription
levelLogLevelThe log level to check.