generate kdocs

This commit is contained in:
2025-11-12 13:45:57 +06:00
parent 3c4e59ddc2
commit 7f92a3e614
16 changed files with 510 additions and 40 deletions

View File

@@ -2,6 +2,21 @@ package dev.inmo.kslog.common
import android.util.Log
/**
* Android platform implementation of the default logger
*
* Uses Android's `[android.util.Log]` as the logging backend, mapping KSLog levels
* to Android log levels:
* - [LogLevel.TRACE] → [Log.d] (debug)
* - [LogLevel.DEBUG] → [Log.d] (debug)
* - [LogLevel.VERBOSE] → [Log.v] (verbose)
* - [LogLevel.INFO] → [Log.i] (info)
* - [LogLevel.WARNING] → [Log.w] (warning)
* - [LogLevel.ERROR] → [Log.e] (error)
* - [LogLevel.ASSERT] → [Log.wtf] (what a terrible failure)
*
* Logs can be viewed using `adb logcat` or Android Studio's Logcat window.
*/
actual var KSLoggerDefaultPlatformLoggerLambda: (level: LogLevel, tag: String, message: Any, throwable: Throwable?) -> Unit = { l, t, m, e ->
val messageString = m.toString()
when(l) {