@Override public final void setBound(Operator operator, Term t) throws InvalidRequestException { Bound b; boolean inclusive; switch (operator) { case GT: b = Bound.START; inclusive = false; break; case GTE: b = Bound.START; inclusive = true; break; case LT: b = Bound.END; inclusive = false; break; case LTE: b = Bound.END; inclusive = true; break; default: throw new AssertionError(); } setBound(b, inclusive, t); }
((SingleColumnRestriction.Slice) existingRestriction).setBound(newRel.operator(), t);
public void setBound(Restriction.Slice slice) throws InvalidRequestException { for (Bound bound : Bound.values()) if (slice.hasBound(bound)) setBound(bound, slice.isInclusive(bound), slice.bound(bound)); }