net.sf.xenqtt
Class LoggingLevels
java.lang.Object
net.sf.xenqtt.LoggingLevels
public final class LoggingLevels
- extends Object
Exposes the disparate log levels that are currently enabled for Xenqtt.
Constructor Summary |
LoggingLevels(boolean traceEnabled,
boolean debugEnabled,
boolean infoEnabled,
boolean warnEnabled,
boolean errorEnabled,
boolean fatalEnabled)
Create a new instance of this class. |
LoggingLevels(int flags)
Create a new instance of this class. |
Method Summary |
int |
flags()
|
boolean |
isLoggable(int flag)
Determine if an event is loggable. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
TRACE_FLAG
public static final int TRACE_FLAG
- See Also:
- Constant Field Values
DEBUG_FLAG
public static final int DEBUG_FLAG
- See Also:
- Constant Field Values
INFO_FLAG
public static final int INFO_FLAG
- See Also:
- Constant Field Values
WARN_FLAG
public static final int WARN_FLAG
- See Also:
- Constant Field Values
ERROR_FLAG
public static final int ERROR_FLAG
- See Also:
- Constant Field Values
FATAL_FLAG
public static final int FATAL_FLAG
- See Also:
- Constant Field Values
DEFAULT_LOGGING_LEVELS
public static final int DEFAULT_LOGGING_LEVELS
- See Also:
- Constant Field Values
traceEnabled
public final boolean traceEnabled
debugEnabled
public final boolean debugEnabled
infoEnabled
public final boolean infoEnabled
warnEnabled
public final boolean warnEnabled
errorEnabled
public final boolean errorEnabled
fatalEnabled
public final boolean fatalEnabled
LoggingLevels
public LoggingLevels(boolean traceEnabled,
boolean debugEnabled,
boolean infoEnabled,
boolean warnEnabled,
boolean errorEnabled,
boolean fatalEnabled)
- Create a new instance of this class.
- Parameters:
traceEnabled
- Whether or not trace logging is enableddebugEnabled
- Whether or not debug logging is enabledinfoEnabled
- Whether or not info logging is enabledwarnEnabled
- Whether or not warn logging is enablederrorEnabled
- Whether or not error logging is enabledfatalEnabled
- Whether or not fatal logging is enabled
LoggingLevels
public LoggingLevels(int flags)
- Create a new instance of this class.
- Parameters:
flags
- Flags that define which logging levels are enabled. The following specifies which flags map to which values:
F = Fatal
E = Error
W = Warn
I = Info
D = Debug
T = Trace
-----------------------------------------
|...| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
-----------------------------------------
|...| X | X | X | F | E | W | I | D | T |
-----------------------------------------
flags
public int flags()
- Returns:
- Flags indicating which logging levels are currently enabled. The following describes the flags that will be set depending on logging levels:
F = Fatal
E = Error
W = Warn
I = Info
D = Debug
T = Trace
-----------------------------------------
|...| 8 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
-----------------------------------------
|...| X | X | X | F | E | W | I | D | T |
-----------------------------------------
isLoggable
public boolean isLoggable(int flag)
- Determine if an event is loggable.
- Parameters:
flag
- The level flag to use in determining if an event is loggable
- Returns:
true
if the event is loggable, false
if it is not
Copyright © 2013. All Rights Reserved.