|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.velocity.runtime.log.SimpleLog4JLogSystem
public class SimpleLog4JLogSystem
Implementation of a simple log4j system that will either latch onto an existing category, or just do a simple rolling file log. Derived from Jon's 'complicated' version :)
Field Summary | |
---|---|
protected org.apache.log4j.Category |
logger
log4java logging interface |
private RuntimeServices |
rsvc
|
Fields inherited from interface org.apache.velocity.runtime.log.LogSystem |
---|
DEBUG_ID, DEBUG_ON, ERROR_ID, INFO_ID, WARN_ID |
Constructor Summary | |
---|---|
SimpleLog4JLogSystem()
|
Method Summary | |
---|---|
protected void |
finalize()
Also do a shutdown if the object is destroy()'d. |
void |
init(RuntimeServices rs)
init() |
private void |
internalInit(java.lang.String logfile)
initializes the log system using the logfile argument |
void |
logVelocityMessage(int level,
java.lang.String message)
logs messages |
void |
shutdown()
Close all destinations |
Methods inherited from class java.lang.Object |
---|
clone, equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private RuntimeServices rsvc
protected org.apache.log4j.Category logger
Constructor Detail |
---|
public SimpleLog4JLogSystem()
Method Detail |
---|
public void init(RuntimeServices rs)
LogSystem
init
in interface LogSystem
private void internalInit(java.lang.String logfile) throws java.lang.Exception
java.lang.Exception
public void logVelocityMessage(int level, java.lang.String message)
logVelocityMessage
in interface LogSystem
level
- severity levelmessage
- complete error messageprotected void finalize() throws java.lang.Throwable
finalize
in class java.lang.Object
java.lang.Throwable
public void shutdown()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |