public class ASTModNode extends ASTMathNode
strictMode
Constructor and Description |
---|
ASTModNode(int id) |
ASTModNode(Parser p,
int id) |
Modifier and Type | Method and Description |
---|---|
String |
getLiteralOperator()
get the string representing the mathematical operator
|
Object |
init(InternalContextAdapter context,
Object data) |
Number |
perform(Number left,
Number right,
InternalContextAdapter context)
Performs the math operation represented by this node.
|
handleSpecial, jjtAccept, value
literal
childrenAccept, cleanupParserAndTokens, dump, dump, dump, evaluate, execute, getColumn, getFirstToken, getFirstTokenImage, getInfo, getLastToken, getLastTokenImage, getLine, getLocation, getParser, getRuntimeServices, getTemplate, getTemplateName, getType, isInvalid, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, render, saveTokenImages, setFirstToken, setInfo, setInvalid, toString, toString
public ASTModNode(int id)
id
- public ASTModNode(Parser p, int id)
p
- id
- public Number perform(Number left, Number right, InternalContextAdapter context)
ASTMathNode
perform
in class ASTMathNode
ASTAddNode.perform(Number, Number, InternalContextAdapter)
public Object init(InternalContextAdapter context, Object data) throws TemplateInitException
ASTMathNode
init
in interface Node
init
in class ASTMathNode
TemplateInitException
Node.init(org.apache.velocity.context.InternalContextAdapter, java.lang.Object)
public String getLiteralOperator()
ASTBinaryOperator
getLiteralOperator
in class ASTBinaryOperator
Copyright © 2000–2020 The Apache Software Foundation. All rights reserved.