Interface Multimap<K,V>
- Type Parameters:
K- key typeV- value type
- All Known Implementing Classes:
DelegatingMultimap, HashMultimap, HashsetMultimap, TreeMultimap
public interface Multimap<K,V>
Basic Multimap.
-
Method Summary
Modifier and TypeMethodDescriptionvoidclear()Clears the multimapCollection<Map.Entry<K, Collection<V>>> entrySet()Get all associations of the multimap.Get all values associated with the keybooleanisEmpty()Checks if multimap is emptykeys()Keys in the mapvoidvoidPut the element pair.voidputAll(K k, Collection<V> vs) Put multiple pairs.voidvalues()
-
Method Details
-
put
-
putAll
-
get
Get all values associated with the key- Parameters:
key- key- Returns:
- collection of values
-
entrySet
Collection<Map.Entry<K, Collection<V>>> entrySet()Get all associations of the multimap. The method is intended for read-only view.- Returns:
- entry set of the multimap
-
isEmpty
boolean isEmpty()Checks if multimap is empty- Returns:
- true, if empty
-
clear
void clear()Clears the multimap -
keys
-
values
Collection<V> values() -
remove
-
merge
-