DefaultUmamiLogger

class DefaultUmamiLogger(logger: Logger = Logger.withTag("Umami")) : UmamiLogger

A default, internal implementation of UmamiLogger that leverages the Kermit logging library.

This class acts as an adapter, translating calls from the UmamiLogger interface into the corresponding methods of a co.touchlab.kermit.Logger instance. It provides a ready-to-use logging solution for the Umami library, abstracting the underlying logging framework.

Constructors

Link copied to clipboard
constructor(logger: Logger = Logger.withTag("Umami"))

Functions

Link copied to clipboard
open override fun debug(message: String)

Logs a debug message by delegating to the underlying Kermit logger's d method.

Link copied to clipboard
open override fun error(message: String, throwable: Throwable? = null)

Logs an error message by delegating to the underlying Kermit logger's e method.

Link copied to clipboard
open override fun info(message: String)

Logs an informational message by delegating to the underlying Kermit logger's i method.

Link copied to clipboard
open override fun log(severity: UmamiLogger.Severity, message: String, throwable: Throwable? = null)

The core logging function that maps UmamiLogger.Severity to the appropriate method in the underlying Kermit logger.

Link copied to clipboard
open override fun verbose(message: String)

Logs a verbose message by delegating to the underlying Kermit logger's v method.

Link copied to clipboard
open override fun warn(message: String, throwable: Throwable? = null)

Logs a warning message by delegating to the underlying Kermit logger's w method.