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

com.github.yoojia.web.LoggerModule.kt Maven / Gradle / Ivy

There is a newer version: 3.0.5-alpha
Show newest version
package com.github.yoojia.web

import com.github.yoojia.web.core.Module
import java.text.SimpleDateFormat

/**
 * @author Yoojia Chen ([email protected])
 * @since 1.0
 */
abstract class LoggerModule : Module{

    companion object {

        internal val LOGGING_TEXT_NAME = ""
        internal val LOGGING_ENABLED_NAME = ""
        internal val FORMATTER = SimpleDateFormat("yyyy-MM-dd HH:mm:ss:SSS")

        internal fun addLine(name: String, value: Any, buff: StringBuilder) {
            buff.append(name).append(": ").append(value).append("\r\n")
        }

        internal fun addSubLine(name: String, value: Any, buff: StringBuilder) {
            buff.append("    ").append(name).append(": ").append(value).append("\r\n")
        }
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy