org.jasig.portal.services
Class LogService
java.lang.Object
org.jasig.portal.services.LogService
- public final class LogService
- extends java.lang.Object
The Logger class is used to output messages to a log file. The first call to
a log method triggers an initialization which renames old logs and creates a
new log with a message stating the current time and log level. The maximum
number of backup log files is specified as a member variable and can be set
by calling setMaxBackupLogFiles (). When calling a log method, it is
necessary to specify a log level which can be either NONE, SEVERE, ERROR,
WARN, INFO, or DEBUG (listed in order of decreasing severity). Log messages
will only be logged if their log level is the same or more severe than the
static member log level, which can be changed by calling setLogLevel ().
Zed's NOTES: This has been completely re-written to use the Log4J system
entirely. This means that you can now write wonderful config files which let
you pick your own log format and your own ouput methods. It will also now
watch the config file for changes and reload them (thus, letting you make
changes without restarting the Portal).
- Version:
- $Revision: 1.16 $
- Author:
- Ken Weiner, Bernie Durfee, Vikrant Joshi, Zed A. Shaw
Field Summary |
static org.apache.log4j.Priority |
DEBUG
|
static org.apache.log4j.Priority |
ERROR
|
static org.apache.log4j.Priority |
INFO
|
static org.apache.log4j.Priority |
NONE
|
static org.apache.log4j.Priority |
SEVERE
|
static org.apache.log4j.Priority |
WARN
|
Method Summary |
static LogService |
instance()
|
static void |
log(org.apache.log4j.Priority pLogLevel,
java.lang.String sMessage)
|
static void |
log(org.apache.log4j.Priority pLogLevel,
java.lang.String sMessage,
java.lang.Throwable ex)
|
static void |
log(org.apache.log4j.Priority pLogLevel,
java.lang.Throwable ex)
|
static void |
log(java.lang.String sMessage)
|
Methods inherited from class java.lang.Object |
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
NONE
public static final org.apache.log4j.Priority NONE
SEVERE
public static final org.apache.log4j.Priority SEVERE
ERROR
public static final org.apache.log4j.Priority ERROR
WARN
public static final org.apache.log4j.Priority WARN
INFO
public static final org.apache.log4j.Priority INFO
DEBUG
public static final org.apache.log4j.Priority DEBUG
instance
public static final LogService instance()
log
public static final void log(org.apache.log4j.Priority pLogLevel,
java.lang.String sMessage)
log
public static final void log(org.apache.log4j.Priority pLogLevel,
java.lang.Throwable ex)
log
public static final void log(org.apache.log4j.Priority pLogLevel,
java.lang.String sMessage,
java.lang.Throwable ex)
log
public static final void log(java.lang.String sMessage)