V - the type of elements maintained by this Collectionpublic class Long2ObjectLinkedOpenHashMap<V> extends Long2ObjectOpenHashMap<V> implements Long2ObjectSortedMap<V>
AbstractLong2ObjectMap.BasicEntry<V>java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Long2ObjectSortedMap.FastSortedSet<V>Long2ObjectMap.Entry<V>, Long2ObjectMap.FastEntrySet<V>| Constructor and Description |
|---|
Long2ObjectLinkedOpenHashMap()
Default Constructor
|
Long2ObjectLinkedOpenHashMap(int minCapacity)
Constructor that defines the minimum capacity
|
Long2ObjectLinkedOpenHashMap(int minCapacity,
float loadFactor)
Constructor that defines the minimum capacity and load factor
|
Long2ObjectLinkedOpenHashMap(long[] keys,
V[] values)
Helper constructor that allow to create a map from unboxed values
|
Long2ObjectLinkedOpenHashMap(java.lang.Long[] keys,
V[] values)
Helper constructor that allow to create a map from boxed values (it will unbox them)
|
Long2ObjectLinkedOpenHashMap(long[] keys,
V[] values,
float loadFactor)
Helper constructor that allow to create a map from unboxed values
|
Long2ObjectLinkedOpenHashMap(java.lang.Long[] keys,
V[] values,
float loadFactor)
Helper constructor that allow to create a map from boxed values (it will unbox them)
|
Long2ObjectLinkedOpenHashMap(Long2ObjectMap<V> map)
A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
|
Long2ObjectLinkedOpenHashMap(Long2ObjectMap<V> map,
float loadFactor)
A Type Specific Helper function that allows to create a new Map with exactly the same values as the provided map.
|
Long2ObjectLinkedOpenHashMap(java.util.Map<? extends java.lang.Long,? extends V> map)
A Helper constructor that allows to create a Map with exactly the same values as the provided map.
|
Long2ObjectLinkedOpenHashMap(java.util.Map<? extends java.lang.Long,? extends V> map,
float loadFactor)
A Helper constructor that allows to create a Map with exactly the same values as the provided map.
|
| Modifier and Type | Method and Description |
|---|---|
void |
clear() |
LongComparator |
comparator() |
long |
firstLongKey()
A method to get the first Key of a Map.
|
V |
firstValue()
A method to get the first Value of a Map.
|
void |
forEach(LongObjectConsumer<V> action)
Type Specific forEach method to reduce boxing/unboxing
|
V |
getAndMoveToFirst(long key)
A Specific get method that allows to move teh given key/value int the first index.
|
V |
getAndMoveToLast(long key)
A Specific get method that allows to move teh given key/value int the last index.
|
Long2ObjectSortedMap<V> |
headMap(long toKey)
A Type Specific HeadMap method to reduce boxing/unboxing
|
LongSet |
keySet() |
long |
lastLongKey()
A method to get the last Key of a Map.
|
V |
lastValue()
A method to get the last Value of a Map.
|
ObjectSet<Long2ObjectMap.Entry<V>> |
long2ObjectEntrySet()
Type Sensitive EntrySet to reduce boxing/unboxing and optionally Temp Object Allocation.
|
boolean |
moveToFirst(long key)
A specific move method to move a given key/value to the first index.
|
boolean |
moveToLast(long key)
A specific move method to move a given key/value to the last index.
|
long |
pollFirstLongKey()
A method to get and remove the first Key of a Map.
|
long |
pollLastLongKey()
A method to get and remove the last Key of a Map.
|
V |
putAndMoveToFirst(long key,
V value)
A customized put method that allows you to insert into the first index.
|
V |
putAndMoveToLast(long key,
V value)
A customized put method that allows you to insert into the last index.
|
Long2ObjectSortedMap<V> |
subMap(long fromKey,
long toKey)
A Type Specific SubMap method to reduce boxing/unboxing
|
Long2ObjectSortedMap<V> |
tailMap(long fromKey)
A Type Specific TailMap method to reduce boxing/unboxing
|
ObjectCollection<V> |
values() |
compute, computeIfAbsent, computeIfPresent, containsKey, containsKey, containsValue, get, getObject, getOrDefault, merge, mergeAll, put, putIfAbsent, remLong, remLongOrDefault, remove, remove, remove, replace, replace, sizeentrySet, equals, getDefaultReturnValue, getOrDefault, hashCode, putAll, putAll, putAll, putAllIfAbsent, replaceObjects, replaceObjects, setDefaultReturnValuefirstKey, headMap, lastKey, subMap, tailMapcompute, compute, computeIfAbsent, computeIfAbsent, computeIfPresent, computeIfPresent, containsKey, containsKey, entrySet, forEach, get, getDefaultReturnValue, getObject, getOrDefault, getOrDefault, merge, merge, mergeAll, put, put, putAll, putAll, putAll, putAllIfAbsent, putIfAbsent, putIfAbsent, remLong, remLongOrDefault, remove, remove, remove, replace, replace, replace, replace, replaceAll, replaceObjects, replaceObjects, setDefaultReturnValuecontainsValue, equals, hashCode, isEmpty, putAll, sizeapplypublic Long2ObjectLinkedOpenHashMap()
public Long2ObjectLinkedOpenHashMap(int minCapacity)
minCapacity - the minimum capacity the HashMap is allowed to be.java.lang.IllegalStateException - if the minimum capacity is negativepublic Long2ObjectLinkedOpenHashMap(int minCapacity,
float loadFactor)
minCapacity - the minimum capacity the HashMap is allowed to be.loadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the minimum capacity is negativejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public Long2ObjectLinkedOpenHashMap(java.lang.Long[] keys,
V[] 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 Long2ObjectLinkedOpenHashMap(java.lang.Long[] keys,
V[] values,
float loadFactor)
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 resizejava.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 Long2ObjectLinkedOpenHashMap(long[] keys,
V[] 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 Long2ObjectLinkedOpenHashMap(long[] keys,
V[] values,
float loadFactor)
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 resizejava.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 Long2ObjectLinkedOpenHashMap(java.util.Map<? extends java.lang.Long,? extends V> map)
map - the values that should be present in the mappublic Long2ObjectLinkedOpenHashMap(java.util.Map<? extends java.lang.Long,? extends V> map, float loadFactor)
map - the values that should be present in the maploadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public Long2ObjectLinkedOpenHashMap(Long2ObjectMap<V> map)
map - the values that should be present in the mappublic Long2ObjectLinkedOpenHashMap(Long2ObjectMap<V> map, float loadFactor)
map - the values that should be present in the maploadFactor - the percentage of how full the backing array can be before they resizejava.lang.IllegalStateException - if the loadfactor is either below/equal to 0 or above/equal to 1public V putAndMoveToFirst(long key, V value)
Long2ObjectSortedMapputAndMoveToFirst in interface Long2ObjectSortedMap<V>key - the key that should be insertedvalue - the value that should be insertedMap.put(Object, Object)public V putAndMoveToLast(long key, V value)
Long2ObjectSortedMapputAndMoveToLast in interface Long2ObjectSortedMap<V>key - the key that should be insertedvalue - the value that should be insertedMap.put(Object, Object)public boolean moveToFirst(long key)
Long2ObjectSortedMapmoveToFirst in interface Long2ObjectSortedMap<V>key - that should be moved to the first indexpublic boolean moveToLast(long key)
Long2ObjectSortedMapmoveToLast in interface Long2ObjectSortedMap<V>key - that should be moved to the first lastpublic V getAndMoveToFirst(long key)
Long2ObjectSortedMapgetAndMoveToFirst in interface Long2ObjectSortedMap<V>key - that is searched forpublic V getAndMoveToLast(long key)
Long2ObjectSortedMapgetAndMoveToLast in interface Long2ObjectSortedMap<V>key - that is searched forpublic LongComparator comparator()
comparator in interface java.util.SortedMap<java.lang.Long,V>comparator in interface Long2ObjectSortedMap<V>public Long2ObjectSortedMap<V> subMap(long fromKey, long toKey)
Long2ObjectSortedMapsubMap in interface Long2ObjectSortedMap<V>fromKey - where the submap should starttoKey - where the subMap should endpublic Long2ObjectSortedMap<V> headMap(long toKey)
Long2ObjectSortedMapheadMap in interface Long2ObjectSortedMap<V>toKey - where the headMap should endpublic Long2ObjectSortedMap<V> tailMap(long fromKey)
Long2ObjectSortedMaptailMap in interface Long2ObjectSortedMap<V>fromKey - where the TailMap should startpublic long firstLongKey()
Long2ObjectSortedMapfirstLongKey in interface Long2ObjectSortedMap<V>public long pollFirstLongKey()
Long2ObjectSortedMappollFirstLongKey in interface Long2ObjectSortedMap<V>public long lastLongKey()
Long2ObjectSortedMaplastLongKey in interface Long2ObjectSortedMap<V>public long pollLastLongKey()
Long2ObjectSortedMappollLastLongKey in interface Long2ObjectSortedMap<V>public V firstValue()
Long2ObjectSortedMapfirstValue in interface Long2ObjectSortedMap<V>public V lastValue()
Long2ObjectSortedMaplastValue in interface Long2ObjectSortedMap<V>public ObjectSet<Long2ObjectMap.Entry<V>> long2ObjectEntrySet()
Long2ObjectMaplong2ObjectEntrySet in interface Long2ObjectMap<V>long2ObjectEntrySet in class Long2ObjectOpenHashMap<V>public LongSet keySet()
keySet in interface java.util.Map<java.lang.Long,V>keySet in interface java.util.SortedMap<java.lang.Long,V>keySet in interface Long2ObjectMap<V>keySet in interface Long2ObjectSortedMap<V>keySet in class Long2ObjectOpenHashMap<V>public ObjectCollection<V> values()
values in interface java.util.Map<java.lang.Long,V>values in interface java.util.SortedMap<java.lang.Long,V>values in interface Long2ObjectMap<V>values in interface Long2ObjectSortedMap<V>values in class Long2ObjectOpenHashMap<V>public void forEach(LongObjectConsumer<V> action)
Long2ObjectMapforEach in interface Long2ObjectMap<V>forEach in class Long2ObjectOpenHashMap<V>action - processor of the values that are iterator overpublic void clear()
clear in interface java.util.Map<java.lang.Long,V>clear in class Long2ObjectOpenHashMap<V>