org.apache.geronimo.system.logging.log4j
Class XLevel

java.lang.Object
  extended by org.apache.log4j.Priority
      extended by org.apache.log4j.Level
          extended by org.apache.geronimo.system.logging.log4j.XLevel
All Implemented Interfaces:
Serializable

public final class XLevel
extends Level

Extention levels for Log4j

See Also:
Serialized Form

Field Summary
static XLevel TRACE
          The Log4j Level Object to use for trace level messages
static int TRACE_INT
           
 
Fields inherited from class org.apache.log4j.Level
ALL, DEBUG, ERROR, FATAL, INFO, OFF, WARN
 
Fields inherited from class org.apache.log4j.Priority
ALL_INT, DEBUG_INT, ERROR_INT, FATAL_INT, INFO_INT, OFF_INT, WARN_INT
 
Constructor Summary
protected XLevel(int level, String name, int syslogEquiv)
           
 
Method Summary
static Level toLevel(int level)
          Convert an integer passed as argument to a level.
static Level toLevel(String name)
          Convert the String argument to a level.
static Level toLevel(String name, Level defaultValue)
          Convert the String argument to a level.
 
Methods inherited from class org.apache.log4j.Level
toLevel
 
Methods inherited from class org.apache.log4j.Priority
equals, getAllPossiblePriorities, getSyslogEquivalent, isGreaterOrEqual, toInt, toPriority, toPriority, toPriority, toPriority, toString
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TRACE_INT

public static final int TRACE_INT
See Also:
Constant Field Values

TRACE

public static final XLevel TRACE
The Log4j Level Object to use for trace level messages

Constructor Detail

XLevel

protected XLevel(int level,
                 String name,
                 int syslogEquiv)
Method Detail

toLevel

public static Level toLevel(String name)
Convert the String argument to a level. If the conversion fails then this method returns TRACE.


toLevel

public static Level toLevel(String name,
                            Level defaultValue)
Convert the String argument to a level. If the conversion fails, return the level specified by the second argument, i.e. defaultValue.


toLevel

public static Level toLevel(int level)
                     throws IllegalArgumentException
Convert an integer passed as argument to a level. If the conversion fails, then this method returns Level.DEBUG.

Throws:
IllegalArgumentException


Copyright © 2003-2007 Apache Software Foundation. All Rights Reserved.