public interface KeyValueState<K,V> extends State, java.lang.Iterable<java.util.Map.Entry<K,V>>
Modifier and Type | Method and Description |
---|---|
V |
delete(K key)
Deletes the value mapped to the key, if there is any
|
V |
get(K key)
Returns the value mapped to the key
|
V |
get(K key,
V defaultValue)
Returns the value mapped to the key or defaultValue if no mapping is found.
|
void |
put(K key,
V value)
Maps the value with the key
|
commit, commit, prepareCommit, rollback
void put(K key, V value)
key
- the keyvalue
- the valueV get(K key)
key
- the keyV get(K key, V defaultValue)
key
- the keydefaultValue
- the value to return if no mapping is found