_[Original issue](https://code.google.com/p/guava-libraries/issues/detail?id=1813) created by **j...@nwsnet.de** on 2014-07-23 at 03:21 PM_

---

I didn't find information on the immutability of `Range`&nbsp;instances in the JavaDocs [1]; only the wiki page [2] explicitly states it.

I suggest documenting the immutability directly in the JavaDocs, and thus in the implementation itself.

[1] https://google.github.io/guava/apidocs/com/google/common/collect/Range.html
[2] https://code.google.com/p/guava-libraries/wiki/RangesExplained

(Slightly unrelated: The comments disappeared from the wiki, especially helpful ones which I remembered to be on the page on ranges are gone. I'd like to state that I don't welcome that change.)

}
  /**
   * Returns {@code true} if {@code value} is within the bounds of this range. For example, on the
   * range {@code [0..2)}, {@code contains(1)} returns {@code true}, while {@code contains(2)}
   * returns {@code false}.
   */
  public boolean contains(C value) {
    checkNotNull(value);
    // let this throw CCE if there is some trickery going on
    return lowerBound.isLessThan(value) && !upperBound.isLessThan(value);
  }
  /**
   * @deprecated Provided only to satisfy the {@link Predicate} interface; use {@link #contains}
   *     instead.
   */
  @Deprecated
  @Override
  public boolean apply(C input) {
    return contains(input);
  }
  /**
   * Returns {@code true} if every element in {@code values} is {@linkplain #contains contained} in
   * this range.
   */
  public boolean containsAll(Iterable<? extends C> values) {
    if (Iterables.isEmpty(values)) {
      return true;
    }
    // this optimizes testing equality of two range-backed sets
    if (values instanceof SortedSet) {