Tuple2 with two times the same type.
Ranges can be (partially) unbounded if one or both of their bounds are null,
which corresponds to "infinity", if T is a type that doesn't already have an
infinity value, such as Double#POSITIVE_INFINITY or Double#NEGATIVE_INFINITY.
Ranges are inclusive on both bounds.
| Modifier and Type | Field and Description |
|---|---|
| private static final long |
| Access | Constructor and Description |
|---|---|
| public | |
| public |
| Modifier and Type | Method and Description |
|---|---|
| public boolean | |
| public boolean | |
| public Optional | intersect(Tuple2<T, T> other)
Deprecated
- Use
intersect(Range) instead.
The intersection of two ranges. |
| public Optional | |
| public Optional | |
| public boolean | |
| public boolean | |
| public boolean | |
| private static <T extends Comparable |
| serialVersionUID | back to summary |
|---|---|
| private static final long serialVersionUID | |
| Range | back to summary |
|---|---|
| public Range(T lowerInclusive, T upperInclusive) | |
| Range | back to summary |
|---|---|
| public Range(Tuple2<T, T> tuple) | |
| contains | back to summary |
|---|---|
| public boolean contains(T t) Whether a value is contained in this range.
| |
| contains | back to summary |
|---|---|
| public boolean contains(Range<T> other) Whether a range is contained in this range.
| |
| intersect | back to summary |
|---|---|
| public Optional Deprecated - Use The intersection of two ranges.
| |
| intersect | back to summary |
|---|---|
| public Optional The intersection of two ranges.
| |
| intersect | back to summary |
|---|---|
| public Optional The intersection of two ranges.
| |
| overlaps | back to summary |
|---|---|
| public boolean overlaps(Tuple2<T, T> other)
Deprecated - Use Whether two ranges overlap.
| |
| overlaps | back to summary |
|---|---|
| public boolean overlaps(Range<T> other) Whether two ranges overlap.
| |
| overlaps | back to summary |
|---|---|
| public boolean overlaps(T lowerInclusive, T upperInclusive) Whether two ranges overlap.
| |
| r | back to summary |
|---|---|
| private static <T extends Comparable | |