Package com.singularsys.jep.parser
Class ASTOpNode
java.lang.Object
com.singularsys.jep.parser.SimpleNode
com.singularsys.jep.parser.ASTFunNode
com.singularsys.jep.parser.ASTOpNode
- All Implemented Interfaces:
Node
Function Node
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.singularsys.jep.parser.Node
Node.HookKey -
Field Summary
Fields inherited from class com.singularsys.jep.parser.ASTFunNode
pfmc -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetName()Returns the name of the node (operator symbol or function name).Returns the id number of the operator if the node is an operator.jjtAccept(ParserVisitor visitor, Object data) Accept the visitor.voidsetOperator(Operator op) Sets the opID, name and pfmc for this node by looking up the values in the Operators classtoString()Returns a string containing the function name.Methods inherited from class com.singularsys.jep.parser.ASTFunNode
getPFMC, getValue, getVar, setFunctionMethods inherited from class com.singularsys.jep.parser.SimpleNode
childIterator, children, childrenAccept, dump, getHook, getId, hookKeys, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent, removeHook, setHook, toString
-
Constructor Details
-
ASTOpNode
public ASTOpNode(int id) Creates a new ASTFunNode
-
-
Method Details
-
jjtAccept
Accept the visitor.- Specified by:
jjtAcceptin interfaceNode- Overrides:
jjtAcceptin classASTFunNode- Throws:
ParseExceptionJepException
-
setOperator
Sets the opID, name and pfmc for this node by looking up the values in the Operators class -
toString
Returns a string containing the function name.- Overrides:
toStringin classASTFunNode
-
getName
Returns the name of the node (operator symbol or function name).- Specified by:
getNamein interfaceNode- Overrides:
getNamein classASTFunNode- Returns:
- the name if an ASTVarNode, ASTFunNode, ASTOpNode, null otherwise
-
getOperator
Returns the id number of the operator if the node is an operator.- Specified by:
getOperatorin interfaceNode- Overrides:
getOperatorin classASTFunNode- Returns:
- The Operator for ASTOpNodes, null otherwise
-