Class CharDoubleHashMap
- java.lang.Object
-
- org.eclipse.collections.impl.primitive.AbstractDoubleIterable
-
- org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableDoubleValuesMap
-
- org.eclipse.collections.impl.map.mutable.primitive.CharDoubleHashMap
-
- All Implemented Interfaces:
Externalizable,Serializable,DoubleIterable,CharDoubleMap,DoubleValuesMap,MutableCharDoubleMap,MutableDoubleValuesMap,PrimitiveIterable,MutableCharKeysMap,CharKeysMap
public class CharDoubleHashMap extends AbstractMutableDoubleValuesMap implements MutableCharDoubleMap, Externalizable, MutableCharKeysMap
This file was automatically generated from template file primitivePrimitiveHashMap.stg.- Since:
- 3.0.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description CharDoubleHashMap()CharDoubleHashMap(int initialCapacity)CharDoubleHashMap(CharDoubleMap map)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description doubleaddToValue(char key, double toBeAdded)MutableCharDoubleMapasSynchronized()MutableCharDoubleMapasUnmodifiable()voidclear()voidcompact()Deprecated.since 12.0 - UsetrimToSize()insteadbooleancontainsKey(char key)MutableDoubleIteratordoubleIterator()booleanequals(Object obj)MutableDoubleCharMapflipUniqueValues()voidforEachKey(CharProcedure procedure)voidforEachKeyValue(CharDoubleProcedure procedure)doubleget(char key)doublegetAndPut(char key, double putValue, double defaultValue)doublegetIfAbsent(char key, double ifAbsent)doublegetIfAbsentPut(char key, double value)doublegetIfAbsentPut(char key, DoubleFunction0 function)<P> doublegetIfAbsentPutWith(char key, DoubleFunction<? super P> function, P parameter)doublegetIfAbsentPutWithKey(char key, CharToDoubleFunction function)doublegetOrThrow(char key)inthashCode()<V> VinjectInto(V injectedValue, ObjectDoubleToObjectFunction<? super V,? extends V> function)MutableCharSetkeySet()LazyCharIterablekeysView()RichIterable<CharDoublePair>keyValuesView()static CharDoubleHashMapnewWithKeysValues(char key1, double value1)static CharDoubleHashMapnewWithKeysValues(char key1, double value1, char key2, double value2)static CharDoubleHashMapnewWithKeysValues(char key1, double value1, char key2, double value2, char key3, double value3)static CharDoubleHashMapnewWithKeysValues(char key1, double value1, char key2, double value2, char key3, double value3, char key4, double value4)voidput(char key, double value)voidputAll(CharDoubleMap map)voidreadExternal(ObjectInput in)CharDoubleHashMapreject(CharDoublePredicate predicate)voidremove(char key)voidremoveKey(char key)doubleremoveKeyIfAbsent(char key, double value)CharDoubleHashMapselect(CharDoublePredicate predicate)ImmutableCharDoubleMaptoImmutable()StringtoString()booleantrimToSize()doubleupdateValue(char key, double initialValueIfAbsent, DoubleToDoubleFunction function)voidupdateValues(CharDoubleToDoubleFunction function)MutableDoubleCollectionvalues()CharDoubleHashMapwithKeysValues(char key1, double value1, char key2, double value2)CharDoubleHashMapwithKeysValues(char key1, double value1, char key2, double value2, char key3, double value3)CharDoubleHashMapwithKeysValues(char key1, double value1, char key2, double value2, char key3, double value3, char key4, double value4)CharDoubleHashMapwithKeyValue(char key1, double value1)CharDoubleHashMapwithoutAllKeys(CharIterable keys)CharDoubleHashMapwithoutKey(char key)voidwriteExternal(ObjectOutput out)-
Methods inherited from class org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableDoubleValuesMap
allSatisfy, anySatisfy, appendString, chunk, collect, contains, containsAll, containsValue, count, detectIfNone, each, forEachValue, isEmpty, max, min, notEmpty, reject, select, size, sum, toArray, toArray
-
Methods inherited from class org.eclipse.collections.impl.primitive.AbstractDoubleIterable
asLazy, average, maxIfEmpty, median, minIfEmpty, toBag, toList, toSet, toSortedArray, toSortedList
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.CharDoubleMap
injectIntoKeyValue
-
Methods inherited from interface org.eclipse.collections.impl.map.primitive.CharKeysMap
isEmpty, notEmpty, size
-
Methods inherited from interface org.eclipse.collections.api.DoubleIterable
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, toSortedListBy
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.DoubleValuesMap
containsValue, forEachValue, tap
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.MutableCharDoubleMap
putPair, withAllKeyValues
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.MutableDoubleValuesMap
collect, reject, select
-
Methods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size
-
-
-
-
Constructor Detail
-
CharDoubleHashMap
public CharDoubleHashMap()
-
CharDoubleHashMap
public CharDoubleHashMap(int initialCapacity)
-
CharDoubleHashMap
public CharDoubleHashMap(CharDoubleMap map)
-
-
Method Detail
-
newWithKeysValues
public static CharDoubleHashMap newWithKeysValues(char key1, double value1)
-
newWithKeysValues
public static CharDoubleHashMap newWithKeysValues(char key1, double value1, char key2, double value2)
-
newWithKeysValues
public static CharDoubleHashMap newWithKeysValues(char key1, double value1, char key2, double value2, char key3, double value3)
-
newWithKeysValues
public static CharDoubleHashMap newWithKeysValues(char key1, double value1, char key2, double value2, char key3, double value3, char key4, double value4)
-
equals
public boolean equals(Object obj)
- Specified by:
equalsin interfaceCharDoubleMap- Overrides:
equalsin classObject
-
hashCode
public int hashCode()
- Specified by:
hashCodein interfaceCharDoubleMap- Overrides:
hashCodein classObject
-
toString
public String toString()
- Specified by:
toStringin interfaceCharDoubleMap- Specified by:
toStringin interfacePrimitiveIterable- Overrides:
toStringin classAbstractDoubleIterable
-
doubleIterator
public MutableDoubleIterator doubleIterator()
- Specified by:
doubleIteratorin interfaceDoubleIterable- Specified by:
doubleIteratorin interfaceMutableDoubleValuesMap
-
injectInto
public <V> V injectInto(V injectedValue, ObjectDoubleToObjectFunction<? super V,? extends V> function)- Specified by:
injectIntoin interfaceDoubleIterable
-
clear
public void clear()
- Specified by:
clearin interfaceMutableCharKeysMap- Specified by:
clearin interfaceMutableDoubleValuesMap
-
put
public void put(char key, double value)- Specified by:
putin interfaceMutableCharDoubleMap
-
putAll
public void putAll(CharDoubleMap map)
- Specified by:
putAllin interfaceMutableCharDoubleMap
-
updateValues
public void updateValues(CharDoubleToDoubleFunction function)
- Specified by:
updateValuesin interfaceMutableCharDoubleMap
-
removeKey
public void removeKey(char key)
- Specified by:
removeKeyin interfaceMutableCharDoubleMap- Specified by:
removeKeyin interfaceMutableCharKeysMap
-
remove
public void remove(char key)
- Specified by:
removein interfaceMutableCharDoubleMap
-
removeKeyIfAbsent
public double removeKeyIfAbsent(char key, double value)- Specified by:
removeKeyIfAbsentin interfaceMutableCharDoubleMap
-
getIfAbsentPut
public double getIfAbsentPut(char key, double value)- Specified by:
getIfAbsentPutin interfaceMutableCharDoubleMap
-
getAndPut
public double getAndPut(char key, double putValue, double defaultValue)- Specified by:
getAndPutin interfaceMutableCharDoubleMap
-
getIfAbsentPut
public double getIfAbsentPut(char key, DoubleFunction0 function)- Specified by:
getIfAbsentPutin interfaceMutableCharDoubleMap
-
getIfAbsentPutWith
public <P> double getIfAbsentPutWith(char key, DoubleFunction<? super P> function, P parameter)- Specified by:
getIfAbsentPutWithin interfaceMutableCharDoubleMap
-
getIfAbsentPutWithKey
public double getIfAbsentPutWithKey(char key, CharToDoubleFunction function)- Specified by:
getIfAbsentPutWithKeyin interfaceMutableCharDoubleMap
-
addToValue
public double addToValue(char key, double toBeAdded)- Specified by:
addToValuein interfaceMutableCharDoubleMap
-
updateValue
public double updateValue(char key, double initialValueIfAbsent, DoubleToDoubleFunction function)- Specified by:
updateValuein interfaceMutableCharDoubleMap
-
withKeyValue
public CharDoubleHashMap withKeyValue(char key1, double value1)
- Specified by:
withKeyValuein interfaceMutableCharDoubleMap
-
withKeysValues
public CharDoubleHashMap withKeysValues(char key1, double value1, char key2, double value2)
-
withKeysValues
public CharDoubleHashMap withKeysValues(char key1, double value1, char key2, double value2, char key3, double value3)
-
withKeysValues
public CharDoubleHashMap withKeysValues(char key1, double value1, char key2, double value2, char key3, double value3, char key4, double value4)
-
withoutKey
public CharDoubleHashMap withoutKey(char key)
- Specified by:
withoutKeyin interfaceMutableCharDoubleMap
-
withoutAllKeys
public CharDoubleHashMap withoutAllKeys(CharIterable keys)
- Specified by:
withoutAllKeysin interfaceMutableCharDoubleMap
-
asUnmodifiable
public MutableCharDoubleMap asUnmodifiable()
- Specified by:
asUnmodifiablein interfaceMutableCharDoubleMap
-
asSynchronized
public MutableCharDoubleMap asSynchronized()
- Specified by:
asSynchronizedin interfaceMutableCharDoubleMap
-
toImmutable
public ImmutableCharDoubleMap toImmutable()
- Specified by:
toImmutablein interfaceCharDoubleMap
-
get
public double get(char key)
- Specified by:
getin interfaceCharDoubleMap
-
getIfAbsent
public double getIfAbsent(char key, double ifAbsent)- Specified by:
getIfAbsentin interfaceCharDoubleMap
-
getOrThrow
public double getOrThrow(char key)
- Specified by:
getOrThrowin interfaceCharDoubleMap
-
containsKey
public boolean containsKey(char key)
- Specified by:
containsKeyin interfaceCharDoubleMap- Specified by:
containsKeyin interfaceCharKeysMap
-
forEachKey
public void forEachKey(CharProcedure procedure)
- Specified by:
forEachKeyin interfaceCharDoubleMap- Specified by:
forEachKeyin interfaceCharKeysMap
-
forEachKeyValue
public void forEachKeyValue(CharDoubleProcedure procedure)
- Specified by:
forEachKeyValuein interfaceCharDoubleMap
-
keysView
public LazyCharIterable keysView()
- Specified by:
keysViewin interfaceCharDoubleMap
-
keyValuesView
public RichIterable<CharDoublePair> keyValuesView()
- Specified by:
keyValuesViewin interfaceCharDoubleMap
-
flipUniqueValues
public MutableDoubleCharMap flipUniqueValues()
- Specified by:
flipUniqueValuesin interfaceCharDoubleMap- Specified by:
flipUniqueValuesin interfaceMutableCharDoubleMap
-
select
public CharDoubleHashMap select(CharDoublePredicate predicate)
- Specified by:
selectin interfaceCharDoubleMap- Specified by:
selectin interfaceMutableCharDoubleMap
-
reject
public CharDoubleHashMap reject(CharDoublePredicate predicate)
- Specified by:
rejectin interfaceCharDoubleMap- Specified by:
rejectin interfaceMutableCharDoubleMap
-
writeExternal
public void writeExternal(ObjectOutput out) throws IOException
- Specified by:
writeExternalin interfaceExternalizable- Throws:
IOException
-
readExternal
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
- Specified by:
readExternalin interfaceExternalizable- Throws:
IOExceptionClassNotFoundException
-
trimToSize
public boolean trimToSize()
- Since:
- 12.0
-
compact
@Deprecated public void 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
public MutableCharSet keySet()
- Specified by:
keySetin interfaceCharDoubleMap
-
values
public MutableDoubleCollection values()
- Specified by:
valuesin interfaceDoubleValuesMap
-
-