public class NumericExpressionEvaluator extends AbstractComparableExpressionEvaluator<Comparable>
BTGOperands, the value provider of which returns a
subtype of Number.| Modifier and Type | Field and Description |
|---|---|
static String |
EQUALS |
static String |
GREATER_OR_EQUALS |
static String |
GREATER_THAN |
static String |
LESS_OR_EQUALS |
static String |
LESS_THAN |
static String |
NOT_EQUALS |
allowLeftNull, LEFT_OP_MISSING, LEFT_OP_NOT_SUPPORTED, OPERATOR_MISSING, OPERATOR_NOT_SUPPORTED, RIGHT_OP_MISSING, RIGHT_OP_NOT_ALLOWED, RIGHT_OP_NOT_SUPPORTED| Constructor and Description |
|---|
NumericExpressionEvaluator(Class<? extends Number> numberType)
Constructor
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
evaluateTerm(Object leftOperand,
String operator,
Object rightOperand)
Evaluates this expression without any error or validation checking.
|
protected String |
getEqualOperator() |
protected String |
getGreaterThanOperator() |
protected String |
getGreaterThanOrEqualOperator() |
protected String |
getLessThanOperator() |
protected String |
getLessThanOrEqualOperator() |
protected String |
getNotEqualOperator() |
Collection<Class> |
getSupportedRightTypes(String operator)
Returns a Collection of types which are supported as right Operand.
|
evaluateComparableaddSupportedOperator, addSupportedOperator, addSupportedOperator, evaluate, getLeftType, getSupportedOperators, isSupported, isSupportedpublic static final String LESS_THAN
public static final String LESS_OR_EQUALS
public static final String GREATER_THAN
public static final String GREATER_OR_EQUALS
public static final String EQUALS
public static final String NOT_EQUALS
public Collection<Class> getSupportedRightTypes(String operator)
ExpressionEvaluatorgetSupportedRightTypes in interface ExpressionEvaluatorgetSupportedRightTypes in class AbstractExpressionEvaluatoroperator - the operator which shall be appliedpublic boolean evaluateTerm(Object leftOperand, String operator, Object rightOperand)
AbstractExpressionEvaluatorevaluateTerm in class AbstractExpressionEvaluatorleftOperand - value for left operandoperator - operator symbolrightOperand - value for right operandprotected String getLessThanOperator()
getLessThanOperator in class AbstractComparableExpressionEvaluator<Comparable>protected String getLessThanOrEqualOperator()
getLessThanOrEqualOperator in class AbstractComparableExpressionEvaluator<Comparable>protected String getGreaterThanOperator()
getGreaterThanOperator in class AbstractComparableExpressionEvaluator<Comparable>protected String getGreaterThanOrEqualOperator()
getGreaterThanOrEqualOperator in class AbstractComparableExpressionEvaluator<Comparable>protected String getEqualOperator()
getEqualOperator in class AbstractComparableExpressionEvaluator<Comparable>protected String getNotEqualOperator()
getNotEqualOperator in class AbstractComparableExpressionEvaluator<Comparable>Copyright © 2017 SAP SE. All Rights Reserved.