|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--org.apache.avalon.framework.logger.AbstractLogEnabled
Utility class to allow construction of easy components that will perform logging.
Constructor Summary | |
AbstractLogEnabled()
|
Method Summary | |
void |
enableLogging(Logger logger)
Set the components logger. |
protected Logger |
getLogger()
Helper method to allow sub-classes to aquire logger. |
protected void |
setupLogger(Object component)
Helper method to setup other components with same logger. |
protected void |
setupLogger(Object component,
Logger logger)
Helper method to setup other components with logger. |
protected void |
setupLogger(Object component,
String subCategory)
Helper method to setup other components with logger. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public AbstractLogEnabled()
Method Detail |
public void enableLogging(Logger logger)
enableLogging
in interface LogEnabled
logger
- the loggerprotected final Logger getLogger()
There is no performance penalty as this is a final method and will be inlined by the JVM.
protected void setupLogger(Object component)
component
- the component to pass logger object toprotected void setupLogger(Object component, String subCategory)
component
- the component to pass logger object tosubCategory
- the subcategory to use (may be null)protected void setupLogger(Object component, Logger logger)
component
- the component to pass logger object tologger
- the Logger
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |