Class MultimapSet<K,V>
- java.lang.Object
-
- org.greenrobot.essentials.collections.AbstractMultimap<K,V,java.util.Set<V>>
-
- org.greenrobot.essentials.collections.MultimapSet<K,V>
-
- All Implemented Interfaces:
java.util.Map<K,java.util.Set<V>>
public class MultimapSet<K,V> extends AbstractMultimap<K,V,java.util.Set<V>>
Combines a Map with Set values to provide simple way to store multiple values for a key. LikeMultimap
, but element values are stored in Sets.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static class
MultimapSet.SetType
-
Field Summary
Fields Modifier and Type Field Description private MultimapSet.SetType
setType
-
Fields inherited from class org.greenrobot.essentials.collections.AbstractMultimap
map
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
MultimapSet(java.util.Map<K,java.util.Set<V>> map, MultimapSet.SetType setType)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static <K,V>
MultimapSet<K,V>create()
static <K,V>
MultimapSet<K,V>create(MultimapSet.SetType setType)
protected java.util.Set<V>
createNewCollection()
-
Methods inherited from class org.greenrobot.essentials.collections.AbstractMultimap
clear, containsElement, containsElement, containsKey, containsValue, countElements, countElements, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, putElement, putElements, remove, removeElement, size, values, valuesElements
-
-
-
-
Field Detail
-
setType
private final MultimapSet.SetType setType
-
-
Constructor Detail
-
MultimapSet
protected MultimapSet(java.util.Map<K,java.util.Set<V>> map, MultimapSet.SetType setType)
-
-
Method Detail
-
create
public static <K,V> MultimapSet<K,V> create()
-
create
public static <K,V> MultimapSet<K,V> create(MultimapSet.SetType setType)
-
createNewCollection
protected java.util.Set<V> createNewCollection()
- Specified by:
createNewCollection
in classAbstractMultimap<K,V,java.util.Set<V>>
-
-