Package com.google.common.collect
Class Maps.DescendingMap<K,V>
- java.lang.Object
-
- com.google.common.collect.ForwardingObject
-
- com.google.common.collect.ForwardingMap<K,V>
-
- com.google.common.collect.Maps.DescendingMap<K,V>
-
- All Implemented Interfaces:
java.util.Map<K,V>
,java.util.NavigableMap<K,V>
,java.util.SortedMap<K,V>
- Direct Known Subclasses:
AbstractNavigableMap.DescendingMap
,ForwardingNavigableMap.StandardDescendingMap
- Enclosing class:
- Maps
abstract static class Maps.DescendingMap<K,V> extends ForwardingMap<K,V> implements java.util.NavigableMap<K,V>
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.common.collect.ForwardingMap
ForwardingMap.StandardEntrySet, ForwardingMap.StandardKeySet, ForwardingMap.StandardValues
-
-
Field Summary
Fields Modifier and Type Field Description private java.util.Comparator<? super K>
comparator
private java.util.Set<java.util.Map.Entry<K,V>>
entrySet
private java.util.NavigableSet<K>
navigableKeySet
-
Constructor Summary
Constructors Constructor Description DescendingMap()
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description java.util.Map.Entry<K,V>
ceilingEntry(K key)
K
ceilingKey(K key)
java.util.Comparator<? super K>
comparator()
(package private) java.util.Set<java.util.Map.Entry<K,V>>
createEntrySet()
protected java.util.Map<K,V>
delegate()
Returns the backing delegate instance that methods are forwarded to.java.util.NavigableSet<K>
descendingKeySet()
java.util.NavigableMap<K,V>
descendingMap()
(package private) abstract java.util.Iterator<java.util.Map.Entry<K,V>>
entryIterator()
java.util.Set<java.util.Map.Entry<K,V>>
entrySet()
java.util.Map.Entry<K,V>
firstEntry()
K
firstKey()
java.util.Map.Entry<K,V>
floorEntry(K key)
K
floorKey(K key)
(package private) abstract java.util.NavigableMap<K,V>
forward()
java.util.SortedMap<K,V>
headMap(K toKey)
java.util.NavigableMap<K,V>
headMap(K toKey, boolean inclusive)
java.util.Map.Entry<K,V>
higherEntry(K key)
K
higherKey(K key)
java.util.Set<K>
keySet()
java.util.Map.Entry<K,V>
lastEntry()
K
lastKey()
java.util.Map.Entry<K,V>
lowerEntry(K key)
K
lowerKey(K key)
java.util.NavigableSet<K>
navigableKeySet()
java.util.Map.Entry<K,V>
pollFirstEntry()
java.util.Map.Entry<K,V>
pollLastEntry()
private static <T> Ordering<T>
reverse(java.util.Comparator<T> forward)
java.util.NavigableMap<K,V>
subMap(K fromKey, boolean fromInclusive, K toKey, boolean toInclusive)
java.util.SortedMap<K,V>
subMap(K fromKey, K toKey)
java.util.SortedMap<K,V>
tailMap(K fromKey)
java.util.NavigableMap<K,V>
tailMap(K fromKey, boolean inclusive)
java.lang.String
toString()
Returns the string representation generated by the delegate'stoString
method.java.util.Collection<V>
values()
-
Methods inherited from class com.google.common.collect.ForwardingMap
clear, containsKey, containsValue, equals, get, hashCode, isEmpty, put, putAll, remove, size, standardClear, standardContainsKey, standardContainsValue, standardEquals, standardHashCode, standardIsEmpty, standardPutAll, standardRemove, standardToString
-
-
-
-
Method Detail
-
delegate
protected final java.util.Map<K,V> delegate()
Description copied from class:ForwardingObject
Returns the backing delegate instance that methods are forwarded to. Abstract subclasses generally override this method with an abstract method that has a more specific return type, such asForwardingSet.delegate()
. Concrete subclasses override this method to supply the instance being decorated.- Specified by:
delegate
in classForwardingMap<K,V>
-
comparator
public java.util.Comparator<? super K> comparator()
-
reverse
private static <T> Ordering<T> reverse(java.util.Comparator<T> forward)
-
keySet
public java.util.Set<K> keySet()
-
navigableKeySet
public java.util.NavigableSet<K> navigableKeySet()
-
descendingKeySet
public java.util.NavigableSet<K> descendingKeySet()
-
subMap
public java.util.NavigableMap<K,V> subMap(K fromKey, boolean fromInclusive, K toKey, boolean toInclusive)
-
values
public java.util.Collection<V> values()
-
toString
public java.lang.String toString()
Description copied from class:ForwardingObject
Returns the string representation generated by the delegate'stoString
method.- Overrides:
toString
in classForwardingObject
-
-