public interface MutableCharObjectMap<V> extends CharObjectMap<V>, MutablePrimitiveObjectMap<V>
| Modifier and Type | Method and Description |
|---|---|
MutableCharObjectMap<V> |
asSynchronized() |
MutableCharObjectMap<V> |
asUnmodifiable() |
MutableObjectCharMap<V> |
flipUniqueValues()
Return the ObjectCharMap that is obtained by flipping the direction of this map and making the associations
from value to key.
|
V |
getIfAbsentPut(char key,
Function0<? extends V> function) |
V |
getIfAbsentPut(char key,
V value) |
<P> V |
getIfAbsentPutWith(char key,
Function<? super P,? extends V> function,
P parameter) |
V |
getIfAbsentPutWithKey(char key,
CharToObjectFunction<? extends V> function) |
V |
put(char key,
V value) |
void |
putAll(CharObjectMap<? extends V> map) |
MutableCharObjectMap<V> |
reject(CharObjectPredicate<? super V> predicate) |
V |
remove(char key) |
V |
removeKey(char key) |
MutableCharObjectMap<V> |
select(CharObjectPredicate<? super V> predicate) |
MutableCharObjectMap<V> |
tap(Procedure<? super V> procedure)
Executes the Procedure for each element in the iterable and returns
this. |
V |
updateValue(char key,
Function0<? extends V> factory,
Function<? super V,? extends V> function)
Look up the value associated with
key, apply the function to it, and replace the value. |
<P> V |
updateValueWith(char key,
Function0<? extends V> factory,
Function2<? super V,? super P,? extends V> function,
P parameter)
Same as
updateValue(char, Function0, Function) with a Function2 and specified parameter which is
passed to the function. |
MutableCharObjectMap<V> |
withKeyValue(char key,
V value) |
MutableCharObjectMap<V> |
withoutAllKeys(CharIterable keys) |
MutableCharObjectMap<V> |
withoutKey(char key) |
containsKey, forEachKey, forEachKeyValue, get, getIfAbsent, keySet, keysView, keyValuesView, toImmutableaggregateBy, aggregateInPlaceBy, clear, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectIf, collectInt, collectLong, collectShort, collectWith, flatCollect, groupBy, groupByEach, groupByUniqueKey, partition, partitionWith, reject, rejectWith, select, selectInstancesOf, selectWith, sumByDouble, sumByFloat, sumByInt, sumByLong, zip, zipWithIndexcontainsValue, equals, forEachValue, hashCode, parallelStream, spliterator, stream, toString, valuesallSatisfy, allSatisfyWith, anySatisfy, anySatisfyWith, appendString, appendString, appendString, asLazy, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectIf, collectInt, collectLong, collectShort, collectWith, contains, containsAll, containsAllArguments, containsAllIterable, count, countBy, countBy, countByWith, countByWith, countWith, detect, detectIfNone, detectOptional, detectWith, detectWithIfNone, detectWithOptional, each, flatCollect, getFirst, getLast, getOnly, groupBy, groupByEach, groupByUniqueKey, injectInto, injectInto, injectInto, injectInto, injectInto, into, isEmpty, makeString, makeString, makeString, max, max, maxBy, maxByOptional, maxOptional, maxOptional, min, min, minBy, minByOptional, minOptional, minOptional, noneSatisfy, noneSatisfyWith, notEmpty, reduce, reduceInPlace, reduceInPlace, reject, rejectWith, select, selectWith, size, summarizeDouble, summarizeFloat, summarizeInt, summarizeLong, sumOfDouble, sumOfFloat, sumOfInt, sumOfLong, toArray, toArray, toBag, toList, toMap, toSet, toSortedBag, toSortedBag, toSortedBagBy, toSortedList, toSortedList, toSortedListBy, toSortedMap, toSortedMap, toSortedSet, toSortedSet, toSortedSetBy, zip, zipWithIndexforEach, forEach, forEachWith, forEachWithIndexvoid putAll(CharObjectMap<? extends V> map)
V removeKey(char key)
V remove(char key)
V getIfAbsentPutWithKey(char key, CharToObjectFunction<? extends V> function)
<P> V getIfAbsentPutWith(char key, Function<? super P,? extends V> function, P parameter)
V updateValue(char key, Function0<? extends V> factory, Function<? super V,? extends V> function)
key, apply the function to it, and replace the value. If there
is no value associated with key, start it off with a value supplied by factory.<P> V updateValueWith(char key, Function0<? extends V> factory, Function2<? super V,? super P,? extends V> function, P parameter)
updateValue(char, Function0, Function) with a Function2 and specified parameter which is
passed to the function.MutableObjectCharMap<V> flipUniqueValues()
CharObjectMapflipUniqueValues in interface CharObjectMap<V>MutableCharObjectMap<V> tap(Procedure<? super V> procedure)
RichIterablethis.
Example using a Java 8 lambda expression:
RichIterable<Person> tapped =
people.tap(person -> LOGGER.info(person.getName()));
Example using an anonymous inner class:
RichIterable<Person> tapped =
people.tap(new Procedure<Person>()
{
public void value(Person person)
{
LOGGER.info(person.getName());
}
});
tap in interface CharObjectMap<V>tap in interface RichIterable<V>RichIterable.each(Procedure),
InternalIterable.forEach(Procedure)MutableCharObjectMap<V> select(CharObjectPredicate<? super V> predicate)
select in interface CharObjectMap<V>MutableCharObjectMap<V> reject(CharObjectPredicate<? super V> predicate)
reject in interface CharObjectMap<V>MutableCharObjectMap<V> withKeyValue(char key, V value)
MutableCharObjectMap<V> withoutKey(char key)
MutableCharObjectMap<V> withoutAllKeys(CharIterable keys)
MutableCharObjectMap<V> asUnmodifiable()
MutableCharObjectMap<V> asSynchronized()
Copyright © 2004–2017. All rights reserved.