|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.zmicer.utils.LoggingUtils
public class LoggingUtils
This utility class contains logging utils (e.g. print the full stack trace of the provided exception into the log file etc.)
$Author:: zmicer $
$Rev:: 57 $
* $Date:: 2007-08-23 09:16:37 #$
Constructor Summary | |
---|---|
LoggingUtils()
|
Method Summary | |
---|---|
static void |
debug(org.apache.log4j.Logger log,
Class claz,
String message)
Perform the debugging: the information about the class is added. |
static void |
error(org.apache.log4j.Logger log,
Class claz,
String message)
Perform the debugging of error: the information about the class is added. |
static void |
logException(org.apache.log4j.Logger logger,
Throwable t,
String message,
Class claz)
This method prints the full stack trace of the given exception into the log file associated with the provided Logger instance. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LoggingUtils()
Method Detail |
---|
public static void logException(org.apache.log4j.Logger logger, Throwable t, String message, Class claz)
Logger
instance.
logger
- the log4j Logger we need to use.
Can not be null (otherwise IllegalArgumentException
would appear).t
- Throwable to be logged.message
- the message to be added to the logging. could be nullclaz
- Class instantiated the process of the logging the exception. Could be null.public static void debug(org.apache.log4j.Logger log, Class claz, String message)
log
- Logger instance. Can not be null (otherwise IllegalArgumentException
would appear).claz
- Class instance which is necessary to obtain the base name of the class to add this info to the log file.
Can not be null (otherwise IllegalArgumentException
would appear).message
- String message to be logged.public static void error(org.apache.log4j.Logger log, Class claz, String message)
log
- Logger instance. Can not be null (otherwise IllegalArgumentException
would appear).claz
- Class instance which is necessary to obtain the base name of the class to add this info to the log file.
Can not be null (otherwise IllegalArgumentException
would appear).message
- String message to be logged.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |