|
SolarMetric Kodo JDO 3.0.3 generated on February 20 2004 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--com.solarmetric.log.LogAdapter
A simple adapter to allow the implementation of a Log
.
Only the method isLogEnabled
and log
need to be overridden.
Fields inherited from interface com.solarmetric.log.LogConstants |
DEBUG, ERROR, FATAL, INFO, TRACE, WARN |
Constructor Summary | |
LogAdapter()
|
Method Summary | |
void |
debug(Object message)
Log a message with debug log level. |
void |
debug(Object message,
Throwable t)
Log an error with debug log level. |
void |
error(Object message)
Log a message with error log level. |
void |
error(Object message,
Throwable t)
Log an error with error log level. |
void |
fatal(Object message)
Log a message with fatal log level. |
void |
fatal(Object message,
Throwable t)
Log an error with fatal log level. |
static String |
getLogLevel(short level)
Returns a String representation of the specified log level. |
static String |
getStackTrace(Throwable t)
Utility method to obtain a stack trace as a String. |
void |
info(Object message)
Log a message with info log level. |
void |
info(Object message,
Throwable t)
Log an error with info log level. |
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? |
abstract boolean |
isLogEnabled(short level)
Check to see if the specified logging level is enabled. |
boolean |
isTraceEnabled()
Is trace logging currently enabled? |
boolean |
isWarnEnabled()
Is warning logging currently enabled? |
abstract void |
log(short level,
String message,
Throwable t)
Send the specified log message to the handler. |
void |
trace(Object message)
Log a message with trace log level. |
void |
trace(Object message,
Throwable t)
Log an error with trace log level. |
void |
warn(Object message)
Log a message with warn log level. |
void |
warn(Object message,
Throwable t)
Log an error with warn log level. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public LogAdapter()
Method Detail |
public abstract boolean isLogEnabled(short level)
public static String getLogLevel(short level)
public static String getStackTrace(Throwable t)
public abstract void log(short level, String message, Throwable t)
level
- the level of the log messagemessage
- the message to sendt
- the Throwable, or null if this is not an errorpublic void debug(Object message)
debug
in interface org.apache.commons.logging.Log
public void debug(Object message, Throwable t)
debug
in interface org.apache.commons.logging.Log
public void error(Object message)
error
in interface org.apache.commons.logging.Log
public void error(Object message, Throwable t)
error
in interface org.apache.commons.logging.Log
public void fatal(Object message)
fatal
in interface org.apache.commons.logging.Log
public void fatal(Object message, Throwable t)
fatal
in interface org.apache.commons.logging.Log
public void info(Object message)
info
in interface org.apache.commons.logging.Log
public void info(Object message, Throwable t)
info
in interface org.apache.commons.logging.Log
public boolean isDebugEnabled()
isDebugEnabled
in interface org.apache.commons.logging.Log
public boolean isErrorEnabled()
isErrorEnabled
in interface org.apache.commons.logging.Log
public boolean isFatalEnabled()
isFatalEnabled
in interface org.apache.commons.logging.Log
public boolean isInfoEnabled()
isInfoEnabled
in interface org.apache.commons.logging.Log
public boolean isTraceEnabled()
isTraceEnabled
in interface org.apache.commons.logging.Log
public boolean isWarnEnabled()
isWarnEnabled
in interface org.apache.commons.logging.Log
public void trace(Object message)
trace
in interface org.apache.commons.logging.Log
public void trace(Object message, Throwable t)
trace
in interface org.apache.commons.logging.Log
public void warn(Object message)
warn
in interface org.apache.commons.logging.Log
public void warn(Object message, Throwable t)
warn
in interface org.apache.commons.logging.Log
|
SolarMetric Kodo JDO 3.0.3 generated on February 20 2004 | ||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |