K
- Type of region keys.V
- Type of region values.@Experimental public interface Region<K,V>
JSONWrapper
Modifier and Type | Method and Description |
---|---|
void |
clear()
Removes all keys and values associated from this region.
|
V |
get(K key)
Gets the value, if any, contained in this region for the
key . |
java.util.Map<K,V> |
getAll(java.util.Collection<K> keys)
Gets the values, if any, contained in this region for the collection of
keys . |
java.util.Set<K> |
keySet()
Gets all the keys for which this region has entries
|
void |
put(K key,
V value)
Puts the
value into this region for the key . |
void |
putAll(java.util.Map<K,V> values)
Puts the map from keys to
values into this region. |
V |
putIfAbsent(K key,
V value)
Puts the
value into this region for the key if key does
not already have a value associated with it. |
void |
remove(K key)
Removes any value associated with the
key from this region. |
int |
size()
Gets the number of entries in this region.
|
int size() throws java.io.IOException
java.io.IOException
V get(K key) throws java.io.IOException
key
.key
- Unique key associated with a value.key
.java.io.IOException
java.util.Map<K,V> getAll(java.util.Collection<K> keys) throws java.io.IOException
keys
.keys
- Collection of unique keys associated with values.keys
to their associated values.java.io.IOException
void put(K key, V value) throws java.io.IOException
value
into this region for the key
.key
- Unique key to associate with the value
.value
- Value to associate with the key
.java.io.IOException
void putAll(java.util.Map<K,V> values) throws java.io.IOException
values
into this region. If any one key/value pair can
not be inserted, the remaining pair insertions will be attempted.values
- Map from keys
to their associated values.java.io.IOException
void clear() throws java.io.IOException
java.io.IOException
V putIfAbsent(K key, V value) throws java.io.IOException
value
into this region for the key
if key
does
not already have a value associated with it.java.io.IOException
void remove(K key) throws java.io.IOException
key
from this region.key
- Unique key associated with a value.java.io.IOException
java.util.Set<K> keySet() throws java.io.IOException
java.io.IOException