public abstract class AbstractChar2FloatMap extends java.util.AbstractMap<java.lang.Character,java.lang.Float> implements Char2FloatMap
| Modifier and Type | Class and Description |
|---|---|
static class |
AbstractChar2FloatMap.BasicEntry
A Simple Type Specific Entry class to reduce boxing/unboxing
|
java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Char2FloatMap.BuilderCache, Char2FloatMap.Entry, Char2FloatMap.FastEntrySet, Char2FloatMap.MapBuilder| Constructor and Description |
|---|
AbstractChar2FloatMap() |
| Modifier and Type | Method and Description |
|---|---|
void |
addToAll(Char2FloatMap m)
A Helper method to bulk add primitives together.
|
float |
computeFloat(char key,
CharFloatUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
float |
computeFloatIfAbsent(char key,
Char2FloatFunction mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
float |
computeFloatIfPresent(char key,
CharFloatUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
boolean |
containsKey(char key)
Type Specific method to reduce boxing/unboxing of values
|
boolean |
containsValue(float value)
Type Specific method to reduce boxing/unboxing of values
|
Char2FloatMap |
copy()
A Function that does a shallow clone of the Map itself.
|
ObjectSet<java.util.Map.Entry<java.lang.Character,java.lang.Float>> |
entrySet() |
boolean |
equals(java.lang.Object o) |
void |
forEach(CharFloatConsumer action)
Type Specific forEach method to reduce boxing/unboxing
|
java.lang.Float |
get(java.lang.Object key) |
float |
getDefaultReturnValue()
Method to see what the default return value is.
|
float |
getOrDefault(char key,
float defaultValue)
A Type Specific getOrDefault method to reduce boxing/unboxing
|
java.lang.Float |
getOrDefault(java.lang.Object key,
java.lang.Float defaultValue) |
int |
hashCode() |
CharSet |
keySet() |
void |
mergeAllFloat(Char2FloatMap m,
FloatFloatUnaryOperator mappingFunction)
A Bulk method for merging Maps.
|
float |
mergeFloat(char key,
float value,
FloatFloatUnaryOperator mappingFunction)
A Type Specific merge method to reduce boxing/unboxing
|
java.lang.Float |
put(java.lang.Character key,
java.lang.Float value)
Deprecated.
|
void |
putAll(char[] keys,
float[] values,
int offset,
int size)
Type Specific array method to bulk add elements into a map without creating a wrapper and increasing performances
|
void |
putAll(Char2FloatMap m)
Type Specific function for the bull putting of values
|
void |
putAll(java.lang.Character[] keys,
java.lang.Float[] values,
int offset,
int size)
Type Specific Object array method to bulk add elements into a map without creating a wrapper and increasing performances
|
void |
putAll(java.util.Map<? extends java.lang.Character,? extends java.lang.Float> m) |
void |
putAllIfAbsent(Char2FloatMap m)
Type-Specific bulk put method put elements into the map if not present.
|
java.lang.Float |
remove(java.lang.Object key) |
float |
replace(char key,
float value)
A Type Specific replace method to reduce boxing/unboxing replace an existing value
|
boolean |
replace(char key,
float oldValue,
float newValue)
A Type Specific replace method to replace an existing value
|
void |
replaceFloats(Char2FloatMap m)
Type-Specific bulk replace method.
|
void |
replaceFloats(CharFloatUnaryOperator mappingFunction)
A Type Specific mass replace method to reduce boxing/unboxing
|
AbstractChar2FloatMap |
setDefaultReturnValue(float v)
Method to define the default return value if a requested key isn't present
|
float |
supplyFloatIfAbsent(char key,
FloatSupplier valueProvider)
A Supplier based computeIfAbsent function to fill the most used usecase of this function
|
FloatCollection |
values() |
clear, containsKey, containsValue, isEmpty, size, toStringaddTo, applyAsFloat, builder, char2FloatEntrySet, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, forEach, get, merge, put, put, put, putAll, putAll, putIfAbsent, putIfAbsent, remove, remove, remove, removeOrDefault, replace, replace, replaceAll, subFrom, synchronize, synchronize, unmodifiablepublic float getDefaultReturnValue()
Char2FloatMapgetDefaultReturnValue in interface Char2FloatMappublic AbstractChar2FloatMap setDefaultReturnValue(float v)
Char2FloatMapsetDefaultReturnValue in interface Char2FloatMapv - value that should be the default return valuepublic Char2FloatMap copy()
Char2FloatMapcopy in interface Char2FloatMap@Deprecated
public java.lang.Float put(java.lang.Character key,
java.lang.Float value)
put in interface java.util.Map<java.lang.Character,java.lang.Float>put in interface Char2FloatMapput in class java.util.AbstractMap<java.lang.Character,java.lang.Float>public void addToAll(Char2FloatMap m)
Char2FloatMapaddToAll in interface Char2FloatMapm - the values that should be added/insertedpublic void putAll(Char2FloatMap m)
Char2FloatMapputAll in interface Char2FloatMapm - the elements that should be insertedpublic void putAll(java.util.Map<? extends java.lang.Character,? extends java.lang.Float> m)
putAll in interface java.util.Map<java.lang.Character,java.lang.Float>putAll in class java.util.AbstractMap<java.lang.Character,java.lang.Float>public void putAll(char[] keys,
float[] values,
int offset,
int size)
Char2FloatMapputAll in interface Char2FloatMapkeys - the keys that should be addedvalues - the values that should be addedoffset - where the to start in the arraysize - how many elements should be addedMap.putAll(Map)public void putAll(java.lang.Character[] keys,
java.lang.Float[] values,
int offset,
int size)
Char2FloatMapputAll in interface Char2FloatMapkeys - the keys that should be addedvalues - the values that should be addedoffset - where the to start in the arraysize - how many elements should be addedMap.putAll(Map)public void putAllIfAbsent(Char2FloatMap m)
Char2FloatMapputAllIfAbsent in interface Char2FloatMapm - elements that should be added if not present.public boolean containsKey(char key)
Char2FloatMapcontainsKey in interface Char2FloatMapkey - element that is searched forpublic boolean containsValue(float value)
Char2FloatMapcontainsValue in interface Char2FloatMapvalue - element that is searched forpublic boolean replace(char key,
float oldValue,
float newValue)
Char2FloatMapreplace in interface Char2FloatMapkey - the element that should be searched foroldValue - the expected value to be replacednewValue - the value to replace the oldValue with.public float replace(char key,
float value)
Char2FloatMapreplace in interface Char2FloatMapkey - the element that should be searched forvalue - the value to replace with.public void replaceFloats(Char2FloatMap m)
Char2FloatMapreplaceFloats in interface Char2FloatMapm - elements that should be replaced.public void replaceFloats(CharFloatUnaryOperator mappingFunction)
Char2FloatMapreplaceFloats in interface Char2FloatMapmappingFunction - operation to replace all valuespublic float computeFloat(char key,
CharFloatUnaryOperator mappingFunction)
Char2FloatMapcomputeFloat in interface Char2FloatMapkey - the key that should be computedmappingFunction - the operator that should generate the valuepublic float computeFloatIfAbsent(char key,
Char2FloatFunction mappingFunction)
Char2FloatMapcomputeFloatIfAbsent in interface Char2FloatMapkey - the key that should be computedmappingFunction - the operator that should generate the value if not presentpublic float supplyFloatIfAbsent(char key,
FloatSupplier valueProvider)
Char2FloatMapsupplyFloatIfAbsent in interface Char2FloatMapkey - the key that should be computedvalueProvider - the value if not presentpublic float computeFloatIfPresent(char key,
CharFloatUnaryOperator mappingFunction)
Char2FloatMapcomputeFloatIfPresent in interface Char2FloatMapkey - the key that should be computedmappingFunction - the operator that should generate the value if presentpublic float mergeFloat(char key,
float value,
FloatFloatUnaryOperator mappingFunction)
Char2FloatMapmergeFloat in interface Char2FloatMapkey - the key that should be be searched forvalue - the value that should be merged withmappingFunction - the operator that should generate the new Valuepublic void mergeAllFloat(Char2FloatMap m, FloatFloatUnaryOperator mappingFunction)
Char2FloatMapmergeAllFloat in interface Char2FloatMapm - the entries that should be bulk addedmappingFunction - the operator that should generate the new Valuepublic java.lang.Float get(java.lang.Object key)
get in interface java.util.Map<java.lang.Character,java.lang.Float>get in interface Char2FloatMapget in class java.util.AbstractMap<java.lang.Character,java.lang.Float>public java.lang.Float getOrDefault(java.lang.Object key,
java.lang.Float defaultValue)
getOrDefault in interface java.util.Map<java.lang.Character,java.lang.Float>getOrDefault in interface Char2FloatMappublic float getOrDefault(char key,
float defaultValue)
Char2FloatMapgetOrDefault in interface Char2FloatMapkey - the key that is searched fordefaultValue - the value that should be returned if the key is not presentpublic java.lang.Float remove(java.lang.Object key)
remove in interface java.util.Map<java.lang.Character,java.lang.Float>remove in interface Char2FloatMapremove in class java.util.AbstractMap<java.lang.Character,java.lang.Float>key - the element that should be removedMap.remove(Object)public void forEach(CharFloatConsumer action)
Char2FloatMapforEach in interface Char2FloatMapaction - processor of the values that are iterator overpublic CharSet keySet()
keySet in interface java.util.Map<java.lang.Character,java.lang.Float>keySet in interface Char2FloatMapkeySet in class java.util.AbstractMap<java.lang.Character,java.lang.Float>public FloatCollection values()
values in interface java.util.Map<java.lang.Character,java.lang.Float>values in interface Char2FloatMapvalues in class java.util.AbstractMap<java.lang.Character,java.lang.Float>public ObjectSet<java.util.Map.Entry<java.lang.Character,java.lang.Float>> entrySet()
entrySet in interface java.util.Map<java.lang.Character,java.lang.Float>entrySet in interface Char2FloatMapentrySet in class java.util.AbstractMap<java.lang.Character,java.lang.Float>public boolean equals(java.lang.Object o)
equals in interface java.util.Map<java.lang.Character,java.lang.Float>equals in class java.util.AbstractMap<java.lang.Character,java.lang.Float>public int hashCode()
hashCode in interface java.util.Map<java.lang.Character,java.lang.Float>hashCode in class java.util.AbstractMap<java.lang.Character,java.lang.Float>