public class Char2ByteAVLTreeMap extends AbstractChar2ByteMap implements Char2ByteNavigableMap
AbstractChar2ByteMap.BasicEntryjava.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Char2ByteSortedMap.FastSortedSetChar2ByteMap.FastEntrySet| Constructor and Description |
|---|
Char2ByteAVLTreeMap()
Default Constructor
|
Char2ByteAVLTreeMap(char[] keys,
byte[] values)
Helper constructor that allow to create a map from unboxed values
|
Char2ByteAVLTreeMap(char[] keys,
byte[] values,
CharComparator comp)
Helper constructor that has a custom sorter and allow to create a map from unboxed values
|
Char2ByteAVLTreeMap(Char2ByteMap map)
A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
|
Char2ByteAVLTreeMap(Char2ByteMap map,
CharComparator 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.
|
Char2ByteAVLTreeMap(java.lang.Character[] keys,
java.lang.Byte[] values)
Helper constructor that allow to create a map from boxed values (it will unbox them)
|
Char2ByteAVLTreeMap(java.lang.Character[] keys,
java.lang.Byte[] values,
CharComparator comp)
Helper constructor that has a custom sorter and allow to create a map from boxed values (it will unbox them)
|
Char2ByteAVLTreeMap(CharComparator comp)
Constructor that allows to define the sorter
|
Char2ByteAVLTreeMap(java.util.Map<? extends java.lang.Character,? extends java.lang.Byte> map)
A Helper constructor that allows to create a Map with exactly the same values as the provided map.
|
Char2ByteAVLTreeMap(java.util.Map<? extends java.lang.Character,? extends java.lang.Byte> map,
CharComparator 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 |
|---|---|
byte |
addTo(char key,
byte value)
A Helper method to add a primitives together.
|
Char2ByteMap.Entry |
ceilingEntry(char key)
A Type Specific ceilingEntry method to reduce boxing/unboxing.
|
char |
ceilingKey(char e)
A Type Specific ceilingKey method to reduce boxing/unboxing.
|
ObjectSet<Char2ByteMap.Entry> |
char2ByteEntrySet()
Type Sensitive EntrySet to reduce boxing/unboxing and optionally Temp Object Allocation.
|
void |
clear() |
CharComparator |
comparator() |
byte |
computeByte(char key,
CharByteUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
byte |
computeByteIfAbsent(char key,
Char2ByteFunction mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
byte |
computeByteIfPresent(char key,
CharByteUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
boolean |
containsKey(char key)
Type Specific method to reduce boxing/unboxing of values
|
CharNavigableSet |
descendingKeySet() |
Char2ByteNavigableMap |
descendingMap() |
byte |
firstByteValue()
A method to get the first Value of a Map.
|
char |
firstCharKey()
A method to get the first Key of a Map.
|
Char2ByteMap.Entry |
firstEntry() |
Char2ByteMap.Entry |
floorEntry(char key)
A Type Specific floorEntry method to reduce boxing/unboxing.
|
char |
floorKey(char e)
A Type Specific floorKey method to reduce boxing/unboxing.
|
byte |
getAndMoveToFirst(char key)
A Specific get method that allows to move teh given key/value int the first index.
|
byte |
getAndMoveToLast(char key)
A Specific get method that allows to move teh given key/value int the last index.
|
byte |
getByte(char key)
A Type Specific get method to reduce boxing/unboxing
|
char |
getDefaultMaxValue()
A Helper method to get the max value for SubMaps.
|
char |
getDefaultMinValue()
A Helper method to get the min value for SubMaps.
|
byte |
getOrDefault(char key,
byte defaultValue)
A Type Specific getOrDefault method to reduce boxing/unboxing
|
Char2ByteNavigableMap |
headMap(char toKey,
boolean inclusive)
A Type Specific HeadMap method to reduce boxing/unboxing
|
Char2ByteMap.Entry |
higherEntry(char key)
A Type Specific higherEntry method to reduce boxing/unboxing.
|
char |
higherKey(char e)
A Type Specific higherKey method to reduce boxing/unboxing.
|
CharSortedSet |
keySet() |
byte |
lastByteValue()
A method to get the last Value of a Map.
|
char |
lastCharKey()
A method to get the last Key of a Map.
|
Char2ByteMap.Entry |
lastEntry() |
Char2ByteMap.Entry |
lowerEntry(char key)
A Type Specific lowerEntry method to reduce boxing/unboxing.
|
char |
lowerKey(char e)
A Type Specific lowerKey method to reduce boxing/unboxing.
|
void |
mergeAllByte(Char2ByteMap m,
ByteByteUnaryOperator mappingFunction)
A Bulk method for merging Maps.
|
byte |
mergeByte(char key,
byte value,
ByteByteUnaryOperator mappingFunction)
A Type Specific merge method to reduce boxing/unboxing
|
boolean |
moveToFirst(char key)
A specific move method to move a given key/value to the first index.
|
boolean |
moveToLast(char key)
A specific move method to move a given key/value to the last index.
|
CharNavigableSet |
navigableKeySet() |
char |
pollFirstCharKey()
A method to get and remove the first Key of a Map.
|
Char2ByteMap.Entry |
pollFirstEntry() |
char |
pollLastCharKey()
A method to get and remove the last Key of a Map.
|
Char2ByteMap.Entry |
pollLastEntry() |
byte |
put(char key,
byte value)
Type Specific method to reduce boxing/unboxing of values
|
byte |
putAndMoveToFirst(char key,
byte value)
A customized put method that allows you to insert into the first index.
|
byte |
putAndMoveToLast(char key,
byte value)
A customized put method that allows you to insert into the last index.
|
byte |
putIfAbsent(char key,
byte value)
Type Specific method to reduce boxing/unboxing of values
|
byte |
remChar(char key)
Type Specific remove function to reduce boxing/unboxing
|
byte |
remCharOrDefault(char key,
byte defaultValue)
Type-Specific Remove function with a default return value if wanted.
|
boolean |
remove(char key,
byte value)
Type Specific remove function to reduce boxing/unboxing
|
byte |
replace(char key,
byte value)
A Type Specific replace method to reduce boxing/unboxing replace an existing value
|
boolean |
replace(char key,
byte oldValue,
byte newValue)
A Type Specific replace method to replace an existing value
|
void |
setDefaultMaxValue(char value)
A Helper method to set the max value for SubMaps.
|
void |
setDefaultMinValue(char value)
A Helper method to set the min value for SubMaps.
|
int |
size() |
Char2ByteNavigableMap |
subMap(char fromKey,
boolean fromInclusive,
char toKey,
boolean toInclusive)
A Type Specific SubMap method to reduce boxing/unboxing
|
Char2ByteNavigableMap |
tailMap(char fromKey,
boolean inclusive)
A Type Specific TailMap method to reduce boxing/unboxing
|
ByteCollection |
values() |
addToAll, containsValue, entrySet, equals, forEach, get, getDefaultReturnValue, getOrDefault, hashCode, putAll, putAll, putAll, putAllIfAbsent, replaceBytes, replaceBytes, setDefaultReturnValuecontainsKey, containsValue, isEmpty, put, remove, toStringceilingEntry, ceilingKey, floorEntry, floorKey, headMap, headMap, headMap, higherEntry, higherKey, lowerEntry, lowerKey, subMap, subMap, subMap, tailMap, tailMap, tailMapfirstKey, lastKeyaddToAll, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, containsValue, entrySet, forEach, forEach, get, getDefaultReturnValue, getOrDefault, merge, put, putAll, putAll, putAll, putAllIfAbsent, putIfAbsent, remove, remove, replace, replace, replaceAll, replaceBytes, replaceBytes, setDefaultReturnValuepublic Char2ByteAVLTreeMap()
public Char2ByteAVLTreeMap(CharComparator comp)
comp - the function that decides how the tree is sorted, can be nullpublic Char2ByteAVLTreeMap(java.lang.Character[] keys,
java.lang.Byte[] 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 Char2ByteAVLTreeMap(java.lang.Character[] keys,
java.lang.Byte[] values,
CharComparator 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 Char2ByteAVLTreeMap(char[] keys,
byte[] 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 Char2ByteAVLTreeMap(char[] keys,
byte[] values,
CharComparator 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 Char2ByteAVLTreeMap(java.util.Map<? extends java.lang.Character,? extends java.lang.Byte> map)
map - the values that should be present in the mappublic Char2ByteAVLTreeMap(java.util.Map<? extends java.lang.Character,? extends java.lang.Byte> map,
CharComparator comp)
map - the values that should be present in the mapcomp - the function that decides how the tree is sorted, can be nullpublic Char2ByteAVLTreeMap(Char2ByteMap map)
map - the values that should be present in the mappublic Char2ByteAVLTreeMap(Char2ByteMap map, CharComparator 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(char value)
Char2ByteNavigableMapsetDefaultMaxValue in interface Char2ByteNavigableMapvalue - the new max valuepublic char getDefaultMaxValue()
Char2ByteNavigableMapgetDefaultMaxValue in interface Char2ByteNavigableMappublic void setDefaultMinValue(char value)
Char2ByteNavigableMapsetDefaultMinValue in interface Char2ByteNavigableMapvalue - the new min valuepublic char getDefaultMinValue()
Char2ByteNavigableMapgetDefaultMinValue in interface Char2ByteNavigableMappublic byte put(char key,
byte value)
Char2ByteMapput in interface Char2ByteMapkey - the key that should be inserted,value - the value that should be insertedMap.put(Object, Object)public byte putIfAbsent(char key,
byte value)
Char2ByteMapputIfAbsent in interface Char2ByteMapkey - the key that should be inserted,value - the value that should be insertedMap.putIfAbsent(Object, Object)public byte addTo(char key,
byte value)
Char2ByteMapaddTo in interface Char2ByteMapkey - the key that should be inserted,value - the value that should be inserted / addedpublic byte putAndMoveToFirst(char key,
byte value)
Char2ByteSortedMapputAndMoveToFirst in interface Char2ByteSortedMapkey - the key that should be insertedvalue - the value that should be insertedMap.put(Object, Object)public byte putAndMoveToLast(char key,
byte value)
Char2ByteSortedMapputAndMoveToLast in interface Char2ByteSortedMapkey - the key that should be insertedvalue - the value that should be insertedMap.put(Object, Object)public boolean moveToFirst(char key)
Char2ByteSortedMapmoveToFirst in interface Char2ByteSortedMapkey - that should be moved to the first indexpublic boolean moveToLast(char key)
Char2ByteSortedMapmoveToLast in interface Char2ByteSortedMapkey - that should be moved to the first lastpublic byte getAndMoveToFirst(char key)
Char2ByteSortedMapgetAndMoveToFirst in interface Char2ByteSortedMapkey - that is searched forpublic byte getAndMoveToLast(char key)
Char2ByteSortedMapgetAndMoveToLast in interface Char2ByteSortedMapkey - that is searched forpublic CharComparator comparator()
comparator in interface java.util.SortedMap<java.lang.Character,java.lang.Byte>comparator in interface Char2ByteSortedMappublic boolean containsKey(char key)
Char2ByteMapcontainsKey in interface Char2ByteMapcontainsKey in class AbstractChar2ByteMapkey - element that is searched forpublic byte getByte(char key)
Char2ByteMapgetByte in interface Char2ByteFunctiongetByte in interface Char2ByteMapkey - the key that is searched forpublic byte getOrDefault(char key,
byte defaultValue)
Char2ByteMapgetOrDefault in interface Char2ByteMapgetOrDefault in class AbstractChar2ByteMapkey - the key that is searched fordefaultValue - the value that should be returned if the key is not presentpublic char firstCharKey()
Char2ByteSortedMapfirstCharKey in interface Char2ByteSortedMappublic char pollFirstCharKey()
Char2ByteSortedMappollFirstCharKey in interface Char2ByteSortedMappublic char lastCharKey()
Char2ByteSortedMaplastCharKey in interface Char2ByteSortedMappublic char pollLastCharKey()
Char2ByteSortedMappollLastCharKey in interface Char2ByteSortedMappublic Char2ByteMap.Entry firstEntry()
firstEntry in interface java.util.NavigableMap<java.lang.Character,java.lang.Byte>firstEntry in interface Char2ByteNavigableMappublic Char2ByteMap.Entry lastEntry()
lastEntry in interface java.util.NavigableMap<java.lang.Character,java.lang.Byte>lastEntry in interface Char2ByteNavigableMappublic Char2ByteMap.Entry pollFirstEntry()
pollFirstEntry in interface java.util.NavigableMap<java.lang.Character,java.lang.Byte>pollFirstEntry in interface Char2ByteNavigableMappublic Char2ByteMap.Entry pollLastEntry()
pollLastEntry in interface java.util.NavigableMap<java.lang.Character,java.lang.Byte>pollLastEntry in interface Char2ByteNavigableMappublic byte firstByteValue()
Char2ByteSortedMapfirstByteValue in interface Char2ByteSortedMappublic byte lastByteValue()
Char2ByteSortedMaplastByteValue in interface Char2ByteSortedMappublic byte remChar(char key)
Char2ByteMapremChar in interface Char2ByteMapkey - the element that should be removedpublic byte remCharOrDefault(char key,
byte defaultValue)
Char2ByteMapremCharOrDefault in interface Char2ByteMapkey - the element that should be removeddefaultValue - the value that should be returned if the entry doesn't existMap.remove(Object, Object)public boolean remove(char key,
byte value)
Char2ByteMapremove in interface Char2ByteMapkey - the element that should be removedvalue - the expected value that should be foundMap.remove(Object, Object)public boolean replace(char key,
byte oldValue,
byte newValue)
Char2ByteMapreplace in interface Char2ByteMapreplace in class AbstractChar2ByteMapkey - the element that should be searched foroldValue - the expected value to be replacednewValue - the value to replace the oldValue with.public byte replace(char key,
byte value)
Char2ByteMapreplace in interface Char2ByteMapreplace in class AbstractChar2ByteMapkey - the element that should be searched forvalue - the value to replace with.public byte computeByte(char key,
CharByteUnaryOperator mappingFunction)
Char2ByteMapcomputeByte in interface Char2ByteMapcomputeByte in class AbstractChar2ByteMapkey - the key that should be computedmappingFunction - the operator that should generate the valuepublic byte computeByteIfAbsent(char key,
Char2ByteFunction mappingFunction)
Char2ByteMapcomputeByteIfAbsent in interface Char2ByteMapcomputeByteIfAbsent in class AbstractChar2ByteMapkey - the key that should be computedmappingFunction - the operator that should generate the value if not presentpublic byte computeByteIfPresent(char key,
CharByteUnaryOperator mappingFunction)
Char2ByteMapcomputeByteIfPresent in interface Char2ByteMapcomputeByteIfPresent in class AbstractChar2ByteMapkey - the key that should be computedmappingFunction - the operator that should generate the value if presentpublic byte mergeByte(char key,
byte value,
ByteByteUnaryOperator mappingFunction)
Char2ByteMapmergeByte in interface Char2ByteMapmergeByte in class AbstractChar2ByteMapkey - the key that should be be searched forvalue - the value that should be merged withmappingFunction - the operator that should generate the new Valuepublic void mergeAllByte(Char2ByteMap m, ByteByteUnaryOperator mappingFunction)
Char2ByteMapmergeAllByte in interface Char2ByteMapmergeAllByte in class AbstractChar2ByteMapm - the entries that should be bulk addedmappingFunction - the operator that should generate the new Valuepublic int size()
size in interface java.util.Map<java.lang.Character,java.lang.Byte>size in class java.util.AbstractMap<java.lang.Character,java.lang.Byte>public void clear()
clear in interface java.util.Map<java.lang.Character,java.lang.Byte>clear in class java.util.AbstractMap<java.lang.Character,java.lang.Byte>public CharSortedSet keySet()
keySet in interface java.util.Map<java.lang.Character,java.lang.Byte>keySet in interface java.util.SortedMap<java.lang.Character,java.lang.Byte>keySet in interface Char2ByteMapkeySet in interface Char2ByteSortedMapkeySet in class AbstractChar2ByteMappublic ObjectSet<Char2ByteMap.Entry> char2ByteEntrySet()
Char2ByteMapchar2ByteEntrySet in interface Char2ByteMappublic ByteCollection values()
values in interface java.util.Map<java.lang.Character,java.lang.Byte>values in interface java.util.SortedMap<java.lang.Character,java.lang.Byte>values in interface Char2ByteMapvalues in interface Char2ByteSortedMapvalues in class AbstractChar2ByteMappublic CharNavigableSet navigableKeySet()
navigableKeySet in interface java.util.NavigableMap<java.lang.Character,java.lang.Byte>navigableKeySet in interface Char2ByteNavigableMappublic Char2ByteNavigableMap descendingMap()
descendingMap in interface java.util.NavigableMap<java.lang.Character,java.lang.Byte>descendingMap in interface Char2ByteNavigableMappublic CharNavigableSet descendingKeySet()
descendingKeySet in interface java.util.NavigableMap<java.lang.Character,java.lang.Byte>descendingKeySet in interface Char2ByteNavigableMappublic Char2ByteNavigableMap subMap(char fromKey, boolean fromInclusive, char toKey, boolean toInclusive)
Char2ByteNavigableMapsubMap in interface Char2ByteNavigableMapfromKey - where the submap should startfromInclusive - if the fromKey is inclusive or nottoKey - where the subMap should endtoInclusive - if the toKey is inclusive or notpublic Char2ByteNavigableMap headMap(char toKey, boolean inclusive)
Char2ByteNavigableMapheadMap in interface Char2ByteNavigableMaptoKey - where the HeadMap should endinclusive - if the toKey is inclusive or notpublic Char2ByteNavigableMap tailMap(char fromKey, boolean inclusive)
Char2ByteNavigableMaptailMap in interface Char2ByteNavigableMapfromKey - where the TailMap should startinclusive - if the fromKey is inclusive or notpublic char lowerKey(char e)
Char2ByteNavigableMaplowerKey in interface Char2ByteNavigableMape - that should be compared with.public char floorKey(char e)
Char2ByteNavigableMapfloorKey in interface Char2ByteNavigableMape - that should be compared with.public char higherKey(char e)
Char2ByteNavigableMaphigherKey in interface Char2ByteNavigableMape - that should be compared with.public char ceilingKey(char e)
Char2ByteNavigableMapceilingKey in interface Char2ByteNavigableMape - that should be compared with.public Char2ByteMap.Entry lowerEntry(char key)
Char2ByteNavigableMaplowerEntry in interface Char2ByteNavigableMapkey - that should be compared with.public Char2ByteMap.Entry higherEntry(char key)
Char2ByteNavigableMaphigherEntry in interface Char2ByteNavigableMapkey - that should be compared with.public Char2ByteMap.Entry floorEntry(char key)
Char2ByteNavigableMapfloorEntry in interface Char2ByteNavigableMapkey - that should be compared with.public Char2ByteMap.Entry ceilingEntry(char key)
Char2ByteNavigableMapceilingEntry in interface Char2ByteNavigableMapkey - that should be compared with.