public class ConstantNode extends ExpressionNode
constant, constant_value, expressiontext, imports, static_type, text
children, id, parent
Constructor and Description |
---|
ConstantNode(jadex.javaparser.javaccimpl.ParserImpl p,
int id)
Create a node.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object o)
Test if two nodes are equal.
|
java.lang.Object |
getValue(IValueFetcher fetcher)
Evaluate the expression in the given state
with respect to given parameters.
|
int |
hashCode()
Get the hash code for the node.
|
void |
setValue(java.lang.Object value)
Set the constant value.
|
java.lang.String |
toPlainString()
Create a string representation of this node and its subnodes.
|
java.lang.String |
toString(java.lang.String prefix)
Create a string representation of this node for dumping in a tree.
|
appendText, getConstantValue, getExpressionText, getParameters, getStaticType, getText, getUnboundParameterNodes, isConstant, precompile, precompileTree, setConstant, setConstantValue, setExpressionText, setStaticType, setText, subnodeToString, throwEvaluationException, throwParseException, toString
dump, jjtAddChild, jjtClose, jjtGetChild, jjtGetNumChildren, jjtGetParent, jjtOpen, jjtSetParent
public ConstantNode(jadex.javaparser.javaccimpl.ParserImpl p, int id)
p
- The parser.id
- The id.public void setValue(java.lang.Object value)
value
- The constant value.public java.lang.Object getValue(IValueFetcher fetcher)
getValue
in interface IParsedExpression
getValue
in class ExpressionNode
params
- The parameters (string, value pairs), if any.public java.lang.String toPlainString()
toPlainString
in interface Node
toPlainString
in class ExpressionNode
public java.lang.String toString(java.lang.String prefix)
toString
in class ExpressionNode
public boolean equals(java.lang.Object o)
equals
in class ExpressionNode
public int hashCode()
hashCode
in class ExpressionNode