Class CharIntHashMap
java.lang.Object
org.eclipse.collections.impl.primitive.AbstractIntIterable
org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableIntValuesMap
org.eclipse.collections.impl.map.mutable.primitive.CharIntHashMap
- All Implemented Interfaces:
Externalizable,Serializable,IntIterable,CharIntMap,IntValuesMap,MutableCharIntMap,MutableIntValuesMap,PrimitiveIterable,MutableCharKeysMap,CharKeysMap
public class CharIntHashMap
extends AbstractMutableIntValuesMap
implements MutableCharIntMap, Externalizable, MutableCharKeysMap
This file was automatically generated from template file primitivePrimitiveHashMap.stg.
- Since:
- 3.0.
- See Also:
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintaddToValue(char key, int toBeAdded) booleanallSatisfyKeyValue(CharIntPredicate predicate) voidclear()voidcompact()Deprecated.booleancontainsKey(char key) booleanvoidforEachKey(CharProcedure procedure) voidforEachKeyValue(CharIntProcedure procedure) intget(char key) intgetAndPut(char key, int putValue, int defaultValue) intgetIfAbsent(char key, int ifAbsent) intgetIfAbsentPut(char key, int value) intgetIfAbsentPut(char key, IntFunction0 function) <P> intgetIfAbsentPutWith(char key, IntFunction<? super P> function, P parameter) intgetIfAbsentPutWithKey(char key, CharToIntFunction function) intgetOrThrow(char key) inthashCode()<V> VinjectInto(V injectedValue, ObjectIntToObjectFunction<? super V, ? extends V> function) keySet()keysView()static CharIntHashMapnewWithKeysValues(char key1, int value1) static CharIntHashMapnewWithKeysValues(char key1, int value1, char key2, int value2) static CharIntHashMapnewWithKeysValues(char key1, int value1, char key2, int value2, char key3, int value3) static CharIntHashMapnewWithKeysValues(char key1, int value1, char key2, int value2, char key3, int value3, char key4, int value4) voidput(char key, int value) voidputAll(CharIntMap map) voidreject(CharIntPredicate predicate) voidremove(char key) voidremoveKey(char key) intremoveKeyIfAbsent(char key, int value) select(CharIntPredicate predicate) toString()booleanintupdateValue(char key, int initialValueIfAbsent, IntToIntFunction function) voidupdateValues(CharIntToIntFunction function) values()withKeysValues(char key1, int value1, char key2, int value2) withKeysValues(char key1, int value1, char key2, int value2, char key3, int value3) withKeysValues(char key1, int value1, char key2, int value2, char key3, int value3, char key4, int value4) withKeyValue(char key1, int value1) withoutAllKeys(CharIterable keys) withoutKey(char key) voidMethods inherited from class org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableIntValuesMap
allSatisfy, anySatisfy, appendString, chunk, collect, contains, containsAll, containsValue, count, detectIfNone, each, forEachValue, isEmpty, max, min, notEmpty, reject, select, size, sum, toArray, toArrayMethods inherited from class org.eclipse.collections.impl.primitive.AbstractIntIterable
asLazy, average, maxIfEmpty, median, minIfEmpty, toBag, toList, toSet, toSortedArray, toSortedListMethods inherited from interface org.eclipse.collections.api.map.primitive.CharIntMap
injectIntoKeyValueMethods inherited from interface org.eclipse.collections.impl.map.primitive.CharKeysMap
isEmpty, notEmpty, sizeMethods inherited from interface org.eclipse.collections.api.IntIterable
allSatisfy, anySatisfy, asLazy, average, averageIfEmpty, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, containsAny, containsAny, containsNone, containsNone, count, detectIfNone, each, flatCollect, forEach, injectIntoBoolean, injectIntoByte, injectIntoChar, injectIntoDouble, injectIntoFloat, injectIntoInt, injectIntoLong, injectIntoShort, max, maxIfEmpty, median, medianIfEmpty, min, minIfEmpty, noneSatisfy, reduce, reduceIfEmpty, reject, select, sum, summaryStatistics, toArray, toArray, toBag, toList, toSet, toSortedArray, toSortedList, toSortedList, toSortedListBy, toSortedListByMethods inherited from interface org.eclipse.collections.api.map.primitive.IntValuesMap
containsValue, forEachValue, tapMethods inherited from interface org.eclipse.collections.api.map.primitive.MutableCharIntMap
putPair, withAllKeyValuesMethods inherited from interface org.eclipse.collections.api.map.primitive.MutableIntValuesMap
collect, reject, selectMethods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size
-
Constructor Details
-
CharIntHashMap
public CharIntHashMap() -
CharIntHashMap
public CharIntHashMap(int initialCapacity) -
CharIntHashMap
-
-
Method Details
-
newWithKeysValues
-
newWithKeysValues
-
newWithKeysValues
public static CharIntHashMap newWithKeysValues(char key1, int value1, char key2, int value2, char key3, int value3) -
newWithKeysValues
public static CharIntHashMap newWithKeysValues(char key1, int value1, char key2, int value2, char key3, int value3, char key4, int value4) -
equals
- Specified by:
equalsin interfaceCharIntMap- Overrides:
equalsin classObject
-
hashCode
public int hashCode()- Specified by:
hashCodein interfaceCharIntMap- Overrides:
hashCodein classObject
-
toString
- Specified by:
toStringin interfaceCharIntMap- Specified by:
toStringin interfacePrimitiveIterable- Overrides:
toStringin classAbstractIntIterable
-
intIterator
- Specified by:
intIteratorin interfaceIntIterable- Specified by:
intIteratorin interfaceMutableIntValuesMap
-
injectInto
- Specified by:
injectIntoin interfaceIntIterable
-
clear
public void clear()- Specified by:
clearin interfaceMutableCharKeysMap- Specified by:
clearin interfaceMutableIntValuesMap
-
put
public void put(char key, int value) - Specified by:
putin interfaceMutableCharIntMap
-
putAll
- Specified by:
putAllin interfaceMutableCharIntMap
-
updateValues
- Specified by:
updateValuesin interfaceMutableCharIntMap
-
removeKey
public void removeKey(char key) - Specified by:
removeKeyin interfaceMutableCharIntMap- Specified by:
removeKeyin interfaceMutableCharKeysMap
-
remove
public void remove(char key) - Specified by:
removein interfaceMutableCharIntMap
-
removeKeyIfAbsent
public int removeKeyIfAbsent(char key, int value) - Specified by:
removeKeyIfAbsentin interfaceMutableCharIntMap
-
getIfAbsentPut
public int getIfAbsentPut(char key, int value) - Specified by:
getIfAbsentPutin interfaceMutableCharIntMap
-
getAndPut
public int getAndPut(char key, int putValue, int defaultValue) - Specified by:
getAndPutin interfaceMutableCharIntMap
-
getIfAbsentPut
- Specified by:
getIfAbsentPutin interfaceMutableCharIntMap
-
getIfAbsentPutWith
- Specified by:
getIfAbsentPutWithin interfaceMutableCharIntMap
-
getIfAbsentPutWithKey
- Specified by:
getIfAbsentPutWithKeyin interfaceMutableCharIntMap
-
addToValue
public int addToValue(char key, int toBeAdded) - Specified by:
addToValuein interfaceMutableCharIntMap
-
updateValue
- Specified by:
updateValuein interfaceMutableCharIntMap
-
withKeyValue
- Specified by:
withKeyValuein interfaceMutableCharIntMap
-
withKeysValues
-
withKeysValues
public CharIntHashMap withKeysValues(char key1, int value1, char key2, int value2, char key3, int value3) -
withKeysValues
public CharIntHashMap withKeysValues(char key1, int value1, char key2, int value2, char key3, int value3, char key4, int value4) -
withoutKey
- Specified by:
withoutKeyin interfaceMutableCharIntMap
-
withoutAllKeys
- Specified by:
withoutAllKeysin interfaceMutableCharIntMap
-
asUnmodifiable
- Specified by:
asUnmodifiablein interfaceMutableCharIntMap
-
asSynchronized
- Specified by:
asSynchronizedin interfaceMutableCharIntMap
-
toImmutable
- Specified by:
toImmutablein interfaceCharIntMap
-
get
public int get(char key) - Specified by:
getin interfaceCharIntMap
-
getIfAbsent
public int getIfAbsent(char key, int ifAbsent) - Specified by:
getIfAbsentin interfaceCharIntMap
-
getOrThrow
public int getOrThrow(char key) - Specified by:
getOrThrowin interfaceCharIntMap
-
containsKey
public boolean containsKey(char key) - Specified by:
containsKeyin interfaceCharIntMap- Specified by:
containsKeyin interfaceCharKeysMap
-
forEachKey
- Specified by:
forEachKeyin interfaceCharIntMap- Specified by:
forEachKeyin interfaceCharKeysMap
-
forEachKeyValue
- Specified by:
forEachKeyValuein interfaceCharIntMap
-
allSatisfyKeyValue
- Specified by:
allSatisfyKeyValuein interfaceCharIntMap- Since:
- 12.0
-
keysView
- Specified by:
keysViewin interfaceCharIntMap
-
keyValuesView
- Specified by:
keyValuesViewin interfaceCharIntMap
-
flipUniqueValues
- Specified by:
flipUniqueValuesin interfaceCharIntMap- Specified by:
flipUniqueValuesin interfaceMutableCharIntMap
-
select
- Specified by:
selectin interfaceCharIntMap- Specified by:
selectin interfaceMutableCharIntMap
-
reject
- Specified by:
rejectin interfaceCharIntMap- Specified by:
rejectin interfaceMutableCharIntMap
-
writeExternal
- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-
readExternal
- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
trimToSize
public boolean trimToSize()- Since:
- 12.0
-
compact
Deprecated.since 12.0 - UsetrimToSize()insteadRehashes every element in the set into a new backing table of the smallest possible size and eliminating removed sentinels. -
keySet
- Specified by:
keySetin interfaceCharIntMap
-
values
- Specified by:
valuesin interfaceIntValuesMap
-
trimToSize()instead