All Downloads are FREE. Search and download functionalities are using the official Maven repository.

commonTest.com.toxicbakery.logging.TestSeedling.kt Maven / Gradle / Ivy

There is a newer version: 1.40.86
Show newest version
package com.toxicbakery.logging

data class TestSeedling(
    override val tag: String = ""
) : ISeedling {

    private val logBuffer: StringBuilder = StringBuilder()

    val log: String
        get() = logBuffer.toString()

    override fun log(
        level: Int,
        tag: String,
        msg: String,
        throwable: Throwable?,
        args: Array?
    ) {
        val exceptionString = throwable?.message?.let { " $it" } ?: ""
        logBuffer.append("$level $tag $msg$exceptionString")
    }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy