Class ForwardingSortedMap.StandardKeySet
java.lang.Object
java.util.AbstractCollection<K>
java.util.AbstractSet<K>
com.google.common.collect.ForwardingSortedMap.StandardKeySet
- All Implemented Interfaces:
Iterable<K>, Collection<K>, SequencedCollection<K>, SequencedSet<K>, Set<K>, SortedSet<K>
A sensible implementation of
SortedMap.keySet()
in terms of the methods of
ForwardingSortedMap
. In many cases, you may wish to override ForwardingMap.keySet()
to forward to this implementation or a subclass thereof.- Since:
- 15.0
- Author:
- Mike Bostock, Louis Wasserman
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
clear()
@Nullable Comparator
<? super K> boolean
first()
void
boolean
isEmpty()
iterator()
last()
boolean
boolean
removeAll
(Collection<?> c) boolean
retainAll
(Collection<?> c) int
size()
Methods inherited from class AbstractSet
equals, hashCode
Methods inherited from class AbstractCollection
add, addAll, containsAll, toArray, toArray, toString
Methods inherited from interface Collection
parallelStream, removeIf, stream, toArray
Methods inherited from interface Set
add, addAll, clear, contains, containsAll, equals, hashCode, isEmpty, iterator, remove, removeAll, retainAll, size, toArray, toArray
Methods inherited from interface SortedSet
addFirst, addLast, getFirst, getLast, removeFirst, removeLast, reversed, spliterator
-
Constructor Details
-
StandardKeySet
public StandardKeySet()Constructor for use by subclasses.
-
-
Method Details
-
comparator
- Specified by:
comparator
in interfaceSortedSet<K extends @Nullable Object>
-
subSet
-
headSet
-
tailSet
-
first
-
last
-
iterator
-
forEach
-
size
-
isEmpty
-
contains
-
remove
-
clear
-
removeAll
-
retainAll
-