KSLog/src/commonMain/kotlin/CallbackKSLog.kt

10 lines
381 B
Kotlin
Raw Normal View History

2022-06-09 03:56:27 +00:00
package dev.inmo.kslog.common
2022-07-30 08:56:26 +00:00
typealias SimpleKSLogCallback = (level: LogLevel, tag: String?, message: Any, throwable: Throwable?) -> Unit
2022-06-09 03:56:27 +00:00
class CallbackKSLog(
2022-07-30 08:56:26 +00:00
private val performLogCallback: SimpleKSLogCallback
2022-06-09 03:56:27 +00:00
) : KSLog {
override fun performLog(level: LogLevel, tag: String?, message: Any, throwable: Throwable?) = performLogCallback(level, tag, message, throwable)
2022-06-09 03:56:27 +00:00
}