Class AbstractSortedMapDecorator
- java.lang.Object
-
- org.apache.commons.collections.map.AbstractMapDecorator
-
- org.apache.commons.collections.map.AbstractSortedMapDecorator
-
- Direct Known Subclasses:
FixedSizeSortedMap
,UnmodifiableSortedMap
@Deprecated(since="2021-04-30") public abstract class AbstractSortedMapDecorator extends AbstractMapDecorator implements SortedMap
Deprecated.Commons Collections 3 is in maintenance mode. Commons Collections 4 should be used instead.Provides a base decorator that enables additional functionality to be added to a Map via decoration.Methods are forwarded directly to the decorated map.
This implementation does not perform any special processing with the map views. Instead it simply returns the set/collection from the wrapped map. This may be undesirable, for example if you are trying to write a validating implementation it would provide a loophole around the validation. But, you might want that loophole, so this class is kept simple.
- Since:
- Commons Collections 3.0
-
-
Constructor Summary
Constructors Constructor Description AbstractSortedMapDecorator(SortedMap map)
Deprecated.Constructor that wraps (not copies).
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description Comparator
comparator()
Deprecated.Object
firstKey()
Deprecated.SortedMap
headMap(Object toKey)
Deprecated.Object
lastKey()
Deprecated.SortedMap
subMap(Object fromKey, Object toKey)
Deprecated.SortedMap
tailMap(Object fromKey)
Deprecated.-
Methods inherited from class org.apache.commons.collections.map.AbstractMapDecorator
clear, containsKey, containsValue, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, remove, size, toString, values
-
Methods inherited from interface java.util.Map
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, equals, forEach, get, getOrDefault, hashCode, isEmpty, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size
-
-
-
-
Constructor Detail
-
AbstractSortedMapDecorator
public AbstractSortedMapDecorator(SortedMap map)
Deprecated.Constructor that wraps (not copies).- Parameters:
map
- the map to decorate, must not be null- Throws:
IllegalArgumentException
- if the collection is null
-
-
Method Detail
-
comparator
public Comparator comparator()
Deprecated.- Specified by:
comparator
in interfaceSortedMap
-
-