Multimap that can hold duplicate key-value pairs and that maintains the insertion
ordering of values for a given key. See the Multimap documentation for information common
to all multimaps.
The get, removeAll, and replaceValues methods each return a List of values. Though the method signature doesn't say so explicitly, the map returned by
asMap has List values.
See the Guava User Guide article on Multimap.
| Modifier and Type | Method and Description |
|---|---|
| public Map | asMap()
Redeclares com. Map from each distinct key to the nonempty
collection of that key's associated values.
|
| public boolean | equals(Object obj)
Redeclares com. |
| public List | get(K key)
Redeclares com. key in this multimap, if any.
|
| public List | removeAll(Object key)
Redeclares com. key.
|
| public List | replaceValues(K key, Iterable<? extends V> values)
Redeclares com. |
| asMap | back to summary |
|---|---|
| public Map Redeclares com. Doc from com. Returns a view of this multimap as a Changes to the returned map or the collections that serve as its values will update the
underlying multimap, and vice versa. The map does not support Note The returned map's values are guaranteed to be of type
| |
| equals | back to summary |
|---|---|
| public boolean equals(Object obj) Redeclares com. Compares the specified object to this multimap for equality. Two An empty
| |
| get | back to summary |
|---|---|
| public List Redeclares com. Doc from com. Returns a view collection of the values associated with Changes to the returned collection will update the underlying multimap, and vice versa. Because the values for a given key may have duplicates and follow the insertion ordering,
this method returns a
| |
| removeAll | back to summary |
|---|---|
| public List Redeclares com. Doc from com. Removes all values associated with the key Once this method returns, Because the values for a given key may have duplicates and follow the insertion ordering,
this method returns a
| |
| replaceValues | back to summary |
|---|---|
| public List Redeclares com. Doc from com. Stores a collection of values with the same key, replacing any existing values for that key. If Because the values for a given key may have duplicates and follow the insertion ordering,
this method returns a
| |