|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.velocity.runtime.log.Log4JLogSystem
Implementation of a simple log4j system that will either latch onto
an existing category, or just do a simple rolling file log.
Use this one rather than SimpleLog4JLogSystem
; it uses the
modern Logger
concept of Log4J, rather than the
deprecated Categeory
concept.
Field Summary | |
protected org.apache.log4j.Logger |
logger
Log4J logging API. |
private RuntimeServices |
rsvc
|
static java.lang.String |
RUNTIME_LOG_LOG4J_LOGGER
|
Fields inherited from interface org.apache.velocity.runtime.log.LogSystem |
DEBUG_ID, DEBUG_ON, ERROR_ID, INFO_ID, WARN_ID |
Constructor Summary | |
Log4JLogSystem()
Log4J logging API. |
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 |
public static final java.lang.String RUNTIME_LOG_LOG4J_LOGGER
private RuntimeServices rsvc
protected org.apache.log4j.Logger logger
Constructor Detail |
public Log4JLogSystem()
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
java.lang.Throwable
public void shutdown()
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |