public abstract class Expression.Comparator extends Expression.Operator
Constructor and Description |
---|
Comparator(String oper,
int precedence) |
Modifier and Type | Method and Description |
---|---|
abstract boolean |
compare(Comparable v1,
Comparable v2)
This method actually implements the comparison.
|
BigDecimal |
eval(BigDecimal v1,
BigDecimal v2)
Implementation for this operator.
|
Object |
eval(String v1,
String v2) |
eval, getOper, getPrecedence, isLeftAssoc, toString
public Comparator(String oper, int precedence)
public BigDecimal eval(BigDecimal v1, BigDecimal v2)
Expression.Operator
eval
in class Expression.Operator
v1
- Operand 1.v2
- Operand 2.public Object eval(String v1, String v2)
eval
in class Expression.Operator
public abstract boolean compare(Comparable v1, Comparable v2)
v1
- Operand 1.v2
- Operand 2.Copyright © 2006–2019 The Apache Software Foundation. All rights reserved.