|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectsmbdav.Log
Provides logging utility functionality. A provider can extend this class and is specified by the "smbdav.Log" system property, or via a Jar service provider ("/META-INF/services/smbdav.Log").
Field Summary | |
static int |
CRITICAL
Logging threshold indicating critical errors should be logged. |
static int |
DEBUG
Logging threshold indicating everything should be logged. |
static int |
ERROR
Logging threshold indicating errors should be logged. |
static int |
INFORMATION
Logging threshold indicating useful information should be logged. |
static int |
NOTHING
Logging threshold indicating nothing should be logged. |
static int |
WARNING
Logging threshold indicating warnings should be logged. |
Constructor Summary | |
protected |
Log()
Constructed provided for subclasses. |
Method Summary | |
protected int |
getLogThreshold()
Returns the current logging threshold. |
static int |
getThreshold()
Returns the current logging threshold. |
static void |
log(int level,
java.lang.Object arg)
Logs an object for the specified level. |
static void |
log(int level,
java.lang.String message,
java.lang.Object arg)
Logs a message with an argument object for the specified level. |
protected abstract void |
logMessage(int level,
java.lang.String message)
Logs the specified message at the provided level. |
static void |
setThreshold(int threshold)
Sets the current logging threshold. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
public static final int DEBUG
public static final int INFORMATION
public static final int WARNING
public static final int ERROR
public static final int CRITICAL
public static final int NOTHING
Constructor Detail |
protected Log()
Method Detail |
public static int getThreshold()
int
containing the current threshold value.public static void setThreshold(int threshold)
threshold
- The new logging threshold value.public static void log(int level, java.lang.Object arg)
level
- The logging level.arg
- The argument object. String
s will be logged
directly; Throwable
s will log a stack trace.public static void log(int level, java.lang.String message, java.lang.Object arg)
level
- The logging level.message
- The message. This can contain format arguments,
i.e. "{0}".arg
- The argument object. A String
will be
interpreted as a single format value. A Throwable
will use the associated stack trace as the format value.
A Object[]
will be interpreted as a set of format values
(i.e., "{0}", "{1}", etc.).protected int getLogThreshold()
int
containing the current threshold value.protected abstract void logMessage(int level, java.lang.String message)
level
- The logging level.message
- The message that is to be logged.
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |