Class AntLogSystem

  • All Implemented Interfaces:
    org.apache.velocity.runtime.log.LogChute, org.apache.velocity.runtime.log.LogSystem

    public class AntLogSystem
    extends AntLogChute
    implements org.apache.velocity.runtime.log.LogSystem
    Deprecated.
    Use AntLogChute instead.
    Implementation of a logger to output messages via an Ant Task's log method. Velocity log levels are mapped to corresponding log levels defined in Ant's logging API. The end result is messages will only be output if Ant log level is high enough.
    Version:
    $Id: AntLogSystem.java 538000 2007-05-14 21:59:05Z cbrisson $
    Author:
    Bill Burton
    • Field Summary

      • Fields inherited from interface org.apache.velocity.runtime.log.LogChute

        DEBUG_ID, DEBUG_PREFIX, ERROR_ID, ERROR_PREFIX, INFO_ID, INFO_PREFIX, TRACE_ID, TRACE_PREFIX, WARN_ID, WARN_PREFIX
      • Fields inherited from interface org.apache.velocity.runtime.log.LogSystem

        DEBUG_ID, DEBUG_ON, ERROR_ID, INFO_ID, WARN_ID
    • Constructor Summary

      Constructors 
      Constructor Description
      AntLogSystem​(org.apache.tools.ant.Task task)
      Deprecated.
       
    • Constructor Detail

      • AntLogSystem

        public AntLogSystem​(org.apache.tools.ant.Task task)
        Deprecated.
    • Method Detail

      • logVelocityMessage

        public void logVelocityMessage​(int level,
                                       java.lang.String message)
        Deprecated.
        use AntLogChute

        Log Velocity messages through the Ant Task log method. The mapping of logging levels from Velocity to Ant is as follows:

         Velocity Level      -->  Ant Level
         LogSystem.DEBUG_ID  -->  Project.MSG_DEBUG
         LogSystem.INFO_ID   -->  Project.MSG_VERBOSE
         LogSystem.WARN_ID   -->  Project.MSG_WARN
         LogSystem.ERROR_ID  -->  Project.MSG_ERR
         
        Specified by:
        logVelocityMessage in interface org.apache.velocity.runtime.log.LogSystem
        Overrides:
        logVelocityMessage in class AntLogChute
        Parameters:
        level - severity level
        message - complete error message
        See Also:
        LogSystem, Task.log(String, int)