uk.ac.sanger.cgp.standalonecsa.services
Class VelocityLogImpl

java.lang.Object
  extended by uk.ac.sanger.cgp.standalonecsa.services.VelocityLogImpl
All Implemented Interfaces:
org.apache.velocity.runtime.log.LogSystem

public class VelocityLogImpl
extends java.lang.Object
implements org.apache.velocity.runtime.log.LogSystem

Allows log messages from the velocity template engine to be sent to the log4j instance.

Author:
Original: kr2, $Author: kr2 $

Field Summary
 
Fields inherited from interface org.apache.velocity.runtime.log.LogSystem
DEBUG_ID, DEBUG_ON, ERROR_ID, INFO_ID, WARN_ID
 
Constructor Summary
VelocityLogImpl()
           
 
Method Summary
 void init(org.apache.velocity.runtime.RuntimeServices rs)
          Required to initialise object.
 void logVelocityMessage(int level, java.lang.String message)
          Passes the different types of Velocity message to the appropriate log4j class.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

VelocityLogImpl

public VelocityLogImpl()
Method Detail

init

public void init(org.apache.velocity.runtime.RuntimeServices rs)
          throws java.lang.Exception
Required to initialise object.

Specified by:
init in interface org.apache.velocity.runtime.log.LogSystem
Parameters:
rs -
Throws:
java.lang.Exception - can throw an exception

logVelocityMessage

public void logVelocityMessage(int level,
                               java.lang.String message)
Passes the different types of Velocity message to the appropriate log4j class.

Specified by:
logVelocityMessage in interface org.apache.velocity.runtime.log.LogSystem
Parameters:
level - indicates severity of Velocity message
message - the message to be passed to log4j