forked from johncfranco/reactive-logger
-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add LoggerFactory and set to ContextView where not need Context
- Loading branch information
Showing
14 changed files
with
1,679 additions
and
1,373 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
version=2.0.0-RC0 | ||
version=2.0.0-RC1 | ||
group=io.github.numichi | ||
developerId=numichi | ||
developerName=Donát Csongor | ||
|
14 changes: 14 additions & 0 deletions
14
src/main/java/io/github/numichi/reactive/logger/LoggerFactory.kt
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
package io.github.numichi.reactive.logger | ||
|
||
import mu.KotlinLogging | ||
import org.slf4j.Logger | ||
|
||
object LoggerFactory { | ||
fun getLogger(string: String) = org.slf4j.LoggerFactory.getLogger(string) | ||
fun getLogger(clazz: Class<*>) = org.slf4j.LoggerFactory.getLogger(clazz) | ||
|
||
fun getKLogger(string: String) = KotlinLogging.logger(string) | ||
fun getKLogger(logger: Logger) = KotlinLogging.logger(logger) | ||
fun getKLogger(clazz: Class<*>) = KotlinLogging.logger(org.slf4j.LoggerFactory.getLogger(clazz)) | ||
fun getKLogger(func: () -> Unit) = KotlinLogging.logger(func) | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.