Class AbstractMapDecorator
java.lang.Object
org.apache.commons.collections.map.AbstractMapDecorator
- All Implemented Interfaces:
Map
- Direct Known Subclasses:
AbstractBidiMapDecorator,AbstractOrderedMapDecorator,AbstractSortedMapDecorator,DefaultedMap,FixedSizeMap,LazyMap,ListOrderedMap,MultiValueMap,PredicatedMap,TransformedMap,UnmodifiableMap
@Deprecated(since="2021-04-30")
public abstract class AbstractMapDecorator
extends Object
implements Map
Deprecated.
Apache Commons Collections version 3.x is being deprecated from AEMaaCS. The upgraded version 4.4 of Commons Collections is already included as replacement. Customers are advised to upgrade to this version of the library. Please note: the package name was changed to org.apache.commons.collections4. Further note that there are AEM APIs currently exposing the old collections classes; these will be updated in upcoming releases.
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
entrySet(), keySet() or values(). 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
-
Nested Class Summary
-
Constructor Summary
ConstructorsConstructorDescriptionAbstractMapDecorator(Map map) Deprecated.Constructor that wraps (not copies). -
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Deprecated.booleancontainsKey(Object key) Deprecated.booleancontainsValue(Object value) Deprecated.entrySet()Deprecated.booleanDeprecated.Deprecated.inthashCode()Deprecated.booleanisEmpty()Deprecated.keySet()Deprecated.Deprecated.voidDeprecated.Deprecated.intsize()Deprecated.toString()Deprecated.values()Deprecated.Methods inherited from interface java.util.Map
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAll
-
Constructor Details
-
AbstractMapDecorator
Deprecated.Constructor that wraps (not copies).- Parameters:
map- the map to decorate, must not be null- Throws:
IllegalArgumentException- if the collection is null
-
-
Method Details
-
clear
public void clear()Deprecated. -
containsKey
Deprecated.- Specified by:
containsKeyin interfaceMap
-
containsValue
Deprecated.- Specified by:
containsValuein interfaceMap
-
entrySet
Deprecated. -
get
Deprecated. -
isEmpty
public boolean isEmpty()Deprecated. -
keySet
Deprecated. -
put
Deprecated. -
putAll
Deprecated. -
remove
Deprecated. -
size
public int size()Deprecated. -
values
Deprecated. -
equals
Deprecated. -
hashCode
public int hashCode()Deprecated. -
toString
Deprecated.
-