Class ByteFloatHashMap
- java.lang.Object
-
- org.eclipse.collections.impl.primitive.AbstractFloatIterable
-
- org.eclipse.collections.impl.map.mutable.primitive.AbstractMutableFloatValuesMap
-
- org.eclipse.collections.impl.map.mutable.primitive.ByteFloatHashMap
-
- All Implemented Interfaces:
Externalizable
,Serializable
,FloatIterable
,ByteFloatMap
,FloatValuesMap
,MutableByteFloatMap
,MutableFloatValuesMap
,PrimitiveIterable
,MutableByteKeysMap
,ByteKeysMap
public class ByteFloatHashMap extends AbstractMutableFloatValuesMap implements MutableByteFloatMap, Externalizable, MutableByteKeysMap
This file was automatically generated from template file primitivePrimitiveHashMap.stg.- Since:
- 3.0.
- See Also:
- Serialized Form
-
-
Constructor Summary
Constructors Constructor Description ByteFloatHashMap()
ByteFloatHashMap(int initialCapacity)
ByteFloatHashMap(ByteFloatMap map)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description float
addToValue(byte key, float toBeAdded)
MutableByteFloatMap
asSynchronized()
MutableByteFloatMap
asUnmodifiable()
void
clear()
void
compact()
Deprecated.since 12.0 - UsetrimToSize()
insteadboolean
containsKey(byte key)
boolean
equals(Object obj)
MutableFloatByteMap
flipUniqueValues()
MutableFloatIterator
floatIterator()
void
forEachKey(ByteProcedure procedure)
void
forEachKeyValue(ByteFloatProcedure procedure)
float
get(byte key)
float
getAndPut(byte key, float putValue, float defaultValue)
float
getIfAbsent(byte key, float ifAbsent)
float
getIfAbsentPut(byte key, float value)
float
getIfAbsentPut(byte key, FloatFunction0 function)
<P> float
getIfAbsentPutWith(byte key, FloatFunction<? super P> function, P parameter)
float
getIfAbsentPutWithKey(byte key, ByteToFloatFunction function)
float
getOrThrow(byte key)
int
hashCode()
<V> V
injectInto(V injectedValue, ObjectFloatToObjectFunction<? super V,? extends V> function)
MutableByteSet
keySet()
LazyByteIterable
keysView()
RichIterable<ByteFloatPair>
keyValuesView()
static ByteFloatHashMap
newWithKeysValues(byte key1, float value1)
static ByteFloatHashMap
newWithKeysValues(byte key1, float value1, byte key2, float value2)
static ByteFloatHashMap
newWithKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3)
static ByteFloatHashMap
newWithKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3, byte key4, float value4)
void
put(byte key, float value)
void
putAll(ByteFloatMap map)
void
readExternal(ObjectInput in)
ByteFloatHashMap
reject(ByteFloatPredicate predicate)
void
remove(byte key)
void
removeKey(byte key)
float
removeKeyIfAbsent(byte key, float value)
ByteFloatHashMap
select(ByteFloatPredicate predicate)
ImmutableByteFloatMap
toImmutable()
String
toString()
boolean
trimToSize()
float
updateValue(byte key, float initialValueIfAbsent, FloatToFloatFunction function)
void
updateValues(ByteFloatToFloatFunction function)
MutableFloatCollection
values()
ByteFloatHashMap
withKeysValues(byte key1, float value1, byte key2, float value2)
ByteFloatHashMap
withKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3)
ByteFloatHashMap
withKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3, byte key4, float value4)
ByteFloatHashMap
withKeyValue(byte key1, float value1)
ByteFloatHashMap
withoutAllKeys(ByteIterable keys)
ByteFloatHashMap
withoutKey(byte 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.ByteFloatMap
injectIntoKeyValue
-
Methods inherited from interface org.eclipse.collections.impl.map.primitive.ByteKeysMap
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.MutableByteFloatMap
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
-
ByteFloatHashMap
public ByteFloatHashMap()
-
ByteFloatHashMap
public ByteFloatHashMap(int initialCapacity)
-
ByteFloatHashMap
public ByteFloatHashMap(ByteFloatMap map)
-
-
Method Detail
-
newWithKeysValues
public static ByteFloatHashMap newWithKeysValues(byte key1, float value1)
-
newWithKeysValues
public static ByteFloatHashMap newWithKeysValues(byte key1, float value1, byte key2, float value2)
-
newWithKeysValues
public static ByteFloatHashMap newWithKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3)
-
newWithKeysValues
public static ByteFloatHashMap newWithKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3, byte key4, float value4)
-
equals
public boolean equals(Object obj)
- Specified by:
equals
in interfaceByteFloatMap
- Overrides:
equals
in classObject
-
hashCode
public int hashCode()
- Specified by:
hashCode
in interfaceByteFloatMap
- Overrides:
hashCode
in classObject
-
toString
public String toString()
- Specified by:
toString
in interfaceByteFloatMap
- 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 interfaceMutableByteKeysMap
- Specified by:
clear
in interfaceMutableFloatValuesMap
-
put
public void put(byte key, float value)
- Specified by:
put
in interfaceMutableByteFloatMap
-
putAll
public void putAll(ByteFloatMap map)
- Specified by:
putAll
in interfaceMutableByteFloatMap
-
updateValues
public void updateValues(ByteFloatToFloatFunction function)
- Specified by:
updateValues
in interfaceMutableByteFloatMap
-
removeKey
public void removeKey(byte key)
- Specified by:
removeKey
in interfaceMutableByteFloatMap
- Specified by:
removeKey
in interfaceMutableByteKeysMap
-
remove
public void remove(byte key)
- Specified by:
remove
in interfaceMutableByteFloatMap
-
removeKeyIfAbsent
public float removeKeyIfAbsent(byte key, float value)
- Specified by:
removeKeyIfAbsent
in interfaceMutableByteFloatMap
-
getIfAbsentPut
public float getIfAbsentPut(byte key, float value)
- Specified by:
getIfAbsentPut
in interfaceMutableByteFloatMap
-
getAndPut
public float getAndPut(byte key, float putValue, float defaultValue)
- Specified by:
getAndPut
in interfaceMutableByteFloatMap
-
getIfAbsentPut
public float getIfAbsentPut(byte key, FloatFunction0 function)
- Specified by:
getIfAbsentPut
in interfaceMutableByteFloatMap
-
getIfAbsentPutWith
public <P> float getIfAbsentPutWith(byte key, FloatFunction<? super P> function, P parameter)
- Specified by:
getIfAbsentPutWith
in interfaceMutableByteFloatMap
-
getIfAbsentPutWithKey
public float getIfAbsentPutWithKey(byte key, ByteToFloatFunction function)
- Specified by:
getIfAbsentPutWithKey
in interfaceMutableByteFloatMap
-
addToValue
public float addToValue(byte key, float toBeAdded)
- Specified by:
addToValue
in interfaceMutableByteFloatMap
-
updateValue
public float updateValue(byte key, float initialValueIfAbsent, FloatToFloatFunction function)
- Specified by:
updateValue
in interfaceMutableByteFloatMap
-
withKeyValue
public ByteFloatHashMap withKeyValue(byte key1, float value1)
- Specified by:
withKeyValue
in interfaceMutableByteFloatMap
-
withKeysValues
public ByteFloatHashMap withKeysValues(byte key1, float value1, byte key2, float value2)
-
withKeysValues
public ByteFloatHashMap withKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3)
-
withKeysValues
public ByteFloatHashMap withKeysValues(byte key1, float value1, byte key2, float value2, byte key3, float value3, byte key4, float value4)
-
withoutKey
public ByteFloatHashMap withoutKey(byte key)
- Specified by:
withoutKey
in interfaceMutableByteFloatMap
-
withoutAllKeys
public ByteFloatHashMap withoutAllKeys(ByteIterable keys)
- Specified by:
withoutAllKeys
in interfaceMutableByteFloatMap
-
asUnmodifiable
public MutableByteFloatMap asUnmodifiable()
- Specified by:
asUnmodifiable
in interfaceMutableByteFloatMap
-
asSynchronized
public MutableByteFloatMap asSynchronized()
- Specified by:
asSynchronized
in interfaceMutableByteFloatMap
-
toImmutable
public ImmutableByteFloatMap toImmutable()
- Specified by:
toImmutable
in interfaceByteFloatMap
-
get
public float get(byte key)
- Specified by:
get
in interfaceByteFloatMap
-
getIfAbsent
public float getIfAbsent(byte key, float ifAbsent)
- Specified by:
getIfAbsent
in interfaceByteFloatMap
-
getOrThrow
public float getOrThrow(byte key)
- Specified by:
getOrThrow
in interfaceByteFloatMap
-
containsKey
public boolean containsKey(byte key)
- Specified by:
containsKey
in interfaceByteFloatMap
- Specified by:
containsKey
in interfaceByteKeysMap
-
forEachKey
public void forEachKey(ByteProcedure procedure)
- Specified by:
forEachKey
in interfaceByteFloatMap
- Specified by:
forEachKey
in interfaceByteKeysMap
-
forEachKeyValue
public void forEachKeyValue(ByteFloatProcedure procedure)
- Specified by:
forEachKeyValue
in interfaceByteFloatMap
-
keysView
public LazyByteIterable keysView()
- Specified by:
keysView
in interfaceByteFloatMap
-
keyValuesView
public RichIterable<ByteFloatPair> keyValuesView()
- Specified by:
keyValuesView
in interfaceByteFloatMap
-
flipUniqueValues
public MutableFloatByteMap flipUniqueValues()
- Specified by:
flipUniqueValues
in interfaceByteFloatMap
- Specified by:
flipUniqueValues
in interfaceMutableByteFloatMap
-
select
public ByteFloatHashMap select(ByteFloatPredicate predicate)
- Specified by:
select
in interfaceByteFloatMap
- Specified by:
select
in interfaceMutableByteFloatMap
-
reject
public ByteFloatHashMap reject(ByteFloatPredicate predicate)
- Specified by:
reject
in interfaceByteFloatMap
- Specified by:
reject
in interfaceMutableByteFloatMap
-
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 MutableByteSet keySet()
- Specified by:
keySet
in interfaceByteFloatMap
-
values
public MutableFloatCollection values()
- Specified by:
values
in interfaceFloatValuesMap
-
-