Interface Operator
-
public interface OperatorRepresents an Logical or Mathimatical Operator that operates on binary expressions.- Version:
- $Revision: 3957 $
- Author:
- Keith Visco
-
-
Field Summary
Fields Modifier and Type Field Description static intADD_OPERATORThe add operator typestatic intAND_OPERATORThe and operator typestatic intDIVIDE_OPERATORThe divide operator typestatic intEQUALITY_OPERATORThe "equality" operator typestatic intMODULUS_OPERATORThe modulus operator typestatic intMULTIPLY_OPERATORThe multiply operator typestatic intOR_OPERATORThe or operator typestatic intQUOTIENT_OPERATORThe quotient operator typestatic intSUBTRACT_OPERATORThe subtract operator type
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description XPathResultexecute(XPathExpression left, XPathExpression right, XPathContext context)Executes this operator on the given expressionsXPathResultexecute(XPathResult left, XPathResult right)Executes this operator on the given XPath valuesintgetOperatorType()Returns the type for this Operator.
-
-
-
Field Detail
-
ADD_OPERATOR
static final int ADD_OPERATOR
The add operator type- See Also:
- Constant Field Values
-
AND_OPERATOR
static final int AND_OPERATOR
The and operator type- See Also:
- Constant Field Values
-
DIVIDE_OPERATOR
static final int DIVIDE_OPERATOR
The divide operator type- See Also:
- Constant Field Values
-
EQUALITY_OPERATOR
static final int EQUALITY_OPERATOR
The "equality" operator type- See Also:
- Constant Field Values
-
MODULUS_OPERATOR
static final int MODULUS_OPERATOR
The modulus operator type- See Also:
- Constant Field Values
-
MULTIPLY_OPERATOR
static final int MULTIPLY_OPERATOR
The multiply operator type- See Also:
- Constant Field Values
-
OR_OPERATOR
static final int OR_OPERATOR
The or operator type- See Also:
- Constant Field Values
-
QUOTIENT_OPERATOR
static final int QUOTIENT_OPERATOR
The quotient operator type- See Also:
- Constant Field Values
-
SUBTRACT_OPERATOR
static final int SUBTRACT_OPERATOR
The subtract operator type- See Also:
- Constant Field Values
-
-
Method Detail
-
getOperatorType
int getOperatorType()
Returns the type for this Operator. The operator type may be one of the pre-defined types, or a user-defined type.- Returns:
- the operator type
-
execute
XPathResult execute(XPathExpression left, XPathExpression right, XPathContext context) throws XPathException
Executes this operator on the given expressions- Parameters:
left- the left-side expressionright- the right-side expressioncontext- the XPathContext- Returns:
- the XPathResult
- Throws:
XPathException- when an error occurs during execution
-
execute
XPathResult execute(XPathResult left, XPathResult right) throws XPathException
Executes this operator on the given XPath values- Parameters:
left- the left-side expressionright- the right-side expression- Returns:
- the XPathResult
- Throws:
XPathException- when an error occurs during execution
-
-