org.sape.carbon.services.log.console
Class ConsoleLogger

java.lang.Object
  |
  +--org.sape.carbon.services.log.console.ConsoleLogger
All Implemented Interfaces:
org.apache.commons.logging.Log

public class ConsoleLogger
extends Object
implements org.apache.commons.logging.Log

Copyright 2003 Sapient

Since:
carbon 2.0
Version:
$Revision: 1.7 $($Author: ghinkl $ / $Date: 2003/07/15 16:18:49 $)
Author:
Anand Raman, March 2003

Field Summary
private  String className
          Name of the class associated with this logger
private static LogView console
          Reference to the view shared by all ConsoleLogger
 
Constructor Summary
ConsoleLogger(String name)
          Constructor
 
Method Summary
 void debug(Object message)
           
 void debug(Object message, Throwable exception)
           
protected  void enqueueMessage(String sourceClass, SeverityEnum severity, Object message)
           
 void error(Object message)
           
 void error(Object message, Throwable exception)
           
 void fatal(Object message)
           
 void fatal(Object message, Throwable exception)
           
 void info(Object message)
           
 void info(Object message, Throwable exception)
           
 boolean isDebugEnabled()
           
 boolean isErrorEnabled()
           
 boolean isFatalEnabled()
           
 boolean isInfoEnabled()
           
protected  boolean isLogging()
          This logger logs messages at all severities
 boolean isTraceEnabled()
           
 boolean isWarnEnabled()
           
 void trace(Object message)
           
 void trace(Object message, Throwable exception)
           
 void warn(Object message)
           
 void warn(Object message, Throwable exception)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

console

private static LogView console
Reference to the view shared by all ConsoleLogger


className

private String className
Name of the class associated with this logger

Constructor Detail

ConsoleLogger

public ConsoleLogger(String name)
Constructor

Parameters:
name - The class name with which this logger is associated
Method Detail

debug

public void debug(Object message)
Specified by:
debug in interface org.apache.commons.logging.Log
See Also:
Log.debug(Object)

error

public void error(Object message)
Specified by:
error in interface org.apache.commons.logging.Log
See Also:
Log.error(Object)

fatal

public void fatal(Object message)
Specified by:
fatal in interface org.apache.commons.logging.Log
See Also:
Log.fatal(Object)

info

public void info(Object message)
Specified by:
info in interface org.apache.commons.logging.Log
See Also:
Log.info(Object)

trace

public void trace(Object message)
Specified by:
trace in interface org.apache.commons.logging.Log
See Also:
Log.trace(Object)

warn

public void warn(Object message)
Specified by:
warn in interface org.apache.commons.logging.Log
See Also:
Log.warn(Object)

enqueueMessage

protected void enqueueMessage(String sourceClass,
                              SeverityEnum severity,
                              Object message)

isDebugEnabled

public boolean isDebugEnabled()
Specified by:
isDebugEnabled in interface org.apache.commons.logging.Log
See Also:
Log.isDebugEnabled()

isErrorEnabled

public boolean isErrorEnabled()
Specified by:
isErrorEnabled in interface org.apache.commons.logging.Log
See Also:
Log.isErrorEnabled()

isFatalEnabled

public boolean isFatalEnabled()
Specified by:
isFatalEnabled in interface org.apache.commons.logging.Log
See Also:
Log.isFatalEnabled()

isInfoEnabled

public boolean isInfoEnabled()
Specified by:
isInfoEnabled in interface org.apache.commons.logging.Log
See Also:
Log.isInfoEnabled()

isTraceEnabled

public boolean isTraceEnabled()
Specified by:
isTraceEnabled in interface org.apache.commons.logging.Log
See Also:
Log.isTraceEnabled()

isWarnEnabled

public boolean isWarnEnabled()
Specified by:
isWarnEnabled in interface org.apache.commons.logging.Log
See Also:
Log.isWarnEnabled()

isLogging

protected boolean isLogging()
This logger logs messages at all severities


debug

public void debug(Object message,
                  Throwable exception)
Specified by:
debug in interface org.apache.commons.logging.Log
See Also:
Log.debug(Object, Throwable)

error

public void error(Object message,
                  Throwable exception)
Specified by:
error in interface org.apache.commons.logging.Log
See Also:
Log.error(Object, Throwable)

fatal

public void fatal(Object message,
                  Throwable exception)
Specified by:
fatal in interface org.apache.commons.logging.Log
See Also:
Log.fatal(Object, Throwable)

info

public void info(Object message,
                 Throwable exception)
Specified by:
info in interface org.apache.commons.logging.Log
See Also:
Log.info(Object, Throwable)

trace

public void trace(Object message,
                  Throwable exception)
Specified by:
trace in interface org.apache.commons.logging.Log
See Also:
Log.trace(Object, Throwable)

warn

public void warn(Object message,
                 Throwable exception)
Specified by:
warn in interface org.apache.commons.logging.Log
See Also:
Log.warn(Object, Throwable)


Copyright 1999-2003 Sapient Corporation. All Rights Reserved.