/** * Tests if this range intersects another range. Two ranges intersect if * there is at least one value, x, for which contains(x) returns true * for both ranges * * @param other the range to check for intersection * @return {@code true} if the ranges intersect; {@code false} otherwise */ public boolean intersects(Range<T> other) { RangeExtendedComparator.Result comp = this.compareTo(other); return RangeExtendedComparator.isIntersection(comp); }
Range r2 = rr.get(i + 1); RangeExtendedComparator.Result result = rc.compare(r1, r2); if (RangeExtendedComparator.isIntersection(result)) { ok = false; msg.append(paramNames[RANGES_ARG]).append(" arg can't contain intersecting ranges");
Range<T> r2 = inputs.get(j); RangeExtendedComparator.Result result = comparator.compare(r1, r2); if (RangeExtendedComparator.isIntersection(result)) { switch (result) { case EEEE: // r1 and r2 are equal points
if (RangeExtendedComparator.isIntersection(result)) { T min; boolean minIncluded;