public class Short2LongLinkedOpenCustomHashMap extends Short2LongOpenCustomHashMap implements Short2LongSortedMap
AbstractShort2LongMap.BasicEntryjava.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Short2LongSortedMap.FastSortedSetShort2LongMap.Entry, Short2LongMap.FastEntrySet| Constructor and Description |
|---|
Short2LongLinkedOpenCustomHashMap(int minCapacity,
float loadFactor,
ShortStrategy strategy)
Constructor that defines the minimum capacity and load factor
|
Short2LongLinkedOpenCustomHashMap(int minCapacity,
ShortStrategy strategy)
Constructor that defines the minimum capacity
|
Short2LongLinkedOpenCustomHashMap(java.util.Map<? extends java.lang.Short,? extends java.lang.Long> map,
float loadFactor,
ShortStrategy strategy)
A Helper constructor that allows to create a Map with exactly the same values as the provided map.
|
Short2LongLinkedOpenCustomHashMap(java.util.Map<? extends java.lang.Short,? extends java.lang.Long> map,
ShortStrategy strategy)
A Helper constructor that allows to create a Map with exactly the same values as the provided map.
|
Short2LongLinkedOpenCustomHashMap(short[] keys,
long[] values,
float loadFactor,
ShortStrategy strategy)
Helper constructor that allow to create a map from unboxed values
|
Short2LongLinkedOpenCustomHashMap(java.lang.Short[] keys,
java.lang.Long[] values,
float loadFactor,
ShortStrategy strategy)
Helper constructor that allow to create a map from boxed values (it will unbox them)
|
Short2LongLinkedOpenCustomHashMap(short[] keys,
long[] values,
ShortStrategy strategy)
Helper constructor that allow to create a map from unboxed values
|
Short2LongLinkedOpenCustomHashMap(java.lang.Short[] keys,
java.lang.Long[] values,
ShortStrategy strategy)
Helper constructor that allow to create a map from boxed values (it will unbox them)
|
Short2LongLinkedOpenCustomHashMap(Short2LongMap map,
float loadFactor,
ShortStrategy strategy)
A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
|
Short2LongLinkedOpenCustomHashMap(Short2LongMap map,
ShortStrategy strategy)
A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
|
Short2LongLinkedOpenCustomHashMap(ShortStrategy strategy)
Default Constructor
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear() |
ShortComparator |
comparator() |
long |
firstLongValue()
A method to get the first Value of a Map.
|
short |
firstShortKey()
A method to get the first Key of a Map.
|
void |
forEach(ShortLongConsumer action)
Type Specific forEach method to reduce boxing/unboxing
|
long |
getAndMoveToFirst(short key)
A Specific get method that allows to move teh given key/value int the first index.
|
long |
getAndMoveToLast(short key)
A Specific get method that allows to move teh given key/value int the last index.
|
Short2LongSortedMap |
headMap(short toKey)
A Type Specific HeadMap method to reduce boxing/unboxing
|
ShortSet |
keySet() |
long |
lastLongValue()
A method to get the last Value of a Map.
|
short |
lastShortKey()
A method to get the last Key of a Map.
|
boolean |
moveToFirst(short key)
A specific move method to move a given key/value to the first index.
|
boolean |
moveToLast(short key)
A specific move method to move a given key/value to the last index.
|
short |
pollFirstShortKey()
A method to get and remove the first Key of a Map.
|
short |
pollLastShortKey()
A method to get and remove the last Key of a Map.
|
long |
putAndMoveToFirst(short key,
long value)
A customized put method that allows you to insert into the first index.
|
long |
putAndMoveToLast(short key,
long value)
A customized put method that allows you to insert into the last index.
|
ObjectSet<Short2LongMap.Entry> |
short2LongEntrySet()
Type Sensitive EntrySet to reduce boxing/unboxing and optionally Temp Object Allocation.
|
Short2LongSortedMap |
subMap(short fromKey,
short toKey)
A Type Specific SubMap method to reduce boxing/unboxing
|
Short2LongSortedMap |
tailMap(short fromKey)
A Type Specific TailMap method to reduce boxing/unboxing
|
LongCollection |
values() |
addTo, computeLong, computeLongIfAbsent, computeLongIfPresent, containsKey, containsKey, containsValue, containsValue, get, getLong, getOrDefault, mergeAllLong, mergeLong, put, putIfAbsent, remove, remove, remove, remShort, remShortOrDefault, replace, replace, sizeaddToAll, entrySet, equals, getDefaultReturnValue, getOrDefault, hashCode, putAll, putAll, putAll, putAllIfAbsent, replaceLongs, replaceLongs, setDefaultReturnValuefirstKey, headMap, lastKey, subMap, tailMapaddTo, addToAll, compute, computeIfAbsent, computeIfPresent, computeLong, computeLongIfAbsent, computeLongIfPresent, containsKey, containsKey, containsValue, containsValue, entrySet, forEach, get, getDefaultReturnValue, getLong, getOrDefault, getOrDefault, merge, mergeAllLong, mergeLong, put, put, putAll, putAll, putAll, putAllIfAbsent, putIfAbsent, putIfAbsent, remove, remove, remove, remShort, remShortOrDefault, replace, replace, replace, replace, replaceAll, replaceLongs, replaceLongs, setDefaultReturnValuepublic Short2LongLinkedOpenCustomHashMap(ShortStrategy strategy)
strategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic Short2LongLinkedOpenCustomHashMap(int minCapacity,
ShortStrategy strategy)
minCapacity - the minimum capacity the HashMap is allowed to be.strategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the minimum capacity is negativepublic Short2LongLinkedOpenCustomHashMap(int minCapacity,
float loadFactor,
ShortStrategy strategy)
minCapacity - the minimum capacity the HashMap is allowed to be.loadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the minimum capacity is negativejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public Short2LongLinkedOpenCustomHashMap(java.lang.Short[] keys,
java.lang.Long[] values,
ShortStrategy strategy)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.strategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the keys and values do not match in lenghtpublic Short2LongLinkedOpenCustomHashMap(java.lang.Short[] keys,
java.lang.Long[] values,
float loadFactor,
ShortStrategy strategy)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.loadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the keys and values do not match in lenghtjava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public Short2LongLinkedOpenCustomHashMap(short[] keys,
long[] values,
ShortStrategy strategy)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.strategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the keys and values do not match in lenghtpublic Short2LongLinkedOpenCustomHashMap(short[] keys,
long[] values,
float loadFactor,
ShortStrategy strategy)
keys - the keys that should be put into the mapvalues - the values that should be put into the map.loadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the keys and values do not match in lenghtjava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public Short2LongLinkedOpenCustomHashMap(java.util.Map<? extends java.lang.Short,? extends java.lang.Long> map,
ShortStrategy strategy)
map - the values that should be present in the mapstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic Short2LongLinkedOpenCustomHashMap(java.util.Map<? extends java.lang.Short,? extends java.lang.Long> map,
float loadFactor,
ShortStrategy strategy)
map - the values that should be present in the maploadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public Short2LongLinkedOpenCustomHashMap(Short2LongMap map, ShortStrategy strategy)
map - the values that should be present in the mapstrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nullpublic Short2LongLinkedOpenCustomHashMap(Short2LongMap map, float loadFactor, ShortStrategy strategy)
map - the values that should be present in the maploadFactor - the percentage of how full the backing array can be before they resizestrategy - the strategy that allows hash control.java.lang.NullPointerException - if Strategy is nulljava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public long putAndMoveToFirst(short key,
long value)
Short2LongSortedMapputAndMoveToFirst in interface Short2LongSortedMapkey - the key that should be insertedvalue - the value that should be insertedMap.put(Object, Object)public long putAndMoveToLast(short key,
long value)
Short2LongSortedMapputAndMoveToLast in interface Short2LongSortedMapkey - the key that should be insertedvalue - the value that should be insertedMap.put(Object, Object)public boolean moveToFirst(short key)
Short2LongSortedMapmoveToFirst in interface Short2LongSortedMapkey - that should be moved to the first indexpublic boolean moveToLast(short key)
Short2LongSortedMapmoveToLast in interface Short2LongSortedMapkey - that should be moved to the first lastpublic long getAndMoveToFirst(short key)
Short2LongSortedMapgetAndMoveToFirst in interface Short2LongSortedMapkey - that is searched forpublic long getAndMoveToLast(short key)
Short2LongSortedMapgetAndMoveToLast in interface Short2LongSortedMapkey - that is searched forpublic ShortComparator comparator()
comparator in interface java.util.SortedMap<java.lang.Short,java.lang.Long>comparator in interface Short2LongSortedMappublic Short2LongSortedMap subMap(short fromKey, short toKey)
Short2LongSortedMapsubMap in interface Short2LongSortedMapfromKey - where the submap should starttoKey - where the subMap should endpublic Short2LongSortedMap headMap(short toKey)
Short2LongSortedMapheadMap in interface Short2LongSortedMaptoKey - where the headMap should endpublic Short2LongSortedMap tailMap(short fromKey)
Short2LongSortedMaptailMap in interface Short2LongSortedMapfromKey - where the TailMap should startpublic short firstShortKey()
Short2LongSortedMapfirstShortKey in interface Short2LongSortedMappublic short pollFirstShortKey()
Short2LongSortedMappollFirstShortKey in interface Short2LongSortedMappublic short lastShortKey()
Short2LongSortedMaplastShortKey in interface Short2LongSortedMappublic short pollLastShortKey()
Short2LongSortedMappollLastShortKey in interface Short2LongSortedMappublic long firstLongValue()
Short2LongSortedMapfirstLongValue in interface Short2LongSortedMappublic long lastLongValue()
Short2LongSortedMaplastLongValue in interface Short2LongSortedMappublic ObjectSet<Short2LongMap.Entry> short2LongEntrySet()
Short2LongMapshort2LongEntrySet in interface Short2LongMapshort2LongEntrySet in class Short2LongOpenCustomHashMappublic ShortSet keySet()
keySet in interface java.util.Map<java.lang.Short,java.lang.Long>keySet in interface java.util.SortedMap<java.lang.Short,java.lang.Long>keySet in interface Short2LongMapkeySet in interface Short2LongSortedMapkeySet in class Short2LongOpenCustomHashMappublic LongCollection values()
values in interface java.util.Map<java.lang.Short,java.lang.Long>values in interface java.util.SortedMap<java.lang.Short,java.lang.Long>values in interface Short2LongMapvalues in interface Short2LongSortedMapvalues in class Short2LongOpenCustomHashMappublic void forEach(ShortLongConsumer action)
Short2LongMapforEach in interface Short2LongMapforEach in class Short2LongOpenCustomHashMapaction - processor of the values that are iterator overpublic void clear()
clear in interface java.util.Map<java.lang.Short,java.lang.Long>clear in class Short2LongOpenCustomHashMap