Package de.mhus.lib.logging
Class Log4JFactory
- java.lang.Object
-
- de.mhus.lib.core.logging.LogFactory
-
- de.mhus.lib.logging.Log4JFactory
-
- All Implemented Interfaces:
IBase
public final class Log4JFactory extends LogFactory
Concrete subclass of
LogFactoryspecific to log4j.- Author:
- Costin Manolache
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description classLog4JFactory.Log4JLog
-
Field Summary
-
Fields inherited from class de.mhus.lib.core.logging.LogFactory
level, levelMapper
-
-
Constructor Summary
Constructors Constructor Description Log4JFactory()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LogEnginecreateInstance(String name)Convenience method to derive a name from the specified class and callgetInstance(String)with it.voidinit(ResourceNode<?> config)-
Methods inherited from class de.mhus.lib.core.logging.LogFactory
getDefaultLevel, getInstance, getInstance, getLevelMapper, getLog, getMaxMessageSize, getParameterMapper, init, setDefaultLevel, setLevelMapper, setMaxMessageSize, setParameterMapper
-
-
-
-
Method Detail
-
init
public void init(ResourceNode<?> config) throws Exception
- Specified by:
initin classLogFactory- Throws:
Exception
-
createInstance
public LogEngine createInstance(String name)
Convenience method to derive a name from the specified class and callgetInstance(String)with it.- Specified by:
createInstancein classLogFactory- Parameters:
name- Class for which a suitable Log name will be derived- Returns:
- the log engine
- Throws:
org.apache.commons.logging.LogConfigurationException- if a suitableLoginstance cannot be returned
-
-