public static class LogBackUtil.LogBackConfigurator extends Object
| Constructor and Description |
|---|
LogBackConfigurator() |
| Modifier and Type | Method and Description |
|---|---|
static ch.qos.logback.classic.LoggerContext |
getLoggerContext() |
LogBackUtil.LogBackConfigurator |
ifNotInstalled()
Install the logger only if none has been installed before
|
void |
install()
Hijack the default java.util.Logger, remove all appenders and (re)install the new logback configuration
|
LogBackUtil.LogBackConfigurator |
withFormat(String format)
Set the format for this console appender
|
LogBackUtil.LogBackConfigurator |
withLevel(ch.qos.logback.classic.Level level)
Set the log level of the root logger
|
LogBackUtil.LogBackConfigurator |
withLoggers(String pattern,
ch.qos.logback.classic.Level level)
Set the log level for a specific logger (class or package)
|
public static ch.qos.logback.classic.LoggerContext getLoggerContext()
public LogBackUtil.LogBackConfigurator withLevel(ch.qos.logback.classic.Level level)
level - public LogBackUtil.LogBackConfigurator withLoggers(String pattern, ch.qos.logback.classic.Level level)
pattern - level - public LogBackUtil.LogBackConfigurator withFormat(String format)
format - public LogBackUtil.LogBackConfigurator ifNotInstalled()
public void install()
Copyright © 2016. All rights reserved.