public final class Logger
extends java.lang.Object
Constructor and Description |
---|
Logger() |
Modifier and Type | Method and Description |
---|---|
static void |
debug(java.lang.String message)
Logs a DEBUG message.
|
static void |
debug(java.lang.String message,
java.lang.Object... arguments)
Logs a DEBUG message with the given arguments.
|
static void |
error(java.lang.String message)
Logs an ERROR message.
|
static void |
error(java.lang.String message,
java.lang.Object... arguments)
Logs an ERROR message with the given arguments.
|
static void |
error(java.lang.String message,
java.lang.Throwable exception)
Logs an ERROR message with the given exception.
|
static void |
info(java.lang.String message)
Logs an INFO message.
|
static boolean |
isDebugEnabled()
Checks whether log entries at DEBUG level will be output.
|
static boolean |
isErrorEnabled()
Checks whether log entries at ERROR level will be output.
|
static boolean |
isInfoEnabled()
Checks whether log entries at INFO level will be output.
|
static boolean |
isWarnEnabled()
Checks whether log entries at WARNING level will be output.
|
static Level |
level()
Returns the current log level specifying which message levels will be logged.
|
static void |
level(Level level)
Sets the log level specifying which message levels will be logged.
|
static void |
warn(java.lang.String message)
Logs a WARNING message.
|
static void |
warn(java.lang.String message,
java.lang.Throwable exception)
Logs a WARNING message with the given exception.
|
public static Level level()
public static void level(Level level)
Level.OFF
value can be used to turn off logging.level
- the new value for the log levelpublic static void error(java.lang.String message)
message
- the message to logpublic static void error(java.lang.String message, java.lang.Object... arguments)
message
- the message to logarguments
- the array of arguments to the messagepublic static void error(java.lang.String message, java.lang.Throwable exception)
message
- the message to logexception
- the Throwable
associated with the log messagepublic static void info(java.lang.String message)
message
- the message to logpublic static void warn(java.lang.String message)
message
- the message to logpublic static void warn(java.lang.String message, java.lang.Throwable exception)
message
- the message to logexception
- the Throwable
associated with the log messagepublic static void debug(java.lang.String message)
message
- the message to logpublic static void debug(java.lang.String message, java.lang.Object... arguments)
message
- the message to logarguments
- the array of arguments to the messagepublic static boolean isErrorEnabled()
public static boolean isWarnEnabled()
public static boolean isInfoEnabled()
public static boolean isDebugEnabled()