IntIterable
, ObjectIntMap<K>
, PrimitiveIterable
ObjectIntHashMap
, ObjectIntHashMapWithHashingStrategy
, SynchronizedObjectIntMap
, UnmodifiableObjectIntMap
public interface MutableObjectIntMap<K> extends ObjectIntMap<K>
Modifier and Type | Method | Description |
---|---|---|
int |
addToValue(K key,
int toBeAdded) |
|
MutableObjectIntMap<K> |
asSynchronized() |
|
MutableObjectIntMap<K> |
asUnmodifiable() |
|
void |
clear() |
|
<V> MutableCollection<V> |
collect(IntToObjectFunction<? extends V> function) |
Returns a new collection with the results of applying the specified function on each element of the source
collection.
|
MutableIntObjectMap<K> |
flipUniqueValues() |
Return the IntObjectMap that is obtained by flipping the direction of this map and making the associations
from value to key.
|
int |
getIfAbsentPut(K key,
int value) |
|
int |
getIfAbsentPut(K key,
IntFunction0 function) |
|
<P> int |
getIfAbsentPutWith(K key,
IntFunction<? super P> function,
P parameter) |
|
int |
getIfAbsentPutWithKey(K key,
IntFunction<? super K> function) |
|
MutableIntIterator |
intIterator() |
Returns a primitive iterator that can be used to iterate over the IntIterable in an
imperative style.
|
void |
put(K key,
int value) |
|
void |
putAll(ObjectIntMap<? extends K> map) |
|
default void |
putPair(ObjectIntPair<K> keyValuePair) |
This method allows MutableObjectIntMap the ability to add an element in the form of
ObjectIntPair<K> . |
MutableIntCollection |
reject(IntPredicate predicate) |
Returns a new IntIterable with all of the elements in the IntIterable that
return false for the specified predicate.
|
MutableObjectIntMap<K> |
reject(ObjectIntPredicate<? super K> predicate) |
|
void |
remove(Object key) |
|
void |
removeKey(K key) |
|
int |
removeKeyIfAbsent(K key,
int value) |
|
MutableIntCollection |
select(IntPredicate predicate) |
Returns a new IntIterable with all of the elements in the IntIterable that
return true for the specified predicate.
|
MutableObjectIntMap<K> |
select(ObjectIntPredicate<? super K> predicate) |
|
default MutableObjectIntMap<K> |
tap(IntProcedure procedure) |
|
int |
updateValue(K key,
int initialValueIfAbsent,
IntToIntFunction function) |
|
void |
updateValues(ObjectIntToIntFunction<? super K> function) |
Updates the values in-place.
|
default MutableObjectIntMap<K> |
withAllKeyValues(Iterable<ObjectIntPair<K>> keyValuePairs) |
|
MutableObjectIntMap<K> |
withKeyValue(K key,
int value) |
|
MutableObjectIntMap<K> |
withoutAllKeys(Iterable<? extends K> keys) |
|
MutableObjectIntMap<K> |
withoutKey(K key) |
allSatisfy, anySatisfy, asLazy, average, averageIfEmpty, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, count, detectIfNone, each, flatCollect, forEach, injectInto, max, maxIfEmpty, median, medianIfEmpty, min, minIfEmpty, noneSatisfy, reduce, reduceIfEmpty, reject, select, sum, summaryStatistics, toArray, toBag, toList, toSet, toSortedArray, toSortedList
containsKey, containsValue, forEachKey, forEachKeyValue, forEachValue, get, getIfAbsent, getOrThrow, keySet, keysView, keyValuesView, toImmutable, toString, values
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size
MutableIntIterator intIterator()
IntIterable
intIterator
in interface IntIterable
void clear()
void put(K key, int value)
default void putPair(ObjectIntPair<K> keyValuePair)
ObjectIntPair<K>
.put(Object, int)
void putAll(ObjectIntMap<? extends K> map)
void updateValues(ObjectIntToIntFunction<? super K> function)
function
- that takes a key and its value and that returns a new value for this keyvoid removeKey(K key)
void remove(Object key)
int removeKeyIfAbsent(K key, int value)
int getIfAbsentPut(K key, int value)
int getIfAbsentPut(K key, IntFunction0 function)
int getIfAbsentPutWithKey(K key, IntFunction<? super K> function)
<P> int getIfAbsentPutWith(K key, IntFunction<? super P> function, P parameter)
int updateValue(K key, int initialValueIfAbsent, IntToIntFunction function)
MutableIntObjectMap<K> flipUniqueValues()
ObjectIntMap
flipUniqueValues
in interface ObjectIntMap<K>
MutableObjectIntMap<K> select(ObjectIntPredicate<? super K> predicate)
select
in interface ObjectIntMap<K>
MutableObjectIntMap<K> reject(ObjectIntPredicate<? super K> predicate)
reject
in interface ObjectIntMap<K>
MutableIntCollection select(IntPredicate predicate)
IntIterable
select
in interface IntIterable
MutableIntCollection reject(IntPredicate predicate)
IntIterable
reject
in interface IntIterable
default MutableObjectIntMap<K> tap(IntProcedure procedure)
tap
in interface IntIterable
tap
in interface ObjectIntMap<K>
<V> MutableCollection<V> collect(IntToObjectFunction<? extends V> function)
IntIterable
collect
in interface IntIterable
MutableObjectIntMap<K> withKeyValue(K key, int value)
MutableObjectIntMap<K> withoutKey(K key)
MutableObjectIntMap<K> withoutAllKeys(Iterable<? extends K> keys)
default MutableObjectIntMap<K> withAllKeyValues(Iterable<ObjectIntPair<K>> keyValuePairs)
MutableObjectIntMap<K> asUnmodifiable()
MutableObjectIntMap<K> asSynchronized()
int addToValue(K key, int toBeAdded)
Copyright © 2004–2019. All rights reserved.