Class SimpleArithmeticExpr
java.lang.Object
org.n52.svalbard.odata.core.expr.BinaryExpr<FilterConstants.SimpleArithmeticOperator>
org.n52.svalbard.odata.core.expr.arithmetic.SimpleArithmeticExpr
- All Implemented Interfaces:
ODataExpr,ArithmeticExpr,Expr
public class SimpleArithmeticExpr
extends BinaryExpr<FilterConstants.SimpleArithmeticOperator>
implements ArithmeticExpr
-
Constructor Summary
ConstructorsConstructorDescriptionSimpleArithmeticExpr(FilterConstants.SimpleArithmeticOperator operator, ArithmeticExpr left, ArithmeticExpr right) Create a newBinaryExpr. -
Method Summary
Modifier and TypeMethodDescription<T,X extends Throwable>
Taccept(ExprVisitor<T, X> visitor) Acceptsvisitorfor this expression.Get this expression as a arithmetic expressionbooleaninthashCode()booleanCheck if this expression is a arithmetic expresion.Methods inherited from class org.n52.svalbard.odata.core.expr.BinaryExpr
asBinary, getLeft, getOperator, getRight, isBinary, toODataString, toStringMethods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface org.n52.svalbard.odata.core.expr.Expr
asBinary, asBoolean, asBooleanBinary, asBooleanUnary, asComparison, asGeometry, asMember, asMethodCall, asNumericValue, asTextValue, asTime, asUnary, isBinary, isBoolean, isBooleanBinary, isBooleanUnary, isComparison, isGeometry, isMember, isMethodCall, isNumericValue, isTextValue, isTime, isUnaryMethods inherited from interface org.n52.shetland.oasis.odata.ODataExpr
toODataString
-
Constructor Details
-
SimpleArithmeticExpr
public SimpleArithmeticExpr(FilterConstants.SimpleArithmeticOperator operator, ArithmeticExpr left, ArithmeticExpr right) Create a newBinaryExpr.- Parameters:
operator- the operatorleft- the left operandright- the right operand
-
-
Method Details
-
isArithmetic
public boolean isArithmetic()Check if this expression is a arithmetic expresion.- Specified by:
isArithmeticin interfaceArithmeticExpr- Specified by:
isArithmeticin interfaceExpr- Returns:
- if it is a arithmetic expression
-
asArithmetic
Get this expression as a arithmetic expression- Specified by:
asArithmeticin interfaceArithmeticExpr- Specified by:
asArithmeticin interfaceExpr- Returns:
- the expression or
Optional.empty()if the type does not match
-
accept
Acceptsvisitorfor this expression. -
hashCode
public int hashCode()- Overrides:
hashCodein classBinaryExpr<FilterConstants.SimpleArithmeticOperator>
-
equals
- Overrides:
equalsin classBinaryExpr<FilterConstants.SimpleArithmeticOperator>
-