|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object de.lmu.ifi.dbs.elki.logging.LoggingConfiguration
public final class LoggingConfiguration
Facility for configuration of logging.
Field Summary | |
---|---|
private static String |
CLIConffile
Configuration file name |
private static String |
confbase
Configuration base |
protected static LoggingConfiguration |
config
Static instance of the configuration |
static boolean |
DEBUG
General debug flag. |
private static String |
TOPLEVEL_PACKAGE
Top level ELKI package (for setting 'verbose') |
Constructor Summary | |
---|---|
private |
LoggingConfiguration(String pkg,
String name)
Configure Java Logging API: LogManager |
Method Summary | |
---|---|
static void |
addHandler(Handler handler)
Add a handler to the root logger. |
static void |
assertConfigured()
Assert that logging was configured. |
private void |
privateReconfigureLogging(String pkg,
String name)
Reconfigure logging. |
static void |
reconfigureLogging(String pkg,
String name)
Reconfigure logging. |
static void |
replaceDefaultHandler(Handler handler)
Replace the default log handler with the given log handler. |
static void |
setDefaultLevel(Level level)
Set the default level. |
static void |
setLevelFor(String pkg,
String level)
Set the logging level for a particular package/class. |
static void |
setVerbose(boolean verbose)
Reconfigure logging to enable 'verbose' logging at the top level. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static boolean DEBUG
private static final String CLIConffile
private static final String TOPLEVEL_PACKAGE
private static final String confbase
protected static LoggingConfiguration config
Constructor Detail |
---|
private LoggingConfiguration(String pkg, String name)
LogManager
Method Detail |
---|
public static void reconfigureLogging(String pkg, String name)
pkg
- Package name the configuration file comes fromname
- File name.private void privateReconfigureLogging(String pkg, String name)
pkg
- Package name the configuration file comes fromname
- File name.public static void assertConfigured()
public static void setVerbose(boolean verbose)
verbose
- verbose flagpublic static void addHandler(Handler handler)
handler
- Handlerpublic static void replaceDefaultHandler(Handler handler)
CLISmartHandler
found on the root logger. It
will leave any other handlers in place.
handler
- Logging handler.public static void setLevelFor(String pkg, String level) throws IllegalArgumentException
pkg
- Packagelevel
- Level name
IllegalArgumentException
- thrown when logger or level was not foundpublic static void setDefaultLevel(Level level)
level
- level
|
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |