class ArithmeticExpression extends BinaryExpression
operator, p1, p2
staticContext
Constructor and Description |
---|
ArithmeticExpression() |
ArithmeticExpression(Expression p1,
int operator,
Expression p2) |
Modifier and Type | Method and Description |
---|---|
Value |
evaluate(Context c)
Evaluate an expression.
|
double |
evaluateAsNumber(Context c)
Evaluate an expression as a Number.
|
int |
getDataType()
Determine the data type of the expression, if possible
|
Expression |
reduce(int dependencies,
Context context)
Perform a partial evaluation of the expression, by eliminating specified dependencies
on the context.
|
display, getDependencies, setDetails, simplify
containsReferences, enumerate, evaluateAsBoolean, evaluateAsNodeSet, evaluateAsString, getStaticContext, indent, isContextDocumentNodeSet, make, outputStringValue, setStaticContext, usesCurrent
public ArithmeticExpression()
public ArithmeticExpression(Expression p1, int operator, Expression p2)
public Value evaluate(Context c) throws XPathException
evaluate
in class Expression
context
- The context in which the expression is to be evaluatedXPathException
public double evaluateAsNumber(Context c) throws XPathException
evaluateAsNumber
in class Expression
context
- The context in which the expression is to be evaluatedXPathException
public int getDataType()
getDataType
in class Expression
public Expression reduce(int dependencies, Context context) throws XPathException
reduce
in class Expression
dependencies
- The dependencies to be removedcontext
- The context to be used for the partial evaluationXPathException