Class AbstractSynchronizedMultimap<K,V>
- java.lang.Object
-
- org.eclipse.collections.impl.multimap.AbstractSynchronizedMultimap<K,V>
-
- All Implemented Interfaces:
Multimap<K,V>,MutableMultimap<K,V>
- Direct Known Subclasses:
SynchronizedBagMultimap,SynchronizedListMultimap,SynchronizedSetMultimap,SynchronizedSortedBagMultimap,SynchronizedSortedSetMultimap
public abstract class AbstractSynchronizedMultimap<K,V> extends Object implements MutableMultimap<K,V>
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description booleanadd(Pair<? extends K,? extends V> keyValuePair)voidclear()<K2,V2,R extends MutableMultimap<K2,V2>>
RcollectKeyMultiValues(Function<? super K,? extends K2> keyFunction, Function<? super V,? extends V2> valueFunction, R target)<K2,V2,R extends MutableMultimap<K2,V2>>
RcollectKeysValues(Function2<? super K,? super V,Pair<K2,V2>> function, R target)<V2,R extends MutableMultimap<K,V2>>
RcollectValues(Function<? super V,? extends V2> function, R target)booleancontainsKey(Object key)booleancontainsKeyAndValue(Object key, Object value)booleancontainsValue(Object value)booleanequals(Object obj)voidforEachKey(Procedure<? super K> procedure)voidforEachKeyMultiValues(Procedure2<? super K,? super RichIterable<V>> procedure)voidforEachKeyValue(Procedure2<? super K,? super V> procedure)voidforEachValue(Procedure<? super V> procedure)inthashCode()booleanisEmpty()Bag<K>keyBag()RichIterable<Pair<K,RichIterable<V>>>keyMultiValuePairsView()SetIterable<K>keySet()RichIterable<K>keysView()RichIterable<Pair<K,V>>keyValuePairsView()RichIterable<RichIterable<V>>multiValuesView()booleannotEmpty()booleanput(K key, V value)booleanputAll(K key, Iterable<? extends V> values)<KK extends K,VV extends V>
booleanputAll(Multimap<KK,VV> multimap)booleanputAllPairs(Iterable<? extends Pair<? extends K,? extends V>> pairs)booleanputAllPairs(Pair<? extends K,? extends V>... pairs)<R extends MutableMultimap<K,V>>
RrejectKeysMultiValues(Predicate2<? super K,? super RichIterable<V>> predicate, R target)<R extends MutableMultimap<K,V>>
RrejectKeysValues(Predicate2<? super K,? super V> predicate, R target)booleanremove(Object key, Object value)<R extends MutableMultimap<K,V>>
RselectKeysMultiValues(Predicate2<? super K,? super RichIterable<V>> predicate, R target)<R extends MutableMultimap<K,V>>
RselectKeysValues(Predicate2<? super K,? super V> predicate, R target)intsize()intsizeDistinct()MutableMap<K,RichIterable<V>>toMap()<R extends Collection<V>>
MutableMap<K,R>toMap(Function0<R> collectionFactory)StringtoString()RichIterable<V>valuesView()MutableMultimap<K,V>withKeyMultiValues(K key, V... values)-
Methods inherited from interface org.eclipse.collections.api.multimap.Multimap
toImmutable, toMutable
-
Methods inherited from interface org.eclipse.collections.api.multimap.MutableMultimap
asSynchronized, collectKeyMultiValues, collectKeysValues, collectValues, flip, get, getIfAbsentPutAll, newEmpty, rejectKeysMultiValues, rejectKeysValues, removeAll, replaceValues, selectKeysMultiValues, selectKeysValues, withKeyValue
-
-
-
-
Method Detail
-
equals
public boolean equals(Object obj)
-
hashCode
public int hashCode()
-
add
public boolean add(Pair<? extends K,? extends V> keyValuePair)
- Specified by:
addin interfaceMutableMultimap<K,V>
-
remove
public boolean remove(Object key, Object value)
- Specified by:
removein interfaceMutableMultimap<K,V>
-
withKeyMultiValues
public MutableMultimap<K,V> withKeyMultiValues(K key, V... values)
- Specified by:
withKeyMultiValuesin interfaceMutableMultimap<K,V>
-
putAllPairs
public boolean putAllPairs(Pair<? extends K,? extends V>... pairs)
- Specified by:
putAllPairsin interfaceMutableMultimap<K,V>
-
putAllPairs
public boolean putAllPairs(Iterable<? extends Pair<? extends K,? extends V>> pairs)
- Specified by:
putAllPairsin interfaceMutableMultimap<K,V>
-
putAll
public boolean putAll(K key, Iterable<? extends V> values)
- Specified by:
putAllin interfaceMutableMultimap<K,V>
-
putAll
public <KK extends K,VV extends V> boolean putAll(Multimap<KK,VV> multimap)
- Specified by:
putAllin interfaceMutableMultimap<K,V>
-
clear
public void clear()
- Specified by:
clearin interfaceMutableMultimap<K,V>
-
forEachValue
public void forEachValue(Procedure<? super V> procedure)
- Specified by:
forEachValuein interfaceMultimap<K,V>
-
forEachKey
public void forEachKey(Procedure<? super K> procedure)
- Specified by:
forEachKeyin interfaceMultimap<K,V>
-
forEachKeyValue
public void forEachKeyValue(Procedure2<? super K,? super V> procedure)
- Specified by:
forEachKeyValuein interfaceMultimap<K,V>
-
forEachKeyMultiValues
public void forEachKeyMultiValues(Procedure2<? super K,? super RichIterable<V>> procedure)
- Specified by:
forEachKeyMultiValuesin interfaceMultimap<K,V>
-
sizeDistinct
public int sizeDistinct()
- Specified by:
sizeDistinctin interfaceMultimap<K,V>
-
containsKey
public boolean containsKey(Object key)
- Specified by:
containsKeyin interfaceMultimap<K,V>
-
containsValue
public boolean containsValue(Object value)
- Specified by:
containsValuein interfaceMultimap<K,V>
-
containsKeyAndValue
public boolean containsKeyAndValue(Object key, Object value)
- Specified by:
containsKeyAndValuein interfaceMultimap<K,V>
-
multiValuesView
public RichIterable<RichIterable<V>> multiValuesView()
- Specified by:
multiValuesViewin interfaceMultimap<K,V>
-
valuesView
public RichIterable<V> valuesView()
- Specified by:
valuesViewin interfaceMultimap<K,V>
-
keyMultiValuePairsView
public RichIterable<Pair<K,RichIterable<V>>> keyMultiValuePairsView()
- Specified by:
keyMultiValuePairsViewin interfaceMultimap<K,V>
-
keyValuePairsView
public RichIterable<Pair<K,V>> keyValuePairsView()
- Specified by:
keyValuePairsViewin interfaceMultimap<K,V>
-
toMap
public MutableMap<K,RichIterable<V>> toMap()
-
toMap
public <R extends Collection<V>> MutableMap<K,R> toMap(Function0<R> collectionFactory)
-
selectKeysValues
public <R extends MutableMultimap<K,V>> R selectKeysValues(Predicate2<? super K,? super V> predicate, R target)
- Specified by:
selectKeysValuesin interfaceMultimap<K,V>
-
rejectKeysValues
public <R extends MutableMultimap<K,V>> R rejectKeysValues(Predicate2<? super K,? super V> predicate, R target)
- Specified by:
rejectKeysValuesin interfaceMultimap<K,V>
-
selectKeysMultiValues
public <R extends MutableMultimap<K,V>> R selectKeysMultiValues(Predicate2<? super K,? super RichIterable<V>> predicate, R target)
- Specified by:
selectKeysMultiValuesin interfaceMultimap<K,V>
-
rejectKeysMultiValues
public <R extends MutableMultimap<K,V>> R rejectKeysMultiValues(Predicate2<? super K,? super RichIterable<V>> predicate, R target)
- Specified by:
rejectKeysMultiValuesin interfaceMultimap<K,V>
-
collectKeysValues
public <K2,V2,R extends MutableMultimap<K2,V2>> R collectKeysValues(Function2<? super K,? super V,Pair<K2,V2>> function, R target)
- Specified by:
collectKeysValuesin interfaceMultimap<K,V>
-
collectKeyMultiValues
public <K2,V2,R extends MutableMultimap<K2,V2>> R collectKeyMultiValues(Function<? super K,? extends K2> keyFunction, Function<? super V,? extends V2> valueFunction, R target)
- Specified by:
collectKeyMultiValuesin interfaceMultimap<K,V>
-
collectValues
public <V2,R extends MutableMultimap<K,V2>> R collectValues(Function<? super V,? extends V2> function, R target)
- Specified by:
collectValuesin interfaceMultimap<K,V>
-
-