Externalizable, Serializable, FloatShortMap, MutableFloatShortMap, MutableShortValuesMap, ShortValuesMap, PrimitiveIterable, ShortIterable, MutableFloatKeysMap, FloatKeysMappublic class FloatShortHashMap extends AbstractMutableShortValuesMap implements MutableFloatShortMap, Externalizable, MutableFloatKeysMap
| Constructor | Description |
|---|---|
FloatShortHashMap() |
|
FloatShortHashMap(int initialCapacity) |
|
FloatShortHashMap(FloatShortMap map) |
| Modifier and Type | Method | Description |
|---|---|---|
short |
addToValue(float key,
short toBeAdded) |
|
MutableFloatShortMap |
asSynchronized() |
|
MutableFloatShortMap |
asUnmodifiable() |
|
void |
clear() |
|
void |
compact() |
Rehashes every element in the set into a new backing table of the smallest possible size and eliminating removed sentinels.
|
boolean |
containsKey(float key) |
|
boolean |
equals(Object obj) |
Follows the same general contract as
Map.equals(Object). |
MutableShortFloatMap |
flipUniqueValues() |
Return the ShortFloatMap that is obtained by flipping the direction of this map and making the associations
from value to key.
|
void |
forEachKey(FloatProcedure procedure) |
|
void |
forEachKeyValue(FloatShortProcedure procedure) |
|
short |
get(float key) |
|
short |
getIfAbsent(float key,
short ifAbsent) |
|
short |
getIfAbsentPut(float key,
short value) |
|
short |
getIfAbsentPut(float key,
ShortFunction0 function) |
|
<P> short |
getIfAbsentPutWith(float key,
ShortFunction<? super P> function,
P parameter) |
|
short |
getIfAbsentPutWithKey(float key,
FloatToShortFunction function) |
|
short |
getOrThrow(float key) |
|
int |
hashCode() |
Follows the same general contract as
Map.hashCode(). |
<V> V |
injectInto(V injectedValue,
ObjectShortToObjectFunction<? super V,? extends V> function) |
|
MutableFloatSet |
keySet() |
|
LazyFloatIterable |
keysView() |
|
RichIterable<FloatShortPair> |
keyValuesView() |
|
static FloatShortHashMap |
newWithKeysValues(float key1,
short value1) |
|
static FloatShortHashMap |
newWithKeysValues(float key1,
short value1,
float key2,
short value2) |
|
static FloatShortHashMap |
newWithKeysValues(float key1,
short value1,
float key2,
short value2,
float key3,
short value3) |
|
static FloatShortHashMap |
newWithKeysValues(float key1,
short value1,
float key2,
short value2,
float key3,
short value3,
float key4,
short value4) |
|
void |
put(float key,
short value) |
|
void |
putAll(FloatShortMap map) |
|
void |
readExternal(ObjectInput in) |
|
FloatShortHashMap |
reject(FloatShortPredicate predicate) |
|
void |
remove(float key) |
|
void |
removeKey(float key) |
|
short |
removeKeyIfAbsent(float key,
short value) |
|
FloatShortHashMap |
select(FloatShortPredicate predicate) |
|
MutableShortIterator |
shortIterator() |
Returns a primitive iterator that can be used to iterate over the ShortIterable in an
imperative style.
|
ImmutableFloatShortMap |
toImmutable() |
|
String |
toString() |
Returns a string with the elements of this iterable separated by commas with spaces and
enclosed in square brackets.
|
short |
updateValue(float key,
short initialValueIfAbsent,
ShortToShortFunction function) |
|
void |
updateValues(FloatShortToShortFunction function) |
Updates the values in-place.
|
MutableShortCollection |
values() |
|
FloatShortHashMap |
withKeysValues(float key1,
short value1,
float key2,
short value2) |
|
FloatShortHashMap |
withKeysValues(float key1,
short value1,
float key2,
short value2,
float key3,
short value3) |
|
FloatShortHashMap |
withKeysValues(float key1,
short value1,
float key2,
short value2,
float key3,
short value3,
float key4,
short value4) |
|
FloatShortHashMap |
withKeyValue(float key1,
short value1) |
|
FloatShortHashMap |
withoutAllKeys(FloatIterable keys) |
|
FloatShortHashMap |
withoutKey(float key) |
|
void |
writeExternal(ObjectOutput out) |
allSatisfy, anySatisfy, appendString, chunk, collect, contains, containsAll, containsValue, count, detectIfNone, each, forEach, forEachValue, isEmpty, max, min, noneSatisfy, notEmpty, reject, select, size, sum, toArrayasLazy, average, containsAll, maxIfEmpty, median, minIfEmpty, toBag, toList, toSet, toSortedArray, toSortedListisEmpty, notEmpty, sizeputPair, withAllKeyValuescollect, reject, selectappendString, appendString, appendString, isEmpty, makeString, makeString, makeString, notEmpty, sizeallSatisfy, anySatisfy, asLazy, average, averageIfEmpty, chunk, collect, collectBoolean, collectByte, collectChar, collectDouble, collectFloat, collectInt, collectLong, collectShort, contains, containsAll, containsAll, count, detectIfNone, each, flatCollect, forEach, max, maxIfEmpty, median, medianIfEmpty, min, minIfEmpty, noneSatisfy, reduce, reduceIfEmpty, reject, select, sum, summaryStatistics, toArray, toBag, toList, toSet, toSortedArray, toSortedListcontainsValue, forEachValue, tappublic FloatShortHashMap()
public FloatShortHashMap(int initialCapacity)
public FloatShortHashMap(FloatShortMap map)
public static FloatShortHashMap newWithKeysValues(float key1, short value1)
public static FloatShortHashMap newWithKeysValues(float key1, short value1, float key2, short value2)
public static FloatShortHashMap newWithKeysValues(float key1, short value1, float key2, short value2, float key3, short value3)
public static FloatShortHashMap newWithKeysValues(float key1, short value1, float key2, short value2, float key3, short value3, float key4, short value4)
public boolean equals(Object obj)
FloatShortMapMap.equals(Object).equals in interface FloatShortMapequals in class Objectpublic int hashCode()
FloatShortMapMap.hashCode().hashCode in interface FloatShortMaphashCode in class Objectpublic String toString()
PrimitiveIterable
Assert.assertEquals("[]", IntLists.mutable.empty().toString());
Assert.assertEquals("[1]", IntLists.mutable.with(1).toString());
Assert.assertEquals("[1, 2, 3]", IntLists.mutable.with(1, 2, 3).toString());
toString in interface FloatShortMaptoString in interface PrimitiveIterabletoString in class AbstractShortIterableAbstractCollection.toString()public MutableShortIterator shortIterator()
ShortIterableshortIterator in interface MutableShortValuesMapshortIterator in interface ShortIterablepublic <V> V injectInto(V injectedValue,
ObjectShortToObjectFunction<? super V,? extends V> function)
injectInto in interface ShortIterablepublic void clear()
clear in interface MutableFloatKeysMapclear in interface MutableShortValuesMappublic void put(float key,
short value)
put in interface MutableFloatShortMappublic void putAll(FloatShortMap map)
putAll in interface MutableFloatShortMappublic void updateValues(FloatShortToShortFunction function)
MutableFloatShortMapupdateValues in interface MutableFloatShortMapfunction - that takes a key and its value and that returns a new value for this keypublic void removeKey(float key)
removeKey in interface MutableFloatKeysMapremoveKey in interface MutableFloatShortMappublic void remove(float key)
remove in interface MutableFloatShortMappublic short removeKeyIfAbsent(float key,
short value)
removeKeyIfAbsent in interface MutableFloatShortMappublic short getIfAbsentPut(float key,
short value)
getIfAbsentPut in interface MutableFloatShortMappublic short getIfAbsentPut(float key,
ShortFunction0 function)
getIfAbsentPut in interface MutableFloatShortMappublic <P> short getIfAbsentPutWith(float key,
ShortFunction<? super P> function,
P parameter)
getIfAbsentPutWith in interface MutableFloatShortMappublic short getIfAbsentPutWithKey(float key,
FloatToShortFunction function)
getIfAbsentPutWithKey in interface MutableFloatShortMappublic short addToValue(float key,
short toBeAdded)
addToValue in interface MutableFloatShortMappublic short updateValue(float key,
short initialValueIfAbsent,
ShortToShortFunction function)
updateValue in interface MutableFloatShortMappublic FloatShortHashMap withKeyValue(float key1, short value1)
withKeyValue in interface MutableFloatShortMappublic FloatShortHashMap withKeysValues(float key1, short value1, float key2, short value2)
public FloatShortHashMap withKeysValues(float key1, short value1, float key2, short value2, float key3, short value3)
public FloatShortHashMap withKeysValues(float key1, short value1, float key2, short value2, float key3, short value3, float key4, short value4)
public FloatShortHashMap withoutKey(float key)
withoutKey in interface MutableFloatShortMappublic FloatShortHashMap withoutAllKeys(FloatIterable keys)
withoutAllKeys in interface MutableFloatShortMappublic MutableFloatShortMap asUnmodifiable()
asUnmodifiable in interface MutableFloatShortMappublic MutableFloatShortMap asSynchronized()
asSynchronized in interface MutableFloatShortMappublic ImmutableFloatShortMap toImmutable()
toImmutable in interface FloatShortMappublic short get(float key)
get in interface FloatShortMappublic short getIfAbsent(float key,
short ifAbsent)
getIfAbsent in interface FloatShortMappublic short getOrThrow(float key)
getOrThrow in interface FloatShortMappublic boolean containsKey(float key)
containsKey in interface FloatKeysMapcontainsKey in interface FloatShortMappublic void forEachKey(FloatProcedure procedure)
forEachKey in interface FloatKeysMapforEachKey in interface FloatShortMappublic void forEachKeyValue(FloatShortProcedure procedure)
forEachKeyValue in interface FloatShortMappublic LazyFloatIterable keysView()
keysView in interface FloatShortMappublic RichIterable<FloatShortPair> keyValuesView()
keyValuesView in interface FloatShortMappublic MutableShortFloatMap flipUniqueValues()
FloatShortMapflipUniqueValues in interface FloatShortMapflipUniqueValues in interface MutableFloatShortMappublic FloatShortHashMap select(FloatShortPredicate predicate)
select in interface FloatShortMapselect in interface MutableFloatShortMappublic FloatShortHashMap reject(FloatShortPredicate predicate)
reject in interface FloatShortMapreject in interface MutableFloatShortMappublic void writeExternal(ObjectOutput out) throws IOException
writeExternal in interface ExternalizableIOExceptionpublic void readExternal(ObjectInput in) throws IOException, ClassNotFoundException
readExternal in interface ExternalizableIOExceptionClassNotFoundExceptionpublic void compact()
public MutableFloatSet keySet()
keySet in interface FloatShortMappublic MutableShortCollection values()
values in interface ShortValuesMapCopyright © 2004–2019. All rights reserved.