public abstract class AbstractLong2BooleanMap extends java.util.AbstractMap<java.lang.Long,java.lang.Boolean> implements Long2BooleanMap
| Modifier and Type | Class and Description |
|---|---|
static class |
AbstractLong2BooleanMap.BasicEntry
A Simple Type Specific Entry class to reduce boxing/unboxing
|
java.util.AbstractMap.SimpleEntry<K,V>, java.util.AbstractMap.SimpleImmutableEntry<K,V>Long2BooleanMap.BuilderCache, Long2BooleanMap.Entry, Long2BooleanMap.FastEntrySet, Long2BooleanMap.MapBuilder| Constructor and Description |
|---|
AbstractLong2BooleanMap() |
| Modifier and Type | Method and Description |
|---|---|
boolean |
computeBoolean(long key,
LongBooleanUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
boolean |
computeBooleanIfAbsent(long key,
java.util.function.LongPredicate mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
boolean |
computeBooleanIfPresent(long key,
LongBooleanUnaryOperator mappingFunction)
A Type Specific compute method to reduce boxing/unboxing
|
boolean |
containsKey(long key)
Type Specific method to reduce boxing/unboxing of values
|
boolean |
containsValue(boolean value)
Type Specific method to reduce boxing/unboxing of values
|
Long2BooleanMap |
copy()
A Function that does a shallow clone of the Map itself.
|
ObjectSet<java.util.Map.Entry<java.lang.Long,java.lang.Boolean>> |
entrySet() |
boolean |
equals(java.lang.Object o) |
void |
forEach(LongBooleanConsumer action)
Type Specific forEach method to reduce boxing/unboxing
|
java.lang.Boolean |
get(java.lang.Object key) |
boolean |
getDefaultReturnValue()
Method to see what the default return value is.
|
boolean |
getOrDefault(long key,
boolean defaultValue)
A Type Specific getOrDefault method to reduce boxing/unboxing
|
java.lang.Boolean |
getOrDefault(java.lang.Object key,
java.lang.Boolean defaultValue) |
int |
hashCode() |
LongSet |
keySet() |
void |
mergeAllBoolean(Long2BooleanMap m,
BooleanBooleanUnaryOperator mappingFunction)
A Bulk method for merging Maps.
|
boolean |
mergeBoolean(long key,
boolean value,
BooleanBooleanUnaryOperator mappingFunction)
A Type Specific merge method to reduce boxing/unboxing
|
java.lang.Boolean |
put(java.lang.Long key,
java.lang.Boolean value)
Deprecated.
|
void |
putAll(long[] keys,
boolean[] 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.Long[] keys,
java.lang.Boolean[] 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(Long2BooleanMap m)
Type Specific function for the bull putting of values
|
void |
putAll(java.util.Map<? extends java.lang.Long,? extends java.lang.Boolean> m) |
void |
putAllIfAbsent(Long2BooleanMap m)
Type-Specific bulk put method put elements into the map if not present.
|
java.lang.Boolean |
remove(java.lang.Object key) |
boolean |
replace(long key,
boolean value)
A Type Specific replace method to reduce boxing/unboxing replace an existing value
|
boolean |
replace(long key,
boolean oldValue,
boolean newValue)
A Type Specific replace method to replace an existing value
|
void |
replaceBooleans(Long2BooleanMap m)
Type-Specific bulk replace method.
|
void |
replaceBooleans(LongBooleanUnaryOperator mappingFunction)
A Type Specific mass replace method to reduce boxing/unboxing
|
AbstractLong2BooleanMap |
setDefaultReturnValue(boolean v)
Method to define the default return value if a requested key isn't present
|
boolean |
supplyBooleanIfAbsent(long key,
BooleanSupplier valueProvider)
A Supplier based computeIfAbsent function to fill the most used usecase of this function
|
BooleanCollection |
values() |
clear, containsKey, containsValue, isEmpty, size, toStringbuilder, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, forEach, get, long2BooleanEntrySet, merge, put, put, put, putAll, putAll, putIfAbsent, putIfAbsent, remove, remove, remove, removeOrDefault, replace, replace, replaceAll, synchronize, synchronize, test, unmodifiablepublic boolean getDefaultReturnValue()
Long2BooleanMapgetDefaultReturnValue in interface Long2BooleanMappublic AbstractLong2BooleanMap setDefaultReturnValue(boolean v)
Long2BooleanMapsetDefaultReturnValue in interface Long2BooleanMapv - value that should be the default return valuepublic Long2BooleanMap copy()
Long2BooleanMapcopy in interface Long2BooleanMap@Deprecated
public java.lang.Boolean put(java.lang.Long key,
java.lang.Boolean value)
put in interface java.util.Map<java.lang.Long,java.lang.Boolean>put in interface Long2BooleanMapput in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>public void putAll(Long2BooleanMap m)
Long2BooleanMapputAll in interface Long2BooleanMapm - the elements that should be insertedpublic void putAll(java.util.Map<? extends java.lang.Long,? extends java.lang.Boolean> m)
putAll in interface java.util.Map<java.lang.Long,java.lang.Boolean>putAll in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>public void putAll(long[] keys,
boolean[] values,
int offset,
int size)
Long2BooleanMapputAll in interface Long2BooleanMapkeys - 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.Long[] keys,
java.lang.Boolean[] values,
int offset,
int size)
Long2BooleanMapputAll in interface Long2BooleanMapkeys - 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(Long2BooleanMap m)
Long2BooleanMapputAllIfAbsent in interface Long2BooleanMapm - elements that should be added if not present.public boolean containsKey(long key)
Long2BooleanMapcontainsKey in interface Long2BooleanMapkey - element that is searched forpublic boolean containsValue(boolean value)
Long2BooleanMapcontainsValue in interface Long2BooleanMapvalue - element that is searched forpublic boolean replace(long key,
boolean oldValue,
boolean newValue)
Long2BooleanMapreplace in interface Long2BooleanMapkey - the element that should be searched foroldValue - the expected value to be replacednewValue - the value to replace the oldValue with.public boolean replace(long key,
boolean value)
Long2BooleanMapreplace in interface Long2BooleanMapkey - the element that should be searched forvalue - the value to replace with.public void replaceBooleans(Long2BooleanMap m)
Long2BooleanMapreplaceBooleans in interface Long2BooleanMapm - elements that should be replaced.public void replaceBooleans(LongBooleanUnaryOperator mappingFunction)
Long2BooleanMapreplaceBooleans in interface Long2BooleanMapmappingFunction - operation to replace all valuespublic boolean computeBoolean(long key,
LongBooleanUnaryOperator mappingFunction)
Long2BooleanMapcomputeBoolean in interface Long2BooleanMapkey - the key that should be computedmappingFunction - the operator that should generate the valuepublic boolean computeBooleanIfAbsent(long key,
java.util.function.LongPredicate mappingFunction)
Long2BooleanMapcomputeBooleanIfAbsent in interface Long2BooleanMapkey - the key that should be computedmappingFunction - the operator that should generate the value if not presentpublic boolean supplyBooleanIfAbsent(long key,
BooleanSupplier valueProvider)
Long2BooleanMapsupplyBooleanIfAbsent in interface Long2BooleanMapkey - the key that should be computedvalueProvider - the value if not presentpublic boolean computeBooleanIfPresent(long key,
LongBooleanUnaryOperator mappingFunction)
Long2BooleanMapcomputeBooleanIfPresent in interface Long2BooleanMapkey - the key that should be computedmappingFunction - the operator that should generate the value if presentpublic boolean mergeBoolean(long key,
boolean value,
BooleanBooleanUnaryOperator mappingFunction)
Long2BooleanMapmergeBoolean in interface Long2BooleanMapkey - the key that should be be searched forvalue - the value that should be merged withmappingFunction - the operator that should generate the new Valuepublic void mergeAllBoolean(Long2BooleanMap m, BooleanBooleanUnaryOperator mappingFunction)
Long2BooleanMapmergeAllBoolean in interface Long2BooleanMapm - the entries that should be bulk addedmappingFunction - the operator that should generate the new Valuepublic java.lang.Boolean get(java.lang.Object key)
get in interface java.util.Map<java.lang.Long,java.lang.Boolean>get in interface Long2BooleanMapget in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>public java.lang.Boolean getOrDefault(java.lang.Object key,
java.lang.Boolean defaultValue)
getOrDefault in interface java.util.Map<java.lang.Long,java.lang.Boolean>getOrDefault in interface Long2BooleanMappublic boolean getOrDefault(long key,
boolean defaultValue)
Long2BooleanMapgetOrDefault in interface Long2BooleanMapkey - the key that is searched fordefaultValue - the value that should be returned if the key is not presentpublic java.lang.Boolean remove(java.lang.Object key)
remove in interface java.util.Map<java.lang.Long,java.lang.Boolean>remove in interface Long2BooleanMapremove in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>key - the element that should be removedMap.remove(Object)public void forEach(LongBooleanConsumer action)
Long2BooleanMapforEach in interface Long2BooleanMapaction - processor of the values that are iterator overpublic LongSet keySet()
keySet in interface java.util.Map<java.lang.Long,java.lang.Boolean>keySet in interface Long2BooleanMapkeySet in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>public BooleanCollection values()
values in interface java.util.Map<java.lang.Long,java.lang.Boolean>values in interface Long2BooleanMapvalues in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>public ObjectSet<java.util.Map.Entry<java.lang.Long,java.lang.Boolean>> entrySet()
entrySet in interface java.util.Map<java.lang.Long,java.lang.Boolean>entrySet in interface Long2BooleanMapentrySet in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>public boolean equals(java.lang.Object o)
equals in interface java.util.Map<java.lang.Long,java.lang.Boolean>equals in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>public int hashCode()
hashCode in interface java.util.Map<java.lang.Long,java.lang.Boolean>hashCode in class java.util.AbstractMap<java.lang.Long,java.lang.Boolean>