de.uniba.wiai.lspi.util.logging
Class Log4jLogger

java.lang.Object
  extended by de.uniba.wiai.lspi.util.logging.Logger
      extended by de.uniba.wiai.lspi.util.logging.Log4jLogger
All Implemented Interfaces:
java.io.Serializable

public class Log4jLogger
extends Logger

This is the standard logger for this framework. It uses log4j for logging.
To configure this logger you have to set the system property log4j.properties.file that points to a file containing log4j properties. See log4j manual for details. If the file cannot be found logging is set to ON for all classes.

Version:
1.0.5
Author:
sven
See Also:
Serialized Form

Nested Class Summary
 
Nested classes/interfaces inherited from class de.uniba.wiai.lspi.util.logging.Logger
Logger.LogLevel
 
Field Summary
static java.lang.String PROPERTIES_FILE_PROPERTY
          Name of property to set the reference to the property file containing log4j properties.
 
Fields inherited from class de.uniba.wiai.lspi.util.logging.Logger
LOGGER_CLASS_NAME_PROPERTY_NAME, LOGGING_OFF_PROPERTY_NAME
 
Constructor Summary
Log4jLogger(java.lang.String _class)
          Creates a new instance of Log4JLogger
 
Method Summary
 void debug(java.lang.Object msg)
           
 void debug(java.lang.Object msg, java.lang.Throwable t)
           
 void error(java.lang.Object msg)
           
 void error(java.lang.Object msg, java.lang.Throwable t)
           
 void fatal(java.lang.Object msg)
           
 void fatal(java.lang.Object msg, java.lang.Throwable t)
           
 void info(java.lang.Object msg)
           
 void info(java.lang.Object msg, java.lang.Throwable t)
           
 boolean isEnabledFor(Logger.LogLevel l)
           
 void warn(java.lang.Object msg)
           
 void warn(java.lang.Object msg, java.lang.Throwable t)
           
 
Methods inherited from class de.uniba.wiai.lspi.util.logging.Logger
getLogger, getLogger
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PROPERTIES_FILE_PROPERTY

public static final java.lang.String PROPERTIES_FILE_PROPERTY
Name of property to set the reference to the property file containing log4j properties.

See Also:
Constant Field Values
Constructor Detail

Log4jLogger

public Log4jLogger(java.lang.String _class)
Creates a new instance of Log4JLogger

Parameters:
_class -
Method Detail

debug

public void debug(java.lang.Object msg)
Specified by:
debug in class Logger

debug

public void debug(java.lang.Object msg,
                  java.lang.Throwable t)
Specified by:
debug in class Logger

info

public void info(java.lang.Object msg)
Specified by:
info in class Logger

info

public void info(java.lang.Object msg,
                 java.lang.Throwable t)
Specified by:
info in class Logger

warn

public void warn(java.lang.Object msg)
Specified by:
warn in class Logger

warn

public void warn(java.lang.Object msg,
                 java.lang.Throwable t)
Specified by:
warn in class Logger

error

public void error(java.lang.Object msg)
Specified by:
error in class Logger

error

public void error(java.lang.Object msg,
                  java.lang.Throwable t)
Specified by:
error in class Logger

fatal

public void fatal(java.lang.Object msg)
Specified by:
fatal in class Logger

fatal

public void fatal(java.lang.Object msg,
                  java.lang.Throwable t)
Specified by:
fatal in class Logger

isEnabledFor

public boolean isEnabledFor(Logger.LogLevel l)
Specified by:
isEnabledFor in class Logger