public static class Short2LongMaps.SingletonMap extends AbstractShort2LongMap
AbstractShort2LongMap.BasicEntryjava.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Short2LongMap.Entry, Short2LongMap.FastEntrySet| Modifier and Type | Method and Description |
|---|---|
long |
addTo(short key,
long value)
A Helper method to add a primitives together.
|
long |
getLong(short key)
A Type Specific get method to reduce boxing/unboxing
|
long |
getOrDefault(short key,
long defaultValue)
A Type Specific getOrDefault method to reduce boxing/unboxing
|
ShortSet |
keySet() |
long |
put(short key,
long value)
Type Specific method to reduce boxing/unboxing of values
|
long |
putIfAbsent(short key,
long value)
Type Specific method to reduce boxing/unboxing of values
|
boolean |
remove(short key,
long value)
Type Specific remove function to reduce boxing/unboxing
|
long |
remShort(short key)
Type Specific remove function to reduce boxing/unboxing
|
long |
remShortOrDefault(short key,
long defaultValue)
Type-Specific Remove function with a default return value if wanted.
|
ObjectSet<Short2LongMap.Entry> |
short2LongEntrySet()
Type Sensitive EntrySet to reduce boxing/unboxing and optionally Temp Object Allocation.
|
LongCollection |
values() |
addToAll, computeLong, computeLongIfAbsent, computeLongIfPresent, containsKey, containsValue, entrySet, equals, forEach, get, getDefaultReturnValue, getOrDefault, hashCode, mergeAllLong, mergeLong, putAll, putAll, putAll, putAllIfAbsent, replace, replace, replaceLongs, replaceLongs, setDefaultReturnValueclear, containsKey, containsValue, isEmpty, put, remove, size, toStringcompute, computeIfAbsent, computeIfPresent, containsKey, containsValue, forEach, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAllpublic long put(short key,
long value)
Short2LongMapkey - the key that should be inserted,value - the value that should be insertedMap.put(Object, Object)public long putIfAbsent(short key,
long value)
Short2LongMapkey - the key that should be inserted,value - the value that should be insertedMap.putIfAbsent(Object, Object)public long addTo(short key,
long value)
Short2LongMapkey - the key that should be inserted,value - the value that should be inserted / addedpublic long remShort(short key)
Short2LongMapkey - the element that should be removedpublic long remShortOrDefault(short key,
long defaultValue)
Short2LongMapkey - the element that should be removeddefaultValue - the value that should be returned if the entry doesn't existMap.remove(Object, Object)public boolean remove(short key,
long value)
Short2LongMapkey - the element that should be removedvalue - the expected value that should be foundMap.remove(Object, Object)public long getLong(short key)
Short2LongMapkey - the key that is searched forpublic long getOrDefault(short key,
long defaultValue)
Short2LongMapgetOrDefault in interface Short2LongMapgetOrDefault in class AbstractShort2LongMapkey - the key that is searched fordefaultValue - the value that should be returned if the key is not presentpublic ShortSet keySet()
keySet in interface java.util.Map<java.lang.Short,java.lang.Long>keySet in interface Short2LongMapkeySet in class AbstractShort2LongMappublic LongCollection values()
values in interface java.util.Map<java.lang.Short,java.lang.Long>values in interface Short2LongMapvalues in class AbstractShort2LongMappublic ObjectSet<Short2LongMap.Entry> short2LongEntrySet()
Short2LongMap