org.apache.velocity.runtime.parser.node
Class ASTModNode

java.lang.Object
  extended by org.apache.velocity.runtime.parser.node.SimpleNode
      extended by org.apache.velocity.runtime.parser.node.ASTMathNode
          extended by org.apache.velocity.runtime.parser.node.ASTModNode
All Implemented Interfaces:
Node

public class ASTModNode
extends ASTMathNode

Handles modulus division

Please look at the Parser.jjt file which is what controls the generation of this class.

Version:
$Id: ASTModNode.java 691048 2008-09-01 20:26:11Z nbubna $
Author:
Will Glass-Husain, Peter Romianowski, Geir Magnusson Jr.

Field Summary
 
Fields inherited from class org.apache.velocity.runtime.parser.node.ASTMathNode
strictMode
 
Fields inherited from class org.apache.velocity.runtime.parser.node.SimpleNode
children, first, id, info, invalid, last, log, parent, parser, rsvc, state, templateName
 
Constructor Summary
ASTModNode(int id)
           
ASTModNode(Parser p, int id)
           
 
Method Summary
 Number perform(Number left, Number right, InternalContextAdapter context)
          Performs the math operation represented by this node.
 
Methods inherited from class org.apache.velocity.runtime.parser.node.ASTMathNode
handleSpecial, init, jjtAccept, value
 
Methods inherited from class org.apache.velocity.runtime.parser.node.SimpleNode
childrenAccept, dump, evaluate, execute, getColumn, getFirstToken, getInfo, getLastToken, getLine, getLocation, getTemplateName, getType, isInvalid, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, literal, render, setFirstToken, setInfo, setInvalid, toString, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

ASTModNode

public ASTModNode(int id)
Parameters:
id -

ASTModNode

public ASTModNode(Parser p,
                  int id)
Parameters:
p -
id -
Method Detail

perform

public Number perform(Number left,
                      Number right,
                      InternalContextAdapter context)
Description copied from class: ASTMathNode
Performs the math operation represented by this node.

Specified by:
perform in class ASTMathNode


Copyright © 2000-2008 The Apache Software Foundation. All Rights Reserved.