| java.lang.Object org.enhydra.dm.api.loggers.Log
All known Subclasses: org.enhydra.dm.loggers.Log4jLog, org.enhydra.dm.loggers.EnhydraLog,
Log | abstract public class Log (Code) | | Provides logging utility functionality. A provider can extend this class and is
specified by the "org.enhydra.dm.util.Log" system property.
|
Field Summary | |
final public static int | CRITICAL Logging threshold indicating critical errors should be logged. | final public static int | DEBUG Logging threshold indicating everything should be logged. | final public static int | ERROR Logging threshold indicating errors should be logged. | final public static int | INFORMATION Logging threshold indicating useful information should be logged. | final public static int | NOTHING Logging threshold indicating nothing should be logged. | final public static int | WARNING Logging threshold indicating warnings should be logged. |
Constructor Summary | |
protected | Log() Constructed provided for subclasses. |
Method Summary | |
public static Log | getInstance() | protected int | getLogThreshold() Returns the current logging threshold. | public int | getThreshold() Returns the current logging threshold. | public void | log(int level, Object arg) Logs an object for the specified level.
Parameters: level - The logging level. Parameters: arg - The argument object. | public void | log(int level, String message, Object arg) Logs a message with an argument object for the specified level.
Parameters: level - The logging level. Parameters: message - The message. | abstract protected void | logMessage(int level, String message) Logs the specified message at the provided level. | public static void | setLogger(Log logger) | public void | setThreshold(int threshold) Sets the current logging threshold. |
CRITICAL | final public static int CRITICAL(Code) | | Logging threshold indicating critical errors should be logged.
|
DEBUG | final public static int DEBUG(Code) | | Logging threshold indicating everything should be logged.
|
ERROR | final public static int ERROR(Code) | | Logging threshold indicating errors should be logged.
|
INFORMATION | final public static int INFORMATION(Code) | | Logging threshold indicating useful information should be logged.
|
NOTHING | final public static int NOTHING(Code) | | Logging threshold indicating nothing should be logged.
|
WARNING | final public static int WARNING(Code) | | Logging threshold indicating warnings should be logged.
|
Log | protected Log()(Code) | | Constructed provided for subclasses.
|
getInstance | public static Log getInstance()(Code) | | |
getLogThreshold | protected int getLogThreshold()(Code) | | Returns the current logging threshold.
an int containing the current threshold value. |
getThreshold | public int getThreshold()(Code) | | Returns the current logging threshold.
an int containing the current threshold value. |
log | public void log(int level, Object arg)(Code) | | Logs an object for the specified level.
Parameters: level - The logging level. Parameters: arg - The argument object. String s will be logged directly;Throwable s will log a stack trace. |
log | public void log(int level, String message, Object arg)(Code) | | Logs a message with an argument object for the specified level.
Parameters: level - The logging level. Parameters: message - The message. This can contain format arguments, i.e. "{0}". Parameters: arg - The argument object. A String will be interpreted as asingle format value. A Throwable will use the associatedstack trace as the format value. A Object[] will beinterpreted as a set of format values (i.e., "{0}", "{1}", etc.). |
logMessage | abstract protected void logMessage(int level, String message)(Code) | | Logs the specified message at the provided level.
Parameters: level - The logging level. Parameters: message - The message that is to be logged. |
setLogger | public static void setLogger(Log logger)(Code) | | |
setThreshold | public void setThreshold(int threshold)(Code) | | Sets the current logging threshold.
Parameters: threshold - The new logging threshold value. |
|
|