public abstract class AbstractBoolean2ShortMap extends java.util.AbstractMap<java.lang.Boolean,java.lang.Short> implements Boolean2ShortMap
| Modifier and Type | Class and Description |
|---|---|
static class |
AbstractBoolean2ShortMap.BasicEntry
A Simple Type Specific Entry class to reduce boxing/unboxing
|
java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Boolean2ShortMap.Entry, Boolean2ShortMap.FastEntrySet| Constructor and Description |
|---|
AbstractBoolean2ShortMap() |
| Modifier and Type | Method and Description |
|---|---|
void |
addToAll(Boolean2ShortMap m)
A Helper method to bulk add primitives together.
|
short |
computeShort(boolean key,
BooleanShortUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
short |
computeShortIfAbsent(boolean key,
Boolean2ShortFunction mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
short |
computeShortIfPresent(boolean key,
BooleanShortUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
boolean |
containsKey(boolean key)
Type Specific method to reduce boxing/unboxing of values
|
boolean |
containsValue(short value)
Type Specific method to reduce boxing/unboxing of values
|
Boolean2ShortMap |
copy()
A Function that does a shallow clone of the Map itself.
|
ObjectSet<java.util.Map.Entry<java.lang.Boolean,java.lang.Short>> |
entrySet() |
boolean |
equals(java.lang.Object o) |
void |
forEach(BooleanShortConsumer action)
Type Specific forEach method to reduce boxing/unboxing
|
java.lang.Short |
get(java.lang.Object key) |
short |
getDefaultReturnValue()
Method to see what the default return value is.
|
short |
getOrDefault(boolean key,
short defaultValue)
A Type Specific getOrDefault method to reduce boxing/unboxing
|
java.lang.Short |
getOrDefault(java.lang.Object key,
java.lang.Short defaultValue) |
int |
hashCode() |
BooleanSet |
keySet() |
void |
mergeAllShort(Boolean2ShortMap m,
ShortShortUnaryOperator mappingFunction)
A Bulk method for merging Maps.
|
short |
mergeShort(boolean key,
short value,
ShortShortUnaryOperator mappingFunction)
A Type Specific merge method to reduce boxing/unboxing
|
java.lang.Short |
put(java.lang.Boolean key,
java.lang.Short value)
Deprecated.
|
void |
putAll(boolean[] keys,
short[] values,
int offset,
int size)
Type Specific array method to bulk add elements into a map without creating a wrapper and increasing performances
|
void |
putAll(java.lang.Boolean[] keys,
java.lang.Short[] values,
int offset,
int size)
Type Specific Object array method to bulk add elements into a map without creating a wrapper and increasing performances
|
void |
putAll(Boolean2ShortMap m)
Type Specific function for the bull putting of values
|
void |
putAll(java.util.Map<? extends java.lang.Boolean,? extends java.lang.Short> m) |
void |
putAllIfAbsent(Boolean2ShortMap m)
Type-Specific bulk put method put elements into the map if not present.
|
java.lang.Short |
remove(java.lang.Object key) |
short |
replace(boolean key,
short value)
A Type Specific replace method to reduce boxing/unboxing replace an existing value
|
boolean |
replace(boolean key,
short oldValue,
short newValue)
A Type Specific replace method to replace an existing value
|
void |
replaceShorts(Boolean2ShortMap m)
Type-Specific bulk replace method.
|
void |
replaceShorts(BooleanShortUnaryOperator mappingFunction)
A Type Specific mass replace method to reduce boxing/unboxing
|
AbstractBoolean2ShortMap |
setDefaultReturnValue(short v)
Method to define the default return value if a requested key isn't present
|
short |
supplyShortIfAbsent(boolean key,
ShortSupplier valueProvider)
A Supplier based computeIfAbsent function to fill the most used usecase of this function
|
ShortCollection |
values() |
clear, containsKey, containsValue, isEmpty, size, toStringaddTo, boolean2ShortEntrySet, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, forEach, get, merge, put, putAll, putAll, putIfAbsent, putIfAbsent, remove, remove, remove, removeOrDefault, replace, replace, replaceAll, subFrompublic short getDefaultReturnValue()
Boolean2ShortMapgetDefaultReturnValue in interface Boolean2ShortMappublic AbstractBoolean2ShortMap setDefaultReturnValue(short v)
Boolean2ShortMapsetDefaultReturnValue in interface Boolean2ShortMapv - value that should be the default return valuepublic Boolean2ShortMap copy()
Boolean2ShortMapcopy in interface Boolean2ShortMap@Deprecated
public java.lang.Short put(java.lang.Boolean key,
java.lang.Short value)
put in interface java.util.Map<java.lang.Boolean,java.lang.Short>put in interface Boolean2ShortMapput in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>public void addToAll(Boolean2ShortMap m)
Boolean2ShortMapaddToAll in interface Boolean2ShortMapm - the values that should be added/insertedpublic void putAll(Boolean2ShortMap m)
Boolean2ShortMapputAll in interface Boolean2ShortMapm - the elements that should be insertedpublic void putAll(java.util.Map<? extends java.lang.Boolean,? extends java.lang.Short> m)
putAll in interface java.util.Map<java.lang.Boolean,java.lang.Short>putAll in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>public void putAll(boolean[] keys,
short[] values,
int offset,
int size)
Boolean2ShortMapputAll in interface Boolean2ShortMapkeys - the keys that should be addedvalues - the values that should be addedoffset - where the to start in the arraysize - how many elements should be addedMap.putAll(Map)public void putAll(java.lang.Boolean[] keys,
java.lang.Short[] values,
int offset,
int size)
Boolean2ShortMapputAll in interface Boolean2ShortMapkeys - the keys that should be addedvalues - the values that should be addedoffset - where the to start in the arraysize - how many elements should be addedMap.putAll(Map)public void putAllIfAbsent(Boolean2ShortMap m)
Boolean2ShortMapputAllIfAbsent in interface Boolean2ShortMapm - elements that should be added if not present.public boolean containsKey(boolean key)
Boolean2ShortMapcontainsKey in interface Boolean2ShortMapkey - element that is searched forpublic boolean containsValue(short value)
Boolean2ShortMapcontainsValue in interface Boolean2ShortMapvalue - element that is searched forpublic boolean replace(boolean key,
short oldValue,
short newValue)
Boolean2ShortMapreplace in interface Boolean2ShortMapkey - the element that should be searched foroldValue - the expected value to be replacednewValue - the value to replace the oldValue with.public short replace(boolean key,
short value)
Boolean2ShortMapreplace in interface Boolean2ShortMapkey - the element that should be searched forvalue - the value to replace with.public void replaceShorts(Boolean2ShortMap m)
Boolean2ShortMapreplaceShorts in interface Boolean2ShortMapm - elements that should be replaced.public void replaceShorts(BooleanShortUnaryOperator mappingFunction)
Boolean2ShortMapreplaceShorts in interface Boolean2ShortMapmappingFunction - operation to replace all valuespublic short computeShort(boolean key,
BooleanShortUnaryOperator mappingFunction)
Boolean2ShortMapcomputeShort in interface Boolean2ShortMapkey - the key that should be computedmappingFunction - the operator that should generate the valuepublic short computeShortIfAbsent(boolean key,
Boolean2ShortFunction mappingFunction)
Boolean2ShortMapcomputeShortIfAbsent in interface Boolean2ShortMapkey - the key that should be computedmappingFunction - the operator that should generate the value if not presentpublic short supplyShortIfAbsent(boolean key,
ShortSupplier valueProvider)
Boolean2ShortMapsupplyShortIfAbsent in interface Boolean2ShortMapkey - the key that should be computedvalueProvider - the value if not presentpublic short computeShortIfPresent(boolean key,
BooleanShortUnaryOperator mappingFunction)
Boolean2ShortMapcomputeShortIfPresent in interface Boolean2ShortMapkey - the key that should be computedmappingFunction - the operator that should generate the value if presentpublic short mergeShort(boolean key,
short value,
ShortShortUnaryOperator mappingFunction)
Boolean2ShortMapmergeShort in interface Boolean2ShortMapkey - the key that should be be searched forvalue - the value that should be merged withmappingFunction - the operator that should generate the new Valuepublic void mergeAllShort(Boolean2ShortMap m, ShortShortUnaryOperator mappingFunction)
Boolean2ShortMapmergeAllShort in interface Boolean2ShortMapm - the entries that should be bulk addedmappingFunction - the operator that should generate the new Valuepublic java.lang.Short get(java.lang.Object key)
get in interface java.util.Map<java.lang.Boolean,java.lang.Short>get in interface Boolean2ShortMapget in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>public java.lang.Short getOrDefault(java.lang.Object key,
java.lang.Short defaultValue)
getOrDefault in interface java.util.Map<java.lang.Boolean,java.lang.Short>getOrDefault in interface Boolean2ShortMappublic short getOrDefault(boolean key,
short defaultValue)
Boolean2ShortMapgetOrDefault in interface Boolean2ShortMapkey - the key that is searched fordefaultValue - the value that should be returned if the key is not presentpublic java.lang.Short remove(java.lang.Object key)
remove in interface java.util.Map<java.lang.Boolean,java.lang.Short>remove in interface Boolean2ShortMapremove in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>key - the element that should be removedMap.remove(Object)public void forEach(BooleanShortConsumer action)
Boolean2ShortMapforEach in interface Boolean2ShortMapaction - processor of the values that are iterator overpublic BooleanSet keySet()
keySet in interface java.util.Map<java.lang.Boolean,java.lang.Short>keySet in interface Boolean2ShortMapkeySet in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>public ShortCollection values()
values in interface java.util.Map<java.lang.Boolean,java.lang.Short>values in interface Boolean2ShortMapvalues in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>public ObjectSet<java.util.Map.Entry<java.lang.Boolean,java.lang.Short>> entrySet()
entrySet in interface java.util.Map<java.lang.Boolean,java.lang.Short>entrySet in interface Boolean2ShortMapentrySet in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>public boolean equals(java.lang.Object o)
equals in interface java.util.Map<java.lang.Boolean,java.lang.Short>equals in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>public int hashCode()
hashCode in interface java.util.Map<java.lang.Boolean,java.lang.Short>hashCode in class java.util.AbstractMap<java.lang.Boolean,java.lang.Short>