KEYTYPE - Key typeVALUETYPE - Element typeCOLLTYPE - Container type containing value typespublic interface IMultiMap<KEYTYPE,VALUETYPE,COLLTYPE extends com.helger.commons.collection.impl.ICommonsCollection<VALUETYPE>>
extends com.helger.commons.collection.impl.ICommonsMap<KEYTYPE,COLLTYPE>
| Modifier and Type | Method and Description |
|---|---|
default boolean |
containsSingle(KEYTYPE aKey,
VALUETYPE aValue)
Check a single element from the container identified by the passed key is
present.
|
default void |
forEachSingle(BiConsumer<? super KEYTYPE,? super VALUETYPE> aConsumer) |
default void |
forEachSingleValue(Consumer<? super VALUETYPE> aConsumer) |
COLLTYPE |
getOrCreate(KEYTYPE aKey)
Get or create the collection of the specified key.
|
default long |
getTotalValueCount() |
default com.helger.commons.state.EChange |
putAllIn(Map<? extends KEYTYPE,? extends VALUETYPE> aMap)
Add all values into the container identified by the passed key-value-map.
|
default com.helger.commons.state.EChange |
putSingle(KEYTYPE aKey,
VALUETYPE aValue)
Add a single value into the container identified by the passed key.
|
default com.helger.commons.state.EChange |
removeSingle(KEYTYPE aKey,
VALUETYPE aValue)
Remove a single element from the container identified by the passed key.
|
addAll, containsAnyEntry, containsAnyKey, containsAnyValue, copyOfEntrySet, copyOfKeySet, copyOfKeySet, copyOfValues, copyOfValues, copyOfValuesMapped, copyOfValuesMapped, createInstance, findFirstEntry, findFirstKey, findFirstValue, forEach, forEachKey, forEachKey, forEachValue, forEachValue, getAsUnmodifiable, getFirstEntry, getFirstEntry, getFirstKey, getFirstKey, getFirstValue, getFirstValue, getSortedByKey, getSortedByValue, getSwappedKeyValues, isNotEmpty, put, putAll, putAll, putAllMapped, putAllMapped, putAllMapped, putIf, putIfNotNull, removeAll, removeIf, removeIfKey, removeIfValue, removeObject, setAllclear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getOrDefault, hashCode, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, values@Nonnull @ReturnsMutableObject(value="design") COLLTYPE getOrCreate(@Nonnull KEYTYPE aKey)
aKey - The key to use. May not be null.null.@Nonnull default com.helger.commons.state.EChange putSingle(@Nonnull KEYTYPE aKey, @Nullable VALUETYPE aValue)
aKey - The key to use. May not be null.aValue - The value to be added. May be null.EChange@Nonnull default com.helger.commons.state.EChange putAllIn(@Nonnull Map<? extends KEYTYPE,? extends VALUETYPE> aMap)
aMap - The key-value-map to use. May not be null.EChange@Nonnull default com.helger.commons.state.EChange removeSingle(@Nonnull KEYTYPE aKey, @Nullable VALUETYPE aValue)
aKey - The key to use. May not be null.aValue - The value to be removed. May be null.EChangedefault boolean containsSingle(@Nonnull KEYTYPE aKey, @Nullable VALUETYPE aValue)
aKey - The key to use. May not be null.aValue - The value to be checked. May be null.true if the value is contained, false
otherwise@Nonnegative default long getTotalValueCount()
default void forEachSingle(@Nonnull BiConsumer<? super KEYTYPE,? super VALUETYPE> aConsumer)
Copyright © 2017–2020 Philip Helger. All rights reserved.