Class of android.util · Range.java · Android's reference
public final class Range<T extends Comparable<? super T>>
An immutable range of comparable values, with both ends inclusive.
public Range(T lower, T upper) sourcepublic static <T extends Comparable<? super T>> Range<T> create(T lower, T upper) sourcepublic T getLower() sourcepublic T getUpper() sourcepublic boolean contains(T value) sourcepublic boolean contains(Range<T> range) sourcepublic T clamp(T value) sourcepublic Range<T> intersect(Range<T> range) sourceThe common part of the two ranges. They must overlap.
public Range<T> intersect(T lower, T upper) sourcepublic Range<T> extend(Range<T> range) sourceThe smallest range that holds both ranges.
public Range<T> extend(T lower, T upper) sourcepublic Range<T> extend(T value) sourcepublic boolean equals(Object o) sourcepublic int hashCode() sourcepublic String toString() sourceMade from ScarletNX's Sail at 166ad3910f80. The framework is ScarletNX's (GPL-3.0-or-later); the parts that follow the Android Open Source Project's sources (Apache-2.0) say so in their files.