org.apache.commons.jxpath.ri.compiler
Class Constant
java.lang.Object
org.apache.commons.jxpath.ri.compiler.Expression
org.apache.commons.jxpath.ri.compiler.Constant
- public class Constant
- extends Expression
A compile tree element containing a constant number or string.
- Version:
- $Revision: 1.8 $ $Date: 2004/02/29 14:17:39 $
- Author:
- Dmitri Plotnikov
Field Summary |
private java.lang.Object |
value
|
Constructor Summary |
Constant(java.lang.Number number)
|
Constant(java.lang.String string)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
value
private java.lang.Object value
Constant
public Constant(java.lang.Number number)
Constant
public Constant(java.lang.String string)
compute
public java.lang.Object compute(EvalContext context)
- Specified by:
compute
in class Expression
computeValue
public java.lang.Object computeValue(EvalContext context)
- Returns the value of the constant.
- Specified by:
computeValue
in class Expression
isContextDependent
public boolean isContextDependent()
- Returns false
- Overrides:
isContextDependent
in class Expression
computeContextDependent
public boolean computeContextDependent()
- Returns false
- Specified by:
computeContextDependent
in class Expression
toString
public java.lang.String toString()