Home » SLF4J-1.5.8 » org.apache.commons » logging » impl » [javadoc | source]
org.apache.commons.logging.impl
public class: AvalonLogger [javadoc | source]
java.lang.Object
   org.apache.commons.logging.impl.AvalonLogger

All Implemented Interfaces:
    Log

Implementation of commons-logging Log interface that delegates all logging calls to the Avalon logging abstraction: the Logger interface.

There are two ways in which this class can be used:

Note: AvalonLogger does not implement Serializable because the constructors available for it make this impossible to achieve in all circumstances; there is no way to "reconnect" to an underlying Logger object on deserialization if one was just passed in to the constructor of the original object. This class was marked Serializable in the 1.0.4 release of commons-logging, but this never actually worked (a NullPointerException would be thrown as soon as the deserialized object was used), so removing this marker is not considered to be an incompatible change.

Constructor:
 public AvalonLogger(Logger logger) 
    Constructs an AvalonLogger that outputs to the given Logger instance.
    Parameters:
    logger - the avalon logger implementation to delegate to
 public AvalonLogger(String name) 
    Constructs an AvalonLogger that will log to a child of the Logger set by calling #setDefaultLogger .
    Parameters:
    name - the name of the avalon logger implementation to delegate to
Method from org.apache.commons.logging.impl.AvalonLogger Summary:
debug,   debug,   error,   error,   fatal,   fatal,   getLogger,   info,   info,   isDebugEnabled,   isErrorEnabled,   isFatalEnabled,   isInfoEnabled,   isTraceEnabled,   isWarnEnabled,   setDefaultLogger,   trace,   trace,   warn,   warn
Methods from java.lang.Object:
clone,   equals,   finalize,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.apache.commons.logging.impl.AvalonLogger Detail:
 public  void debug(Object message) 
    Logs a message with org.apache.avalon.framework.logger.Logger.debug.
 public  void debug(Object message,
    Throwable t) 
    Logs a message with org.apache.avalon.framework.logger.Logger.debug.
 public  void error(Object message) 
    Logs a message with org.apache.avalon.framework.logger.Logger.error.
 public  void error(Object message,
    Throwable t) 
    Logs a message with org.apache.avalon.framework.logger.Logger.error.
 public  void fatal(Object message) 
    Logs a message with org.apache.avalon.framework.logger.Logger.fatalError.
 public  void fatal(Object message,
    Throwable t) 
    Logs a message with org.apache.avalon.framework.logger.Logger.fatalError.
 public Logger getLogger() 
    Gets the Avalon logger implementation used to perform logging.
 public  void info(Object message) 
    Logs a message with org.apache.avalon.framework.logger.Logger.info.
 public  void info(Object message,
    Throwable t) 
    Logs a message with org.apache.avalon.framework.logger.Logger.info.
 public boolean isDebugEnabled() 
    Is logging to org.apache.avalon.framework.logger.Logger.debug enabled?
 public boolean isErrorEnabled() 
    Is logging to org.apache.avalon.framework.logger.Logger.error enabled?
 public boolean isFatalEnabled() 
    Is logging to org.apache.avalon.framework.logger.Logger.fatalError enabled?
 public boolean isInfoEnabled() 
    Is logging to org.apache.avalon.framework.logger.Logger.info enabled?
 public boolean isTraceEnabled() 
    Is logging to org.apache.avalon.framework.logger.Logger.debug enabled?
 public boolean isWarnEnabled() 
    Is logging to org.apache.avalon.framework.logger.Logger.warn enabled?
 public static  void setDefaultLogger(Logger logger) 
    Sets the ancesteral Avalon logger from which the delegating loggers will descend.
 public  void trace(Object message) 
    Logs a message with org.apache.avalon.framework.logger.Logger.debug.
 public  void trace(Object message,
    Throwable t) 
    Logs a message with org.apache.avalon.framework.logger.Logger.debug.
 public  void warn(Object message) 
    Logs a message with org.apache.avalon.framework.logger.Logger.warn.
 public  void warn(Object message,
    Throwable t) 
    Logs a message with org.apache.avalon.framework.logger.Logger.warn.