SLF4J API
Version 1.4.3

org.apache.log4j
Class Category

java.lang.Object
  extended by org.apache.log4j.Category
Direct Known Subclasses:
Logger

public class Category
extends Object

This class is a minimal implementation of the origianl org.apache.log4j.Logger class delegating all calls to a org.slf4j.Logger.Logger instance.

Log4j's debug(), info(), warn(), error() printing methods are directly mapped to their logback equivalents. Log4j's trace() printing method is mapped to logback's debug() method with a TRACE marker. Log4j's fatal() printing method is mapped to logback's error() method with a FATAL marker.

Author:
Sébastien Pennec, Ceki Gülcü

Method Summary
 void debug(Object message)
          Delegates to Logger method of logback.
 void debug(Object message, Object o)
          Delegates to Logger method of logback.
 void debug(Object message, Throwable t)
          Delegates to Logger method of logback.
 void debug(String message, Object arg1, Object arg2)
          Delegates to Logger method of logback.
 void error(Object message)
          Delegates to Logger method of logback.
 void error(Object message, Object o)
          Delegates to Logger method of logback.
 void error(Object message, Throwable t)
          Delegates to Logger method of logback.
 void error(String message, Object arg1, Object arg2)
          Delegates to Logger method of logback.
 void fatal(Object message)
          Delegates to Logger method of logback.
 void fatal(Object message, Object o)
          Delegates to Logger method of logback in addition, the call is marked with a marker named "FATAL".
 void fatal(Object message, Throwable t)
          Delegates to Logger method of logback in addition, the call is marked with a marker named "FATAL".
 void fatal(String message, Object arg1, Object arg2)
          Delegates to Logger method of logback in addition, the call is marked with a marker named "FATAL".
static Logger getLogger(Class clazz)
           
static Logger getLogger(String name)
           
 String getName()
          Returns the obvious.
static Logger getRootLogger()
          Does the obvious.
 void info(Object message)
          Delegates to Logger method of logback.
 void info(Object message, Object o)
          Delegates to Logger method of logback.
 void info(Object message, Throwable t)
          Delegates to Logger method of logback.
 void info(String message, Object arg1, Object arg2)
          Delegates to Logger method of logback.
 boolean isDebugEnabled()
          Delegates to Logger method of logback
 boolean isEnabledFor(Level l)
           
 boolean isEnabledFor(Priority p)
           
 boolean isErrorEnabled()
          Delegates to Logger method of logback
 boolean isInfoEnabled()
          Delegates to Logger method of logback
 boolean isTraceEnabled()
          Delegates to Logger method of logback.
 boolean isWarnEnabled()
          Delegates to Logger method of logback
 void log(String FQCN, Priority p, Object msg, Throwable t)
           
 void trace(Object message)
          Delegates to Logger method of logback, in addition, the call is marked with a marker named "TRACE".
 void trace(Object message, Object o)
          Delegates to Logger method of logback in addition, the call is marked with a marker named "TRACE".
 void trace(Object message, Throwable t)
          Delegates to Logger method of logback in addition, the call is marked with a marker named "TRACE".
 void trace(String message, Object arg1, Object arg2)
          Delegates to Logger method of logback in addition, the call is marked with a marker named "TRACE".
 void warn(Object message)
          Delegates to Logger method of logback.
 void warn(Object message, Object o)
          Delegates to Logger method of logback.
 void warn(Object message, Throwable t)
          Delegates to Logger method of logback.
 void warn(String message, Object arg1, Object arg2)
          Delegates to Logger method of logback.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Method Detail

getLogger

public static Logger getLogger(String name)

getLogger

public static Logger getLogger(Class clazz)

getRootLogger

public static Logger getRootLogger()
Does the obvious.

Returns:

getName

public String getName()
Returns the obvious.

Returns:

isTraceEnabled

public boolean isTraceEnabled()
Delegates to Logger method of logback.


isDebugEnabled

public boolean isDebugEnabled()
Delegates to Logger method of logback


isInfoEnabled

public boolean isInfoEnabled()
Delegates to Logger method of logback


isWarnEnabled

public boolean isWarnEnabled()
Delegates to Logger method of logback


isEnabledFor

public boolean isEnabledFor(Priority p)

isEnabledFor

public boolean isEnabledFor(Level l)

isErrorEnabled

public boolean isErrorEnabled()
Delegates to Logger method of logback


trace

public void trace(Object message)
Delegates to Logger method of logback, in addition, the call is marked with a marker named "TRACE".


trace

public void trace(Object message,
                  Throwable t)
Delegates to Logger method of logback in addition, the call is marked with a marker named "TRACE".


trace

public void trace(Object message,
                  Object o)
Delegates to Logger method of logback in addition, the call is marked with a marker named "TRACE".


trace

public void trace(String message,
                  Object arg1,
                  Object arg2)
Delegates to Logger method of logback in addition, the call is marked with a marker named "TRACE".


debug

public void debug(Object message)
Delegates to Logger method of logback.


debug

public void debug(Object message,
                  Throwable t)
Delegates to Logger method of logback.


debug

public void debug(Object message,
                  Object o)
Delegates to Logger method of logback.


debug

public void debug(String message,
                  Object arg1,
                  Object arg2)
Delegates to Logger method of logback.


info

public void info(Object message)
Delegates to Logger method of logback.


info

public void info(Object message,
                 Throwable t)
Delegates to Logger method of logback.


info

public void info(Object message,
                 Object o)
Delegates to Logger method of logback.


info

public void info(String message,
                 Object arg1,
                 Object arg2)
Delegates to Logger method of logback.


warn

public void warn(Object message)
Delegates to Logger method of logback.


warn

public void warn(Object message,
                 Throwable t)
Delegates to Logger method of logback.


warn

public void warn(Object message,
                 Object o)
Delegates to Logger method of logback.


warn

public void warn(String message,
                 Object arg1,
                 Object arg2)
Delegates to Logger method of logback.


error

public void error(Object message)
Delegates to Logger method of logback.


error

public void error(Object message,
                  Throwable t)
Delegates to Logger method of logback.


error

public void error(Object message,
                  Object o)
Delegates to Logger method of logback.


error

public void error(String message,
                  Object arg1,
                  Object arg2)
Delegates to Logger method of logback.


fatal

public void fatal(Object message)
Delegates to Logger method of logback.


fatal

public void fatal(Object message,
                  Throwable t)
Delegates to Logger method of logback in addition, the call is marked with a marker named "FATAL".


fatal

public void fatal(Object message,
                  Object o)
Delegates to Logger method of logback in addition, the call is marked with a marker named "FATAL".


fatal

public void fatal(String message,
                  Object arg1,
                  Object arg2)
Delegates to Logger method of logback in addition, the call is marked with a marker named "FATAL".


log

public void log(String FQCN,
                Priority p,
                Object msg,
                Throwable t)

SLF4J API
Version 1.4.3

Copyright © 2005-2008 QOS.ch. All Rights Reserved.