public final class LoggerUtil extends Object
Modifier and Type | Method and Description |
---|---|
static void |
disableLogging()
Removes all the handlers from all the defined loggers.
|
static void |
removeRestletLoggers()
Adjusts the Restlet Loggers so that they dump their output rather than
sending it to the console.
|
static void |
setLoggingLevel(Logger logger,
String level)
Sets the logging level to be used for this WattDepot logger.
|
static void |
showLoggers()
Utility for printing out the known/defined logger names.
|
static void |
useConsoleHandler()
Forces all Loggers to use the Console for logging output.
|
static void |
useFileHandler(String serverHome)
Adjusts the Restlet Loggers so that they send their output to a file, not
the console.
|
public static void useConsoleHandler()
public static void disableLogging()
public static void useFileHandler(String serverHome)
serverHome
- Home directory for this server. Logging files are placed
in [serverHome]/logs. If null, an IllegalArgumentException is
thrown.IllegalArgumentException
- If serverHome is null.RuntimeException
- If there are problems creating directories or
opening log file.public static void removeRestletLoggers()
public static void setLoggingLevel(Logger logger, String level)
logger
- The logger whose level is to be set.level
- The new Level.public static void showLoggers()
Copyright © 2015 Collaborative Software Development Laboratory. All rights reserved.