| Package | Description | 
|---|---|
| java.util | Contains the collections framework, legacy collection classes, event model,
date and time facilities, internationalization, and miscellaneous utility
classes (a string tokenizer, a random-number generator, and a bit array). | 
| java.util.concurrent | Utility classes commonly useful in concurrent programming. | 
| Modifier and Type | Class and Description | 
|---|---|
| class  | TreeSet<E>A  NavigableSetimplementation based on aTreeMap. | 
| Modifier and Type | Method and Description | 
|---|---|
| static <E> NavigableSet<E> | Collections. checkedNavigableSet(NavigableSet<E> s,
                   Class<E> type)Returns a dynamically typesafe view of the specified navigable set. | 
| NavigableSet<K> | TreeMap. descendingKeySet() | 
| NavigableSet<K> | NavigableMap. descendingKeySet()Returns a reverse order  NavigableSetview of the keys contained in this map. | 
| NavigableSet<E> | TreeSet. descendingSet() | 
| NavigableSet<E> | NavigableSet. descendingSet()Returns a reverse order view of the elements contained in this set. | 
| static <E> NavigableSet<E> | Collections. emptyNavigableSet()Returns an empty navigable set (immutable). | 
| NavigableSet<E> | TreeSet. headSet(E toElement,
       boolean inclusive) | 
| NavigableSet<E> | NavigableSet. headSet(E toElement,
       boolean inclusive)Returns a view of the portion of this set whose elements are less than
 (or equal to, if  inclusiveis true)toElement. | 
| NavigableSet<K> | TreeMap. navigableKeySet() | 
| NavigableSet<K> | NavigableMap. navigableKeySet()Returns a  NavigableSetview of the keys contained in this map. | 
| NavigableSet<E> | TreeSet. subSet(E fromElement,
      boolean fromInclusive,
      E toElement,
      boolean toInclusive) | 
| NavigableSet<E> | NavigableSet. subSet(E fromElement,
      boolean fromInclusive,
      E toElement,
      boolean toInclusive)Returns a view of the portion of this set whose elements range from
  fromElementtotoElement. | 
| static <T> NavigableSet<T> | Collections. synchronizedNavigableSet(NavigableSet<T> s)Returns a synchronized (thread-safe) navigable set backed by the
 specified navigable set. | 
| NavigableSet<E> | TreeSet. tailSet(E fromElement,
       boolean inclusive) | 
| NavigableSet<E> | NavigableSet. tailSet(E fromElement,
       boolean inclusive)Returns a view of the portion of this set whose elements are greater
 than (or equal to, if  inclusiveis true)fromElement. | 
| static <T> NavigableSet<T> | Collections. unmodifiableNavigableSet(NavigableSet<T> s)Returns an unmodifiable view of the specified navigable set. | 
| Modifier and Type | Method and Description | 
|---|---|
| static <E> NavigableSet<E> | Collections. checkedNavigableSet(NavigableSet<E> s,
                   Class<E> type)Returns a dynamically typesafe view of the specified navigable set. | 
| static <T> NavigableSet<T> | Collections. synchronizedNavigableSet(NavigableSet<T> s)Returns a synchronized (thread-safe) navigable set backed by the
 specified navigable set. | 
| static <T> NavigableSet<T> | Collections. unmodifiableNavigableSet(NavigableSet<T> s)Returns an unmodifiable view of the specified navigable set. | 
| Modifier and Type | Class and Description | 
|---|---|
| class  | ConcurrentSkipListSet<E>A scalable concurrent  NavigableSetimplementation based on
 aConcurrentSkipListMap. | 
| Modifier and Type | Method and Description | 
|---|---|
| NavigableSet<K> | ConcurrentSkipListMap. descendingKeySet() | 
| NavigableSet<K> | ConcurrentNavigableMap. descendingKeySet()Returns a reverse order  NavigableSetview of the keys contained in this map. | 
| NavigableSet<E> | ConcurrentSkipListSet. descendingSet()Returns a reverse order view of the elements contained in this set. | 
| NavigableSet<E> | ConcurrentSkipListSet. headSet(E toElement) | 
| NavigableSet<E> | ConcurrentSkipListSet. headSet(E toElement,
       boolean inclusive) | 
| NavigableSet<K> | ConcurrentSkipListMap. keySet()Returns a  NavigableSetview of the keys contained in this map. | 
| NavigableSet<K> | ConcurrentNavigableMap. keySet()Returns a  NavigableSetview of the keys contained in this map. | 
| NavigableSet<K> | ConcurrentSkipListMap. navigableKeySet() | 
| NavigableSet<K> | ConcurrentNavigableMap. navigableKeySet()Returns a  NavigableSetview of the keys contained in this map. | 
| NavigableSet<E> | ConcurrentSkipListSet. subSet(E fromElement,
      boolean fromInclusive,
      E toElement,
      boolean toInclusive) | 
| NavigableSet<E> | ConcurrentSkipListSet. subSet(E fromElement,
      E toElement) | 
| NavigableSet<E> | ConcurrentSkipListSet. tailSet(E fromElement) | 
| NavigableSet<E> | ConcurrentSkipListSet. tailSet(E fromElement,
       boolean inclusive) | 
 Submit a bug or feature 
For further API reference and developer documentation, see Java SE Documentation. That documentation contains more detailed, developer-targeted descriptions, with conceptual overviews, definitions of terms, workarounds, and working code examples.
 Copyright © 1993, 2025, Oracle and/or its affiliates.  All rights reserved. Use is subject to license terms. Also see the documentation redistribution policy.