public abstract class DefaultLogger extends Object implements Logger
| Constructor and Description |
|---|
DefaultLogger(Channel threshold) |
| Modifier and Type | Method and Description |
|---|---|
Logger |
exception(Channel channel,
Throwable throwable)
Log the given exception to the given channel
|
Logger |
getLogger()
Get stored logger
|
protected abstract void |
internalLog(Channel channel,
String message)
Internal method used by
DefaultLogger to send processed message to the final implementation. |
Logger |
log(Channel channel,
String message,
Object... arguments)
Log the given message to the provided channel
|
Logger |
setThreshold(Channel threshold)
Modify current threshold
|
PrintStream |
toPrintStream(Channel channel)
Create PrintStream that will write to the current logger.
|
protected Channel threshold
public DefaultLogger(Channel threshold)
protected abstract void internalLog(Channel channel, String message)
DefaultLogger to send processed message to the final implementation.channel - the channel to log tomessage - the message to logpublic Logger log(Channel channel, String message, Object... arguments)
Loggerpublic Logger exception(Channel channel, Throwable throwable)
Loggerpublic Logger setThreshold(Channel threshold)
LoggersetThreshold in interface Loggerthreshold - the threshold to setpublic PrintStream toPrintStream(Channel channel)
LoggertoPrintStream in interface Loggerpublic Logger getLogger()
JournalistgetLogger in interface JournalistCopyright © 2021. All rights reserved.