public class Double2FloatAVLTreeMap extends AbstractDouble2FloatMap implements Double2FloatNavigableMap
AbstractDouble2FloatMap.BasicEntryjava.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Double2FloatSortedMap.FastSortedSetDouble2FloatMap.BuilderCache, Double2FloatMap.Entry, Double2FloatMap.FastEntrySet, Double2FloatMap.MapBuilder| Constructor and Description |
|---|
Double2FloatAVLTreeMap()
Default Constructor
|
Double2FloatAVLTreeMap(double[] keys,
float[] values)
Helper constructor that allow to create a map from unboxed values
|
Double2FloatAVLTreeMap(java.lang.Double[] keys,
java.lang.Float[] values)
Helper constructor that allow to create a map from boxed values (it will unbox them)
|
Double2FloatAVLTreeMap(double[] keys,
float[] values,
DoubleComparator comp)
Helper constructor that has a custom sorter and allow to create a map from unboxed values
|
Double2FloatAVLTreeMap(java.lang.Double[] keys,
java.lang.Float[] values,
DoubleComparator comp)
Helper constructor that has a custom sorter and allow to create a map from boxed values (it will unbox them)
|
Double2FloatAVLTreeMap(Double2FloatMap map)
A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
|
Double2FloatAVLTreeMap(Double2FloatMap map,
DoubleComparator comp)
A Type Specific Helper function that has a custom sorter and allows to create a new Map with exactly the same values as the provided map.
|
Double2FloatAVLTreeMap(DoubleComparator comp)
Constructor that allows to define the sorter
|
Double2FloatAVLTreeMap(java.util.Map<? extends java.lang.Double,? extends java.lang.Float> map)
A Helper constructor that allows to create a Map with exactly the same values as the provided map.
|
Double2FloatAVLTreeMap(java.util.Map<? extends java.lang.Double,? extends java.lang.Float> map,
DoubleComparator comp)
A Helper constructor that has a custom sorter and allows to create a Map with exactly the same values as the provided map.
|
| Modifier and Type | Method and Description |
|---|---|
float |
addTo(double key,
float value)
A Helper method to add a primitives together.
|
Double2FloatMap.Entry |
ceilingEntry(double key)
A Type Specific ceilingEntry method to reduce boxing/unboxing.
|
double |
ceilingKey(double e)
A Type Specific ceilingKey method to reduce boxing/unboxing.
|
void |
clear() |
DoubleComparator |
comparator() |
float |
computeFloat(double key,
DoubleFloatUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
float |
computeFloatIfAbsent(double key,
Double2FloatFunction mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
float |
computeFloatIfPresent(double key,
DoubleFloatUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
boolean |
containsKey(double key)
Type Specific method to reduce boxing/unboxing of values
|
Double2FloatAVLTreeMap |
copy()
A Function that does a shallow clone of the Map itself.
|
DoubleNavigableSet |
descendingKeySet() |
Double2FloatNavigableMap |
descendingMap() |
ObjectSet<Double2FloatMap.Entry> |
double2FloatEntrySet()
Type Sensitive EntrySet to reduce boxing/unboxing and optionally Temp Object Allocation.
|
double |
firstDoubleKey()
A method to get the first Key of a Map.
|
Double2FloatMap.Entry |
firstEntry() |
float |
firstFloatValue()
A method to get the first Value of a Map.
|
Double2FloatMap.Entry |
floorEntry(double key)
A Type Specific floorEntry method to reduce boxing/unboxing.
|
double |
floorKey(double e)
A Type Specific floorKey method to reduce boxing/unboxing.
|
void |
forEach(DoubleFloatConsumer action)
Type Specific forEach method to reduce boxing/unboxing
|
float |
get(double key)
A Type Specific get method to reduce boxing/unboxing
|
double |
getDefaultMaxValue()
A Helper method to get the max value for SubMaps.
|
double |
getDefaultMinValue()
A Helper method to get the min value for SubMaps.
|
float |
getOrDefault(double key,
float defaultValue)
A Type Specific getOrDefault method to reduce boxing/unboxing
|
Double2FloatNavigableMap |
headMap(double toKey,
boolean inclusive)
A Type Specific HeadMap method to reduce boxing/unboxing
|
Double2FloatMap.Entry |
higherEntry(double key)
A Type Specific higherEntry method to reduce boxing/unboxing.
|
double |
higherKey(double e)
A Type Specific higherKey method to reduce boxing/unboxing.
|
DoubleNavigableSet |
keySet() |
double |
lastDoubleKey()
A method to get the last Key of a Map.
|
Double2FloatMap.Entry |
lastEntry() |
float |
lastFloatValue()
A method to get the last Value of a Map.
|
Double2FloatMap.Entry |
lowerEntry(double key)
A Type Specific lowerEntry method to reduce boxing/unboxing.
|
double |
lowerKey(double e)
A Type Specific lowerKey method to reduce boxing/unboxing.
|
void |
mergeAllFloat(Double2FloatMap m,
FloatFloatUnaryOperator mappingFunction)
A Bulk method for merging Maps.
|
float |
mergeFloat(double key,
float value,
FloatFloatUnaryOperator mappingFunction)
A Type Specific merge method to reduce boxing/unboxing
|
DoubleNavigableSet |
navigableKeySet() |
double |
pollFirstDoubleKey()
A method to get and remove the first Key of a Map.
|
Double2FloatMap.Entry |
pollFirstEntry() |
double |
pollLastDoubleKey()
A method to get and remove the last Key of a Map.
|
Double2FloatMap.Entry |
pollLastEntry() |
float |
put(double key,
float value)
Type Specific method to reduce boxing/unboxing of values
|
float |
putIfAbsent(double key,
float value)
Type Specific method to reduce boxing/unboxing of values
|
float |
remove(double key)
Type Specific remove function to reduce boxing/unboxing
|
boolean |
remove(double key,
float value)
Type Specific remove function to reduce boxing/unboxing
|
float |
removeOrDefault(double key,
float defaultValue)
Type-Specific Remove function with a default return value if wanted.
|
float |
replace(double key,
float value)
A Type Specific replace method to reduce boxing/unboxing replace an existing value
|
boolean |
replace(double key,
float oldValue,
float newValue)
A Type Specific replace method to replace an existing value
|
void |
setDefaultMaxValue(double value)
A Helper method to set the max value for SubMaps.
|
void |
setDefaultMinValue(double value)
A Helper method to set the min value for SubMaps.
|
int |
size() |
float |
subFrom(double key,
float value)
A Helper method to subtract from primitive from each other.
|
Double2FloatNavigableMap |
subMap(double fromKey,
boolean fromInclusive,
double toKey,
boolean toInclusive)
A Type Specific SubMap method to reduce boxing/unboxing
|
float |
supplyFloatIfAbsent(double key,
FloatSupplier valueProvider)
A Supplier based computeIfAbsent function to fill the most used usecase of this function
|
Double2FloatNavigableMap |
tailMap(double fromKey,
boolean inclusive)
A Type Specific TailMap method to reduce boxing/unboxing
|
FloatCollection |
values() |
addToAll, containsValue, entrySet, equals, get, getDefaultReturnValue, getOrDefault, hashCode, put, putAll, putAll, putAll, putAll, putAllIfAbsent, remove, replaceFloats, replaceFloats, setDefaultReturnValueceilingEntry, ceilingKey, floorEntry, floorKey, headMap, headMap, headMap, higherEntry, higherKey, lowerEntry, lowerKey, subMap, subMap, subMap, synchronize, synchronize, tailMap, tailMap, tailMap, unmodifiablefirstKey, lastKeyaddToAll, applyAsFloat, builder, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, containsValue, entrySet, forEach, get, getDefaultReturnValue, getOrDefault, merge, put, put, put, putAll, putAll, putAll, putAll, putAll, putAllIfAbsent, putIfAbsent, remove, remove, replace, replace, replaceAll, replaceFloats, replaceFloats, setDefaultReturnValuepublic Double2FloatAVLTreeMap()
public Double2FloatAVLTreeMap(DoubleComparator comp)
comp - the function that decides how the tree is sorted, can be nullpublic Double2FloatAVLTreeMap(java.lang.Double[] keys,
java.lang.Float[] values)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.java.lang.IllegalStateException - if the keys and values do not match in lenghtpublic Double2FloatAVLTreeMap(java.lang.Double[] keys,
java.lang.Float[] values,
DoubleComparator comp)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.comp - the function that decides how the tree is sorted, can be nulljava.lang.IllegalStateException - if the keys and values do not match in lenghtpublic Double2FloatAVLTreeMap(double[] keys,
float[] values)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.java.lang.IllegalStateException - if the keys and values do not match in lenghtpublic Double2FloatAVLTreeMap(double[] keys,
float[] values,
DoubleComparator comp)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.comp - the function that decides how the tree is sorted, can be nulljava.lang.IllegalStateException - if the keys and values do not match in lenghtpublic Double2FloatAVLTreeMap(java.util.Map<? extends java.lang.Double,? extends java.lang.Float> map)
map - the values that should be present in the mappublic Double2FloatAVLTreeMap(java.util.Map<? extends java.lang.Double,? extends java.lang.Float> map,
DoubleComparator comp)
map - the values that should be present in the mapcomp - the function that decides how the tree is sorted, can be nullpublic Double2FloatAVLTreeMap(Double2FloatMap map)
map - the values that should be present in the mappublic Double2FloatAVLTreeMap(Double2FloatMap map, DoubleComparator comp)
map - the values that should be present in the mapcomp - the function that decides how the tree is sorted, can be nullpublic void setDefaultMaxValue(double value)
Double2FloatNavigableMapsetDefaultMaxValue in interface Double2FloatNavigableMapvalue - the new max valuepublic double getDefaultMaxValue()
Double2FloatNavigableMapgetDefaultMaxValue in interface Double2FloatNavigableMappublic void setDefaultMinValue(double value)
Double2FloatNavigableMapsetDefaultMinValue in interface Double2FloatNavigableMapvalue - the new min valuepublic double getDefaultMinValue()
Double2FloatNavigableMapgetDefaultMinValue in interface Double2FloatNavigableMappublic float put(double key,
float value)
Double2FloatMapput in interface Double2FloatMapkey - the key that should be inserted,value - the value that should be insertedMap.put(Object, Object)public float putIfAbsent(double key,
float value)
Double2FloatMapputIfAbsent in interface Double2FloatMapkey - the key that should be inserted,value - the value that should be insertedMap.putIfAbsent(Object, Object)public float addTo(double key,
float value)
Double2FloatMapaddTo in interface Double2FloatMapkey - the key that should be inserted,value - the value that should be inserted / addedpublic float subFrom(double key,
float value)
Double2FloatMapDouble2FloatMap.getDefaultReturnValue()
If the fence is reached the element will be automaticall removedsubFrom in interface Double2FloatMapkey - that should be subtract fromvalue - that should be subtractpublic DoubleComparator comparator()
comparator in interface java.util.SortedMap<java.lang.Double,java.lang.Float>comparator in interface Double2FloatSortedMappublic boolean containsKey(double key)
Double2FloatMapcontainsKey in interface Double2FloatMapcontainsKey in class AbstractDouble2FloatMapkey - element that is searched forpublic float get(double key)
Double2FloatMapget in interface Double2FloatMapkey - the key that is searched forpublic float getOrDefault(double key,
float defaultValue)
Double2FloatMapgetOrDefault in interface Double2FloatMapgetOrDefault in class AbstractDouble2FloatMapkey - the key that is searched fordefaultValue - the value that should be returned if the key is not presentpublic double firstDoubleKey()
Double2FloatSortedMapfirstDoubleKey in interface Double2FloatSortedMappublic double pollFirstDoubleKey()
Double2FloatSortedMappollFirstDoubleKey in interface Double2FloatSortedMappublic double lastDoubleKey()
Double2FloatSortedMaplastDoubleKey in interface Double2FloatSortedMappublic double pollLastDoubleKey()
Double2FloatSortedMappollLastDoubleKey in interface Double2FloatSortedMappublic Double2FloatMap.Entry firstEntry()
firstEntry in interface java.util.NavigableMap<java.lang.Double,java.lang.Float>firstEntry in interface Double2FloatNavigableMappublic Double2FloatMap.Entry lastEntry()
lastEntry in interface java.util.NavigableMap<java.lang.Double,java.lang.Float>lastEntry in interface Double2FloatNavigableMappublic Double2FloatMap.Entry pollFirstEntry()
pollFirstEntry in interface java.util.NavigableMap<java.lang.Double,java.lang.Float>pollFirstEntry in interface Double2FloatNavigableMappublic Double2FloatMap.Entry pollLastEntry()
pollLastEntry in interface java.util.NavigableMap<java.lang.Double,java.lang.Float>pollLastEntry in interface Double2FloatNavigableMappublic float firstFloatValue()
Double2FloatSortedMapfirstFloatValue in interface Double2FloatSortedMappublic float lastFloatValue()
Double2FloatSortedMaplastFloatValue in interface Double2FloatSortedMappublic float remove(double key)
Double2FloatMapremove in interface Double2FloatMapkey - the element that should be removedpublic float removeOrDefault(double key,
float defaultValue)
Double2FloatMapremoveOrDefault in interface Double2FloatMapkey - the element that should be removeddefaultValue - the value that should be returned if the entry doesn't existMap.remove(Object, Object)public boolean remove(double key,
float value)
Double2FloatMapremove in interface Double2FloatMapkey - the element that should be removedvalue - the expected value that should be foundMap.remove(Object, Object)public boolean replace(double key,
float oldValue,
float newValue)
Double2FloatMapreplace in interface Double2FloatMapreplace in class AbstractDouble2FloatMapkey - the element that should be searched foroldValue - the expected value to be replacednewValue - the value to replace the oldValue with.public float replace(double key,
float value)
Double2FloatMapreplace in interface Double2FloatMapreplace in class AbstractDouble2FloatMapkey - the element that should be searched forvalue - the value to replace with.public float computeFloat(double key,
DoubleFloatUnaryOperator mappingFunction)
Double2FloatMapcomputeFloat in interface Double2FloatMapcomputeFloat in class AbstractDouble2FloatMapkey - the key that should be computedmappingFunction - the operator that should generate the valuepublic float computeFloatIfAbsent(double key,
Double2FloatFunction mappingFunction)
Double2FloatMapcomputeFloatIfAbsent in interface Double2FloatMapcomputeFloatIfAbsent in class AbstractDouble2FloatMapkey - the key that should be computedmappingFunction - the operator that should generate the value if not presentpublic float supplyFloatIfAbsent(double key,
FloatSupplier valueProvider)
Double2FloatMapsupplyFloatIfAbsent in interface Double2FloatMapsupplyFloatIfAbsent in class AbstractDouble2FloatMapkey - the key that should be computedvalueProvider - the value if not presentpublic float computeFloatIfPresent(double key,
DoubleFloatUnaryOperator mappingFunction)
Double2FloatMapcomputeFloatIfPresent in interface Double2FloatMapcomputeFloatIfPresent in class AbstractDouble2FloatMapkey - the key that should be computedmappingFunction - the operator that should generate the value if presentpublic float mergeFloat(double key,
float value,
FloatFloatUnaryOperator mappingFunction)
Double2FloatMapmergeFloat in interface Double2FloatMapmergeFloat in class AbstractDouble2FloatMapkey - 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(Double2FloatMap m, FloatFloatUnaryOperator mappingFunction)
Double2FloatMapmergeAllFloat in interface Double2FloatMapmergeAllFloat in class AbstractDouble2FloatMapm - the entries that should be bulk addedmappingFunction - the operator that should generate the new Valuepublic void forEach(DoubleFloatConsumer action)
Double2FloatMapforEach in interface Double2FloatMapforEach in class AbstractDouble2FloatMapaction - processor of the values that are iterator overpublic int size()
size in interface java.util.Map<java.lang.Double,java.lang.Float>size in class java.util.AbstractMap<java.lang.Double,java.lang.Float>public void clear()
clear in interface java.util.Map<java.lang.Double,java.lang.Float>clear in class java.util.AbstractMap<java.lang.Double,java.lang.Float>public Double2FloatAVLTreeMap copy()
Double2FloatMapcopy in interface Double2FloatMapcopy in interface Double2FloatNavigableMapcopy in interface Double2FloatSortedMapcopy in class AbstractDouble2FloatMappublic DoubleNavigableSet keySet()
keySet in interface java.util.Map<java.lang.Double,java.lang.Float>keySet in interface java.util.SortedMap<java.lang.Double,java.lang.Float>keySet in interface Double2FloatMapkeySet in interface Double2FloatNavigableMapkeySet in interface Double2FloatSortedMapkeySet in class AbstractDouble2FloatMappublic ObjectSet<Double2FloatMap.Entry> double2FloatEntrySet()
Double2FloatMapdouble2FloatEntrySet in interface Double2FloatMappublic FloatCollection values()
values in interface java.util.Map<java.lang.Double,java.lang.Float>values in interface java.util.SortedMap<java.lang.Double,java.lang.Float>values in interface Double2FloatMapvalues in interface Double2FloatSortedMapvalues in class AbstractDouble2FloatMappublic DoubleNavigableSet navigableKeySet()
navigableKeySet in interface java.util.NavigableMap<java.lang.Double,java.lang.Float>navigableKeySet in interface Double2FloatNavigableMappublic Double2FloatNavigableMap descendingMap()
descendingMap in interface java.util.NavigableMap<java.lang.Double,java.lang.Float>descendingMap in interface Double2FloatNavigableMappublic DoubleNavigableSet descendingKeySet()
descendingKeySet in interface java.util.NavigableMap<java.lang.Double,java.lang.Float>descendingKeySet in interface Double2FloatNavigableMappublic Double2FloatNavigableMap subMap(double fromKey, boolean fromInclusive, double toKey, boolean toInclusive)
Double2FloatNavigableMapsubMap in interface Double2FloatNavigableMapfromKey - where the submap should startfromInclusive - if the fromKey is inclusive or nottoKey - where the subMap should endtoInclusive - if the toKey is inclusive or notpublic Double2FloatNavigableMap headMap(double toKey, boolean inclusive)
Double2FloatNavigableMapheadMap in interface Double2FloatNavigableMaptoKey - where the HeadMap should endinclusive - if the toKey is inclusive or notpublic Double2FloatNavigableMap tailMap(double fromKey, boolean inclusive)
Double2FloatNavigableMaptailMap in interface Double2FloatNavigableMapfromKey - where the TailMap should startinclusive - if the fromKey is inclusive or notpublic double lowerKey(double e)
Double2FloatNavigableMaplowerKey in interface Double2FloatNavigableMape - that should be compared with.public double floorKey(double e)
Double2FloatNavigableMapfloorKey in interface Double2FloatNavigableMape - that should be compared with.public double higherKey(double e)
Double2FloatNavigableMaphigherKey in interface Double2FloatNavigableMape - that should be compared with.public double ceilingKey(double e)
Double2FloatNavigableMapceilingKey in interface Double2FloatNavigableMape - that should be compared with.public Double2FloatMap.Entry lowerEntry(double key)
Double2FloatNavigableMaplowerEntry in interface Double2FloatNavigableMapkey - that should be compared with.public Double2FloatMap.Entry higherEntry(double key)
Double2FloatNavigableMaphigherEntry in interface Double2FloatNavigableMapkey - that should be compared with.public Double2FloatMap.Entry floorEntry(double key)
Double2FloatNavigableMapfloorEntry in interface Double2FloatNavigableMapkey - that should be compared with.public Double2FloatMap.Entry ceilingEntry(double key)
Double2FloatNavigableMapceilingEntry in interface Double2FloatNavigableMapkey - that should be compared with.