public interface MultiValueMap<K,V> extends Map<K,List<V>>
Map
interface that stores multiple values.Modifier and Type | Method and Description |
---|---|
void |
add(K key,
V value)
Add the given single value to the current list of values for the given key.
|
V |
getFirst(K key)
Return the first value for the given key.
|
void |
set(K key,
V value)
Set the given single value under the given key.
|
void |
setAll(Map<K,V> values)
Set the given values under.
|
Map<K,V> |
toSingleValueMap()
Returns the first values contained in this
MultiValueMap . |
V getFirst(K key)
key
- the keynull
void add(K key, V value)
key
- the keyvalue
- the value to be addedvoid set(K key, V value)
key
- the keyvalue
- the value to set