|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.commons.logging.impl.Jdk14Logger
public class Jdk14Logger
Implementation of the org.apache.commons.logging.Log
interface that wraps the standard JDK logging mechanisms that were
introduced in the Merlin release (JDK 1.4).
Field Summary | |
---|---|
protected static Level |
dummyLevel
This member variable simply ensures that any attempt to initialise this class in a pre-1.4 JVM will result in an ExceptionInInitializerError. |
protected Logger |
logger
The underlying Logger implementation we are using. |
protected String |
name
The name of the logger we are wrapping. |
Constructor Summary | |
---|---|
Jdk14Logger(String name)
Construct a named instance of this Logger. |
Method Summary | |
---|---|
void |
debug(Object message)
Logs a message with java.util.logging.Level.FINE . |
void |
debug(Object message,
Throwable exception)
Logs a message with java.util.logging.Level.FINE . |
void |
error(Object message)
Logs a message with java.util.logging.Level.SEVERE . |
void |
error(Object message,
Throwable exception)
Logs a message with java.util.logging.Level.SEVERE . |
void |
fatal(Object message)
Logs a message with java.util.logging.Level.SEVERE . |
void |
fatal(Object message,
Throwable exception)
Logs a message with java.util.logging.Level.SEVERE . |
Logger |
getLogger()
Return the native Logger instance we are using. |
void |
info(Object message)
Logs a message with java.util.logging.Level.INFO . |
void |
info(Object message,
Throwable exception)
Logs a message with java.util.logging.Level.INFO . |
boolean |
isDebugEnabled()
Is debug logging currently enabled? |
boolean |
isErrorEnabled()
Is error logging currently enabled? |
boolean |
isFatalEnabled()
Is fatal logging currently enabled? |
boolean |
isInfoEnabled()
Is info logging currently enabled? |
boolean |
isTraceEnabled()
Is trace logging currently enabled? |
boolean |
isWarnEnabled()
Is warn logging currently enabled? |
protected void |
log(Level level,
String msg,
Throwable ex)
|
void |
trace(Object message)
Logs a message with java.util.logging.Level.FINEST . |
void |
trace(Object message,
Throwable exception)
Logs a message with java.util.logging.Level.FINEST . |
void |
warn(Object message)
Logs a message with java.util.logging.Level.WARNING . |
void |
warn(Object message,
Throwable exception)
Logs a message with java.util.logging.Level.WARNING . |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected static final Level dummyLevel
protected transient Logger logger
protected String name
Constructor Detail |
---|
public Jdk14Logger(String name)
name
- Name of the logger to be constructedMethod Detail |
---|
protected void log(Level level, String msg, Throwable ex)
public void debug(Object message)
java.util.logging.Level.FINE
.
debug
in interface Log
message
- to logLog.debug(Object)
public void debug(Object message, Throwable exception)
java.util.logging.Level.FINE
.
debug
in interface Log
message
- to logexception
- log this causeLog.debug(Object, Throwable)
public void error(Object message)
java.util.logging.Level.SEVERE
.
error
in interface Log
message
- to logLog.error(Object)
public void error(Object message, Throwable exception)
java.util.logging.Level.SEVERE
.
error
in interface Log
message
- to logexception
- log this causeLog.error(Object, Throwable)
public void fatal(Object message)
java.util.logging.Level.SEVERE
.
fatal
in interface Log
message
- to logLog.fatal(Object)
public void fatal(Object message, Throwable exception)
java.util.logging.Level.SEVERE
.
fatal
in interface Log
message
- to logexception
- log this causeLog.fatal(Object, Throwable)
public Logger getLogger()
public void info(Object message)
java.util.logging.Level.INFO
.
info
in interface Log
message
- to logLog.info(Object)
public void info(Object message, Throwable exception)
java.util.logging.Level.INFO
.
info
in interface Log
message
- to logexception
- log this causeLog.info(Object, Throwable)
public boolean isDebugEnabled()
isDebugEnabled
in interface Log
public boolean isErrorEnabled()
isErrorEnabled
in interface Log
public boolean isFatalEnabled()
isFatalEnabled
in interface Log
public boolean isInfoEnabled()
isInfoEnabled
in interface Log
public boolean isTraceEnabled()
isTraceEnabled
in interface Log
public boolean isWarnEnabled()
isWarnEnabled
in interface Log
public void trace(Object message)
java.util.logging.Level.FINEST
.
trace
in interface Log
message
- to logLog.trace(Object)
public void trace(Object message, Throwable exception)
java.util.logging.Level.FINEST
.
trace
in interface Log
message
- to logexception
- log this causeLog.trace(Object, Throwable)
public void warn(Object message)
java.util.logging.Level.WARNING
.
warn
in interface Log
message
- to logLog.warn(Object)
public void warn(Object message, Throwable exception)
java.util.logging.Level.WARNING
.
warn
in interface Log
message
- to logexception
- log this causeLog.warn(Object, Throwable)
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES All Classes | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |