public class MemoryKeyMapStore<K,S,T> extends Object implements KeyMapStore<K,S,T>
| Constructor and Description |
|---|
MemoryKeyMapStore() |
| Modifier and Type | Method and Description |
|---|---|
void |
clearCache()
clear all cache.
|
void |
close()
close the store.
|
void |
flush()
flush to disk.
|
Map<S,T> |
get(K key)
get value from store.
|
T |
get(K key,
S subKey)
get subValue from store.
|
void |
put(K key,
Map<S,T> value)
put key value into store.
|
void |
put(K key,
S subKey,
T value)
put sub key value into the store incrementally.
|
void |
remove(K key)
remove key in the store.
|
public void put(K key, Map<S,T> value) throws IOException
KeyValueStoreput in interface KeyValueStore<K,Map<S,T>>IOExceptionpublic void put(K key, S subKey, T value) throws IOException
KeyMapStoreput in interface KeyMapStore<K,S,T>IOExceptionpublic Map<S,T> get(K key) throws IOException
KeyValueStoreget in interface KeyValueStore<K,Map<S,T>>IOExceptionpublic T get(K key, S subKey) throws IOException
KeyMapStoreget in interface KeyMapStore<K,S,T>IOExceptionpublic void remove(K key) throws IOException
KeyValueStoreremove in interface KeyValueStore<K,Map<S,T>>IOExceptionpublic void flush()
throws IOException
KeyValueStoreflush in interface KeyValueStore<K,Map<S,T>>IOExceptionpublic void clearCache()
KeyValueStoreclearCache in interface KeyValueStore<K,Map<S,T>>public void close()
throws IOException
KeyValueStoreclose in interface KeyValueStore<K,Map<S,T>>IOExceptionCopyright © 2020. All rights reserved.