K
- the key typeV
- the value element typepublic class LinkedMultiValueMap<K,V> extends MultiValueMapAdapter<K,V> implements java.io.Serializable, java.lang.Cloneable
MultiValueMap
that wraps a LinkedHashMap
,
storing multiple values in a LinkedList
.
This Map implementation is generally not thread-safe. It is primarily designed for data structures exposed from request objects, for use in a single thread only.
Modifier and Type | Field and Description |
---|---|
private static long |
serialVersionUID |
Constructor and Description |
---|
LinkedMultiValueMap()
Create a new LinkedMultiValueMap that wraps a
LinkedHashMap . |
LinkedMultiValueMap(int initialCapacity)
Create a new LinkedMultiValueMap that wraps a
LinkedHashMap
with the given initial capacity. |
LinkedMultiValueMap(java.util.Map<K,java.util.List<V>> otherMap)
Copy constructor: Create a new LinkedMultiValueMap with the same mappings as
the specified Map.
|
Modifier and Type | Method and Description |
---|---|
LinkedMultiValueMap<K,V> |
clone()
Create a regular copy of this Map.
|
LinkedMultiValueMap<K,V> |
deepCopy()
Create a deep copy of this Map.
|
add, addAll, addAll, clear, containsKey, containsValue, entrySet, equals, get, getFirst, hashCode, isEmpty, keySet, put, putAll, remove, set, setAll, size, toSingleValueMap, toString, values
private static final long serialVersionUID
public LinkedMultiValueMap()
LinkedHashMap
.public LinkedMultiValueMap(int initialCapacity)
LinkedHashMap
with the given initial capacity.initialCapacity
- the initial capacitypublic LinkedMultiValueMap(java.util.Map<K,java.util.List<V>> otherMap)
otherMap
- the Map whose mappings are to be placed in this Mapclone()
,
deepCopy()
public LinkedMultiValueMap<K,V> deepCopy()
LinkedList
for each entry)
along the lines of MultiValueMap.addAll
semanticsMultiValueMapAdapter.addAll(MultiValueMap)
,
clone()
public LinkedMultiValueMap<K,V> clone()
clone
in class java.lang.Object
Map.put
semanticsMultiValueMapAdapter.put(Object, List)
,
MultiValueMapAdapter.putAll(Map)
,
LinkedMultiValueMap(Map)
,
deepCopy()