- java.lang.Object
-
- org.eclipse.jetty.logging.JettyLoggerFactory
-
- All Implemented Interfaces:
org.slf4j.ILoggerFactory
public class JettyLoggerFactory extends java.lang.Object implements org.slf4j.ILoggerFactory
-
-
Constructor Summary
Constructors Constructor Description JettyLoggerFactory(JettyLoggerConfiguration config)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description protected static java.lang.StringcondensePackageString(java.lang.String classname)Condenses a classname by stripping down the package name to just the first character of each package name segment.ConfiguredJettyLoggergetJettyLogger(java.lang.String name)Get aJettyLoggerinstance, creating if not yet existing.org.slf4j.LoggergetLogger(java.lang.String name)Main interface forILoggerFactoryJettyLoggergetRootLogger()protected voidwalkChildLoggers(java.lang.String parentName, java.util.function.Consumer<JettyLogger> childConsumer)
-
-
-
Constructor Detail
-
JettyLoggerFactory
public JettyLoggerFactory(JettyLoggerConfiguration config)
-
-
Method Detail
-
getJettyLogger
public JettyLogger getJettyLogger(java.lang.String name)
Get aJettyLoggerinstance, creating if not yet existing.- Parameters:
name- the name of the logger- Returns:
- the JettyLogger instance
-
getLogger
public org.slf4j.Logger getLogger(java.lang.String name)
Main interface forILoggerFactory- Specified by:
getLoggerin interfaceorg.slf4j.ILoggerFactory- Parameters:
name- the name of the logger- Returns:
- the Slf4j Logger
-
walkChildLoggers
protected void walkChildLoggers(java.lang.String parentName, java.util.function.Consumer<JettyLogger> childConsumer)
-
getRootLogger
public JettyLogger getRootLogger()
-
condensePackageString
protected static java.lang.String condensePackageString(java.lang.String classname)
Condenses a classname by stripping down the package name to just the first character of each package name segment.ConfiguredExamples: "org.eclipse.jetty.test.FooTest" = "oejt.FooTest" "org.eclipse.jetty.server.logging.LogTest" = "orjsl.LogTest"
- Parameters:
classname- the fully qualified class name- Returns:
- the condensed name
-
-