Package org.n52.svalbard.odata.core.expr
Class BinaryExpr<T>
- java.lang.Object
-
- org.n52.svalbard.odata.core.expr.BinaryExpr<T>
-
- Type Parameters:
T- the operator type
- Direct Known Subclasses:
BooleanBinaryExpr,ComparisonExpr,SimpleArithmeticExpr
public abstract class BinaryExpr<T> extends Object implements Expr
Class to hold a binary expression.
-
-
Constructor Summary
Constructors Constructor Description BinaryExpr(T operator, Expr left, Expr right)Create a newBinaryExpr.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Optional<BinaryExpr<?>>asBinary()Get this expression as a binary expressionbooleanequals(Object o)ExprgetLeft()Get the left operand.TgetOperator()Get the operator.ExprgetRight()Get the right operand.inthashCode()booleanisBinary()Check if this expression is a binary expression.StringtoODataString()StringtoString()-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface org.n52.svalbard.odata.core.expr.Expr
accept, asArithmetic, asBoolean, asBooleanBinary, asBooleanUnary, asComparison, asGeometry, asMember, asMethodCall, asNumericValue, asTextValue, asTime, asUnary, isArithmetic, isBoolean, isBooleanBinary, isBooleanUnary, isComparison, isGeometry, isMember, isMethodCall, isNumericValue, isTextValue, isTime, isUnary
-
-
-
-
Method Detail
-
getOperator
public T getOperator()
Get the operator.- Returns:
- the operator
-
getLeft
public Expr getLeft()
Get the left operand.- Returns:
- the left operand
-
getRight
public Expr getRight()
Get the right operand.- Returns:
- the right operand
-
isBinary
public boolean isBinary()
Description copied from interface:ExprCheck if this expression is a binary expression.
-
asBinary
public Optional<BinaryExpr<?>> asBinary()
Description copied from interface:ExprGet this expression as a binary expression
-
toODataString
public String toODataString()
- Specified by:
toODataStringin interfaceODataExpr
-
-