MultiValueMap.
| Modifier and Type | Class and Description |
|---|---|
| private static class | |
| private static class |
| Modifier and Type | Field and Description |
|---|---|
| private final MultiValueMap | |
| private transient Set | |
| private transient Set | |
| private static final long | |
| private transient Collection |
| Access | Constructor and Description |
|---|---|
| public |
| Modifier and Type | Method and Description |
|---|---|
| public void | add(K
the key key, V the value to be added value)Implements org. Add the given single value to the current list of values for the given key. |
| public void | addAll(K
they key key, List<? extends V> the values to be added values)Implements org. Add all the values of the given list to the current list of values for the given key. |
| public void | addAll(MultiValueMap<K, V>
the values to be added values)Implements org. Add all the values of the given |
| public void | addIfAbsent(K
the key key, V the value to be added value)Overrides default org.
|
| public void | clear()
Implements java. Removes all of the mappings from this map (optional operation). |
| public List | compute(K
key with which the specified value is to be associated key, BiFunction<? super K, ? super List<V>, ? extends List<V>> the remapping function to compute a value remappingFunction)Overrides default java. Attempts to compute a mapping for the specified key and its current
mapped value, or |
| public List | computeIfAbsent(K
key with which the specified value is to be associated key, Function<? super K, ? extends List<V>> the mapping function to compute a value mappingFunction)Overrides default java. If the specified key is not already associated with a value (or is mapped
to |
| public List | computeIfPresent(K
key with which the specified value is to be associated key, BiFunction<? super K, ? super List<V>, ? extends List<V>> the remapping function to compute a value remappingFunction)Overrides default java. If the value for the specified key is present and non-null, attempts to compute a new mapping given the key and its current mapped value (optional operation). |
| public boolean | containsKey(Object
key whose presence in this map is to be tested key)Implements java. Returns |
| public boolean | containsValue(Object
value whose presence in this map is to be tested value)Implements java. Returns |
| public Set | entrySet()
Implements java. Returns a |
| public boolean | equals(Object
object to be compared for equality with this map other)Overrides java. Implements java. Compares the specified object with this map for equality. |
| public void | forEach(BiConsumer<? super K, ? super List<V>>
The action to be performed for each entry action)Overrides default java. Performs the given action for each entry in this map until all entries have been processed or the action throws an exception. |
| public List | get(Object
the key whose associated value is to be returned key)Implements java. Returns the value to which the specified key is mapped,
or |
| public V | getFirst(K
the key key)Implements org. Return the first value for the given key. |
| public List | getOrDefault(Object
the key whose associated value is to be returned key, List<V> the default mapping of the key defaultValue)Overrides default java. Returns the value to which the specified key is mapped, or
|
| public int | hashCode()
Overrides java. Implements java. Returns the hash code value for this map. |
| public boolean | |
| public Set | |
| public List | merge(K
key with which the resulting value is to be associated key, List<V> the non-null value to be merged with the existing value
associated with the key or, if no existing value or a null value
is associated with the key, to be associated with the key value, BiFunction<? super List<V>, ? super List<V>, ? extends List<V>> the remapping function to recompute a value if
present remappingFunction)Overrides default java. If the specified key is not already associated with a value or is associated with null, associates it with the given non-null value (optional operation). |
| public List | put(K
key with which the specified value is to be associated key, List<V> value to be associated with the specified key value)Implements java. Associates the specified value with the specified key in this map (optional operation). |
| public void | putAll(Map<? extends K, ? extends List<V>>
mappings to be stored in this map m)Implements java. Copies all of the mappings from the specified map to this map (optional operation). |
| public List | putIfAbsent(K
key with which the specified value is to be associated key, List<V> value to be associated with the specified key value)Overrides default java. If the specified key is not already associated with a value (or is mapped
to |
| public List | remove(Object
key whose mapping is to be removed from the map key)Implements java. Removes the mapping for a key from this map if it is present (optional operation). |
| public boolean | remove(Object
key with which the specified value is associated key, Object value expected to be associated with the specified key value)Overrides default java. Removes the entry for the specified key only if it is currently mapped to the specified value (optional operation). |
| public boolean | replace(K
key with which the specified value is associated key, List<V> value expected to be associated with the specified key oldValue, List<V> value to be associated with the specified key newValue)Overrides default java. Replaces the entry for the specified key only if currently mapped to the specified value (optional operation). |
| public List | replace(K
key with which the specified value is associated key, List<V> value to be associated with the specified key value)Overrides default java. Replaces the entry for the specified key only if it is currently mapped to some value (optional operation). |
| public void | replaceAll(BiFunction<? super K, ? super List<V>, ? extends List<V>>
the function to apply to each entry function)Overrides default java. Replaces each entry's value with the result of invoking the given function on that entry until all entries have been processed or the function throws an exception (optional operation). |
| public void | set(K
the key key, V the value to set value)Implements org. Set the given single value under the given key. |
| public void | setAll(Map<K, V>
the values. values)Implements org. Set the given values under. |
| public int | |
| public Map | toSingleValueMap()
Implements org. Return a |
| public String | |
| public Collection | values()
Implements java. Returns a |