public MapExtra<K,V>
Extra methods for Map interface
Modifier and Type | Method and Description |
---|---|
void |
forEach(java.util.function.BiConsumer<? super K,? super V> action) |
void |
forEachKey(Function1<? super K,Unit> procedure) |
void |
forEachValue(Function1<? super V,Unit> procedure) |
Serializer<K> |
getKeySerializer() |
Serializer<V> |
getValueSerializer() |
boolean |
isClosed() |
boolean |
putIfAbsentBoolean(K key,
V value)
Atomically associates the specified key with the given value if it is
not already associated with a value.
|
long |
sizeLong()
map size as long number
|
long sizeLong()
map size as long number
boolean putIfAbsentBoolean(K key, V value)
Atomically associates the specified key with the given value if it is not already associated with a value.
This is equivalent to:
if(cache.containsKey(key)){}cache.put(key,value);return true;}else{return false;}
*
except that the action is performed atomically.
boolean isClosed()
void forEachKey(Function1<? super K,Unit> procedure)
void forEachValue(Function1<? super V,Unit> procedure)
void forEach(java.util.function.BiConsumer<? super K,? super V> action)
Serializer<K> getKeySerializer()
Serializer<V> getValueSerializer()