Class DoubleFloatHashMap
- java.lang.Object
-
- org.eclipse.collections.impl.primitive.AbstractFloatIterable
-
- org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableFloatValuesMap
-
- org.eclipse.collections.impl.map.mutable.primitive.DoubleFloatHashMap
-
- All Implemented Interfaces:
Externalizable
,Serializable
,FloatIterable
,DoubleFloatMap
,FloatValuesMap
,MutableDoubleFloatMap
,MutableFloatValuesMap
,PrimitiveIterable
,MutableDoubleKeysMap
,DoubleKeysMap
public class DoubleFloatHashMap extends AbstractMutableFloatValuesMap implements MutableDoubleFloatMap, Externalizable, MutableDoubleKeysMap
This file was automatically generated from template file primitivePrimitiveHashMap.stg.- Since:
- 3.0.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description DoubleFloatHashMap()
DoubleFloatHashMap(int initialCapacity)
DoubleFloatHashMap(DoubleFloatMap map)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description float
addToValue(double key, float toBeAdded)
MutableDoubleFloatMap
asSynchronized()
MutableDoubleFloatMap
asUnmodifiable()
void
clear()
void
compact()
Deprecated.since 12.0 - UsetrimToSize()
insteadboolean
containsKey(double key)
boolean
equals(Object obj)
MutableFloatDoubleMap
flipUniqueValues()
MutableFloatIterator
floatIterator()
void
forEachKey(DoubleProcedure procedure)
void
forEachKeyValue(DoubleFloatProcedure procedure)
float
get(double key)
float
getAndPut(double key, float putValue, float defaultValue)
float
getIfAbsent(double key, float ifAbsent)
float
getIfAbsentPut(double key, float value)
float
getIfAbsentPut(double key, FloatFunction0 function)
<P> float
getIfAbsentPutWith(double key, FloatFunction<? super P> function, P parameter)
float
getIfAbsentPutWithKey(double key, DoubleToFloatFunction function)
float
getOrThrow(double key)
int
hashCode()
<V> V
injectInto(V injectedValue, ObjectFloatToObjectFunction<? super V,? extends V> function)
MutableDoubleSet
keySet()
LazyDoubleIterable
keysView()
RichIterable<DoubleFloatPair>
keyValuesView()
static DoubleFloatHashMap
newWithKeysValues(double key1, float value1)
static DoubleFloatHashMap
newWithKeysValues(double key1, float value1, double key2, float value2)
static DoubleFloatHashMap
newWithKeysValues(double key1, float value1, double key2, float value2, double key3, float value3)
static DoubleFloatHashMap
newWithKeysValues(double key1, float value1, double key2, float value2, double key3, float value3, double key4, float value4)
void
put(double key, float value)
void
putAll(DoubleFloatMap map)
void
readExternal(ObjectInput in)
DoubleFloatHashMap
reject(DoubleFloatPredicate predicate)
void
remove(double key)
void
removeKey(double key)
float
removeKeyIfAbsent(double key, float value)
DoubleFloatHashMap
select(DoubleFloatPredicate predicate)
ImmutableDoubleFloatMap
toImmutable()
String
toString()
boolean
trimToSize()
float
updateValue(double key, float initialValueIfAbsent, FloatToFloatFunction function)
void
updateValues(DoubleFloatToFloatFunction function)
MutableFloatCollection
values()
DoubleFloatHashMap
withKeysValues(double key1, float value1, double key2, float value2)
DoubleFloatHashMap
withKeysValues(double key1, float value1, double key2, float value2, double key3, float value3)
DoubleFloatHashMap
withKeysValues(double key1, float value1, double key2, float value2, double key3, float value3, double key4, float value4)
DoubleFloatHashMap
withKeyValue(double key1, float value1)
DoubleFloatHashMap
withoutAllKeys(DoubleIterable keys)
DoubleFloatHashMap
withoutKey(double key)
void
writeExternal(ObjectOutput out)
-
Methods inherited from class org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableFloatValuesMap
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.AbstractFloatIterable
asLazy, average, maxIfEmpty, median, minIfEmpty, toBag, toList, toSet, toSortedArray, toSortedList
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.DoubleFloatMap
injectIntoKeyValue
-
Methods inherited from interface org.eclipse.collections.impl.map.primitive.DoubleKeysMap
isEmpty, notEmpty, size
-
Methods inherited from interface org.eclipse.collections.api.FloatIterable
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.FloatValuesMap
containsValue, forEachValue, tap
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.MutableDoubleFloatMap
putPair, withAllKeyValues
-
Methods inherited from interface org.eclipse.collections.api.map.primitive.MutableFloatValuesMap
collect, reject, select
-
Methods inherited from interface org.eclipse.collections.api.PrimitiveIterable
appendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, size
-
-
-
-
Constructor Detail
-
DoubleFloatHashMap
public DoubleFloatHashMap()
-
DoubleFloatHashMap
public DoubleFloatHashMap(int initialCapacity)
-
DoubleFloatHashMap
public DoubleFloatHashMap(DoubleFloatMap map)
-
-
Method Detail
-
newWithKeysValues
public static DoubleFloatHashMap newWithKeysValues(double key1, float value1)
-
newWithKeysValues
public static DoubleFloatHashMap newWithKeysValues(double key1, float value1, double key2, float value2)
-
newWithKeysValues
public static DoubleFloatHashMap newWithKeysValues(double key1, float value1, double key2, float value2, double key3, float value3)
-
newWithKeysValues
public static DoubleFloatHashMap newWithKeysValues(double key1, float value1, double key2, float value2, double key3, float value3, double key4, float value4)
-
equals
public boolean equals(Object obj)
- Specified by:
equals
in interfaceDoubleFloatMap
- Overrides:
equals
in classObject
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfaceDoubleFloatMap
- Overrides:
hashCode
in classObject
-
toString
public String toString()
- Specified by:
toString
in interfaceDoubleFloatMap
- Specified by:
toString
in interfacePrimitiveIterable
- Overrides:
toString
in classAbstractFloatIterable
-
floatIterator
public MutableFloatIterator floatIterator()
- Specified by:
floatIterator
in interfaceFloatIterable
- Specified by:
floatIterator
in interfaceMutableFloatValuesMap
-
injectInto
public <V> V injectInto(V injectedValue, ObjectFloatToObjectFunction<? super V,? extends V> function)
- Specified by:
injectInto
in interfaceFloatIterable
-
clear
public void clear()
- Specified by:
clear
in interfaceMutableDoubleKeysMap
- Specified by:
clear
in interfaceMutableFloatValuesMap
-
put
public void put(double key, float value)
- Specified by:
put
in interfaceMutableDoubleFloatMap
-
putAll
public void putAll(DoubleFloatMap map)
- Specified by:
putAll
in interfaceMutableDoubleFloatMap
-
updateValues
public void updateValues(DoubleFloatToFloatFunction function)
- Specified by:
updateValues
in interfaceMutableDoubleFloatMap
-
removeKey
public void removeKey(double key)
- Specified by:
removeKey
in interfaceMutableDoubleFloatMap
- Specified by:
removeKey
in interfaceMutableDoubleKeysMap
-
remove
public void remove(double key)
- Specified by:
remove
in interfaceMutableDoubleFloatMap
-
removeKeyIfAbsent
public float removeKeyIfAbsent(double key, float value)
- Specified by:
removeKeyIfAbsent
in interfaceMutableDoubleFloatMap
-
getIfAbsentPut
public float getIfAbsentPut(double key, float value)
- Specified by:
getIfAbsentPut
in interfaceMutableDoubleFloatMap
-
getAndPut
public float getAndPut(double key, float putValue, float defaultValue)
- Specified by:
getAndPut
in interfaceMutableDoubleFloatMap
-
getIfAbsentPut
public float getIfAbsentPut(double key, FloatFunction0 function)
- Specified by:
getIfAbsentPut
in interfaceMutableDoubleFloatMap
-
getIfAbsentPutWith
public <P> float getIfAbsentPutWith(double key, FloatFunction<? super P> function, P parameter)
- Specified by:
getIfAbsentPutWith
in interfaceMutableDoubleFloatMap
-
getIfAbsentPutWithKey
public float getIfAbsentPutWithKey(double key, DoubleToFloatFunction function)
- Specified by:
getIfAbsentPutWithKey
in interfaceMutableDoubleFloatMap
-
addToValue
public float addToValue(double key, float toBeAdded)
- Specified by:
addToValue
in interfaceMutableDoubleFloatMap
-
updateValue
public float updateValue(double key, float initialValueIfAbsent, FloatToFloatFunction function)
- Specified by:
updateValue
in interfaceMutableDoubleFloatMap
-
withKeyValue
public DoubleFloatHashMap withKeyValue(double key1, float value1)
- Specified by:
withKeyValue
in interfaceMutableDoubleFloatMap
-
withKeysValues
public DoubleFloatHashMap withKeysValues(double key1, float value1, double key2, float value2)
-
withKeysValues
public DoubleFloatHashMap withKeysValues(double key1, float value1, double key2, float value2, double key3, float value3)
-
withKeysValues
public DoubleFloatHashMap withKeysValues(double key1, float value1, double key2, float value2, double key3, float value3, double key4, float value4)
-
withoutKey
public DoubleFloatHashMap withoutKey(double key)
- Specified by:
withoutKey
in interfaceMutableDoubleFloatMap
-
withoutAllKeys
public DoubleFloatHashMap withoutAllKeys(DoubleIterable keys)
- Specified by:
withoutAllKeys
in interfaceMutableDoubleFloatMap
-
asUnmodifiable
public MutableDoubleFloatMap asUnmodifiable()
- Specified by:
asUnmodifiable
in interfaceMutableDoubleFloatMap
-
asSynchronized
public MutableDoubleFloatMap asSynchronized()
- Specified by:
asSynchronized
in interfaceMutableDoubleFloatMap
-
toImmutable
public ImmutableDoubleFloatMap toImmutable()
- Specified by:
toImmutable
in interfaceDoubleFloatMap
-
get
public float get(double key)
- Specified by:
get
in interfaceDoubleFloatMap
-
getIfAbsent
public float getIfAbsent(double key, float ifAbsent)
- Specified by:
getIfAbsent
in interfaceDoubleFloatMap
-
getOrThrow
public float getOrThrow(double key)
- Specified by:
getOrThrow
in interfaceDoubleFloatMap
-
containsKey
public boolean containsKey(double key)
- Specified by:
containsKey
in interfaceDoubleFloatMap
- Specified by:
containsKey
in interfaceDoubleKeysMap
-
forEachKey
public void forEachKey(DoubleProcedure procedure)
- Specified by:
forEachKey
in interfaceDoubleFloatMap
- Specified by:
forEachKey
in interfaceDoubleKeysMap
-
forEachKeyValue
public void forEachKeyValue(DoubleFloatProcedure procedure)
- Specified by:
forEachKeyValue
in interfaceDoubleFloatMap
-
keysView
public LazyDoubleIterable keysView()
- Specified by:
keysView
in interfaceDoubleFloatMap
-
keyValuesView
public RichIterable<DoubleFloatPair> keyValuesView()
- Specified by:
keyValuesView
in interfaceDoubleFloatMap
-
flipUniqueValues
public MutableFloatDoubleMap flipUniqueValues()
- Specified by:
flipUniqueValues
in interfaceDoubleFloatMap
- Specified by:
flipUniqueValues
in interfaceMutableDoubleFloatMap
-
select
public DoubleFloatHashMap select(DoubleFloatPredicate predicate)
- Specified by:
select
in interfaceDoubleFloatMap
- Specified by:
select
in interfaceMutableDoubleFloatMap
-
reject
public DoubleFloatHashMap reject(DoubleFloatPredicate predicate)
- Specified by:
reject
in interfaceDoubleFloatMap
- Specified by:
reject
in interfaceMutableDoubleFloatMap
-
writeExternal
public void writeExternal(ObjectOutput out) throws IOException
- Specified by:
writeExternal
in interfaceExternalizable
- Throws:
IOException
-
readExternal
public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
- Specified by:
readExternal
in interfaceExternalizable
- Throws:
IOException
ClassNotFoundException
-
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 MutableDoubleSet keySet()
- Specified by:
keySet
in interfaceDoubleFloatMap
-
values
public MutableFloatCollection values()
- Specified by:
values
in interfaceFloatValuesMap
-
-