|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.jmol.util.Logger
public final class Logger
Logger mechanism.
| Field Summary | |
|---|---|
private static boolean[] |
_activeLevels
|
private static LoggerInterface |
_logger
|
private static boolean |
_logLevel
|
static boolean |
debugging
|
static int |
LEVEL_DEBUG
|
static int |
LEVEL_DEBUGHIGH
|
static int |
LEVEL_ERROR
|
static int |
LEVEL_FATAL
|
static int |
LEVEL_INFO
|
static int |
LEVEL_MAX
|
static int |
LEVEL_WARN
|
(package private) static long |
startTime
|
| Constructor Summary | |
|---|---|
Logger()
|
|
| Method Summary | |
|---|---|
static long |
checkTimer(java.lang.String msg)
|
static void |
debug(java.lang.String txt)
Writes a log at DEBUG level. |
static void |
error(java.lang.String txt)
Writes a log at ERROR level. |
static void |
error(java.lang.String txt,
java.lang.Throwable e)
Writes a log at ERROR level with detail on exception. |
static void |
fatal(java.lang.String txt)
Writes a log at FATAL level. |
static void |
fatal(java.lang.String txt,
java.lang.Throwable e)
Writes a log at FATAL level with detail on exception. |
static java.lang.String |
getLevel(int level)
Returns the text corresponding to a level. |
private static boolean |
getProperty(java.lang.String level,
boolean defaultValue)
|
static void |
info(java.lang.String txt)
Writes a log at INFO level. |
static boolean |
isActiveLevel(int level)
Tells if a logging level is active. |
static boolean |
logLevel()
Indicates if the level is logged. |
static void |
logLevel(boolean log)
Indicates if the level is logged. |
static void |
setActiveLevel(int level,
boolean active)
Changes the activation state for a logging level. |
static void |
setLogger(LoggerInterface logger)
Replaces the current logger implementation by a new one. |
static void |
setLogLevel(int level)
Activates all logging levels up through a given level. |
static void |
startTimer()
|
static void |
warn(java.lang.String txt)
Writes a log at WARN level. |
static void |
warn(java.lang.String txt,
java.lang.Throwable e)
Writes a log at WARN level with detail on exception. |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private static LoggerInterface _logger
public static final int LEVEL_FATAL
public static final int LEVEL_ERROR
public static final int LEVEL_WARN
public static final int LEVEL_INFO
public static final int LEVEL_DEBUG
public static final int LEVEL_DEBUGHIGH
public static final int LEVEL_MAX
private static final boolean[] _activeLevels
private static boolean _logLevel
public static boolean debugging
static long startTime
| Constructor Detail |
|---|
public Logger()
| Method Detail |
|---|
private static boolean getProperty(java.lang.String level,
boolean defaultValue)
public static void setLogger(LoggerInterface logger)
logger - New logger implementation.public static boolean isActiveLevel(int level)
level - Logging level.
public static void setActiveLevel(int level,
boolean active)
level - Level.active - New activation state.public static void setLogLevel(int level)
level - public static java.lang.String getLevel(int level)
level - Level.
public static boolean logLevel()
public static void logLevel(boolean log)
log - Indicator.public static void debug(java.lang.String txt)
txt - String to write.public static void info(java.lang.String txt)
txt - String to write.public static void warn(java.lang.String txt)
txt - String to write.
public static void warn(java.lang.String txt,
java.lang.Throwable e)
txt - String to write.e - Exception.public static void error(java.lang.String txt)
txt - String to write.
public static void error(java.lang.String txt,
java.lang.Throwable e)
txt - String to write.e - Exception.public static void fatal(java.lang.String txt)
txt - String to write.
public static void fatal(java.lang.String txt,
java.lang.Throwable e)
txt - String to write.e - Exception.public static void startTimer()
public static long checkTimer(java.lang.String msg)
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||