|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.log4j.Priority
public class Priority
Refrain from using this class directly, use
the Level
class instead.
Field Summary | |
---|---|
static int |
ALL_INT
The ALL has the lowest possible rank and is intended to
turn on all logging. |
static Priority |
DEBUG
Deprecated. Use Level.DEBUG instead. |
static int |
DEBUG_INT
The DEBUG Level designates fine-grained
informational events that are most useful to debug an
application. |
static Priority |
ERROR
Deprecated. Use Level.ERROR instead. |
static int |
ERROR_INT
The ERROR level designates error events that
might still allow the application to continue running. |
static Priority |
FATAL
Deprecated. Use Level.FATAL instead. |
static int |
FATAL_INT
The FATAL level designates very severe error
events that will presumably lead the application to abort. |
static Priority |
INFO
Deprecated. Use Level.INFO instead. |
static int |
INFO_INT
The INFO level designates informational messages
that highlight the progress of the application at coarse-grained
level. |
static int |
OFF_INT
The OFF has the highest possible rank and is
intended to turn off logging. |
static Priority |
WARN
Deprecated. Use Level.WARN instead. |
static int |
WARN_INT
The WARN level designates potentially harmful situations. |
Constructor Summary | |
---|---|
protected |
Priority()
Default constructor for deserialization. |
protected |
Priority(int level,
String levelStr,
int syslogEquivalent)
Instantiate a level object. |
Method Summary | |
---|---|
boolean |
equals(Object o)
Two priorities are equal if their level fields are equal. |
static Priority[] |
getAllPossiblePriorities()
Deprecated. This method will be removed with no replacement. |
int |
getSyslogEquivalent()
Return the syslog equivalent of this priority as an integer. |
boolean |
isGreaterOrEqual(Priority r)
Returns true if this level has a higher or equal
level than the level passed as argument, false
otherwise. |
int |
toInt()
Returns the integer representation of this level. |
static Priority |
toPriority(int val)
Deprecated. Please use the Level.toLevel(int) method instead. |
static Priority |
toPriority(int val,
Priority defaultPriority)
Deprecated. Please use the Level.toLevel(int, Level) method instead. |
static Priority |
toPriority(String sArg)
Deprecated. Please use the Level.toLevel(String) method instead. |
static Priority |
toPriority(String sArg,
Priority defaultPriority)
Deprecated. Please use the Level.toLevel(String, Level) method instead. |
String |
toString()
Returns the string representation of this priority. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static final int OFF_INT
OFF
has the highest possible rank and is
intended to turn off logging.
public static final int FATAL_INT
FATAL
level designates very severe error
events that will presumably lead the application to abort.
public static final int ERROR_INT
ERROR
level designates error events that
might still allow the application to continue running.
public static final int WARN_INT
WARN
level designates potentially harmful situations.
public static final int INFO_INT
INFO
level designates informational messages
that highlight the progress of the application at coarse-grained
level.
public static final int DEBUG_INT
DEBUG
Level designates fine-grained
informational events that are most useful to debug an
application.
public static final int ALL_INT
ALL
has the lowest possible rank and is intended to
turn on all logging.
@Deprecated public static final Priority FATAL
Level.FATAL
instead.@Deprecated public static final Priority ERROR
Level.ERROR
instead.@Deprecated public static final Priority WARN
Level.WARN
instead.@Deprecated public static final Priority INFO
Level.INFO
instead.@Deprecated public static final Priority DEBUG
Level.DEBUG
instead.Constructor Detail |
---|
protected Priority()
protected Priority(int level, String levelStr, int syslogEquivalent)
level
- The level value.levelStr
- The level name.syslogEquivalent
- The equivalent syslog value.Method Detail |
---|
public boolean equals(Object o)
equals
in class Object
o
- The Object to check.
public final int getSyslogEquivalent()
public boolean isGreaterOrEqual(Priority r)
true
if this level has a higher or equal
level than the level passed as argument, false
otherwise.
You should think twice before overriding the default
implementation of isGreaterOrEqual
method.
r
- The Priority to check.
@Deprecated public static Priority[] getAllPossiblePriorities()
public final String toString()
toString
in class Object
public final int toInt()
@Deprecated public static Priority toPriority(String sArg)
Level.toLevel(String)
method instead.
sArg
- The name of the Priority.
@Deprecated public static Priority toPriority(int val)
Level.toLevel(int)
method instead.
val
- The value of the Priority.
@Deprecated public static Priority toPriority(int val, Priority defaultPriority)
Level.toLevel(int, Level)
method instead.
val
- The value of the Priority.defaultPriority
- The default Priority to use if the value is invalid.
@Deprecated public static Priority toPriority(String sArg, Priority defaultPriority)
Level.toLevel(String, Level)
method instead.
sArg
- The name of the Priority.defaultPriority
- The default Priority to use if the name is not found.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |