public class Provider extends Object
META-INF/log4j-provider.properties file. Note that this class is automatically created by Log4j and should not be used by providers.
| Modifier and Type | Field and Description |
|---|---|
static String |
FACTORY_PRIORITY
Property name to set for a Log4j 2 provider to specify the priority of this implementation.
|
static String |
LOGGER_CONTEXT_FACTORY
Property name to set to the implementation of
LoggerContextFactory.
|
static String |
THREAD_CONTEXT_MAP
Property name to set to the implementation of
ThreadContextMap.
|
| Constructor and Description |
|---|
Provider(Properties
|
| Modifier and Type | Method and Description |
|---|---|
String |
getClassName()
Gets the class name of the
LoggerContextFactory implementation of this Provider.
|
Integer |
getPriority()
Gets the priority (natural ordering) of this Provider.
|
String |
getThreadContextMap()
Gets the class name of the
ThreadContextMap implementation of this Provider.
|
URL |
getUrl()
Gets the URL containing this Provider's Log4j details.
|
Class |
loadLoggerContextFactory()
Loads the
LoggerContextFactory class specified by this Provider.
|
Class |
loadThreadContextMap()
Loads the
ThreadContextMap class specified by this Provider.
|
String |
toString()
|
public static final StringFACTORY_PRIORITY
public static final StringTHREAD_CONTEXT_MAP
ThreadContextMap.
public static final StringLOGGER_CONTEXT_FACTORY
LoggerContextFactory.
public Provider(Propertiesprops, URL url, ClassLoader classLoader)
public IntegergetPriority()
public StringgetClassName()
LoggerContextFactory implementation of this Provider.
public Class<? extends LoggerContextFactory > loadLoggerContextFactory()
LoggerContextFactory class specified by this Provider.
null if there was an error loading it
public StringgetThreadContextMap()
ThreadContextMap implementation of this Provider.
public Class<? extends ThreadContextMap > loadThreadContextMap()
ThreadContextMap class specified by this Provider.
null if there was an error loading it
public URLgetUrl()
META-INF/log4j-provider.properties file
public StringtoString()