public final class Predicate extends Object
left <operator> right, except
for PredicateKind.NULL_CHECK (which has only a left operand)
and PredicateKind.COMPLEX (which preserves an undecomposed
sub-tree, typically with a single operand).
operator is the verbatim comparison token
(=, <>, >, IS NULL,
IS NOT NULL, BETWEEN, ...). May be null for a
PredicateKind.COMPLEX predicate.leftOperand is non-null.rightOperand is null for PredicateKind.NULL_CHECK
and may be null for PredicateKind.COMPLEX.sourceSpan covers the whole predicate; null when the
parser cannot anchor it.Immutable. Introduced by join-analysis slice 162 (S1); produced by
PredicateTreeBuilder in slice 166 (S5).
| Constructor and Description |
|---|
Predicate(PredicateKind kind,
String operator,
PredicateOperand leftOperand,
PredicateOperand rightOperand,
SourceSpan sourceSpan) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
equals(Object o) |
PredicateKind |
getKind() |
PredicateOperand |
getLeftOperand() |
String |
getOperator()
Verbatim comparison token; may be null for COMPLEX.
|
PredicateOperand |
getRightOperand()
Null for NULL_CHECK; may be null for COMPLEX.
|
SourceSpan |
getSourceSpan()
Optional; null when the parser cannot anchor this predicate.
|
int |
hashCode() |
String |
toString() |
public Predicate(PredicateKind kind, String operator, PredicateOperand leftOperand, PredicateOperand rightOperand, SourceSpan sourceSpan)
public PredicateKind getKind()
public String getOperator()
public PredicateOperand getLeftOperand()
public PredicateOperand getRightOperand()
public SourceSpan getSourceSpan()