public class NoOpBackingStore<K extends Serializable,V extends Serializable> extends BackingStore<K,V>
| Modifier and Type | Method and Description |
|---|---|
void |
destroy()
Called when the store is no longer needed.
|
BackingStoreFactory |
getBackingStoreFactory() |
protected void |
initialize(BackingStoreConfiguration<K,V> conf) |
V |
load(K key,
String version)
Load and return the data for the given id.
|
void |
remove(K key)
Remove the association for the id.
|
int |
removeExpired()
Remove expired entries
|
String |
save(K key,
V value,
boolean isNew)
Save the value whose key is id.
|
int |
size()
Get the current size of the store
|
String |
updateTimestamp(K key,
String version,
Long accessTime)
Recomended way is to just do a save(k, v)
|
close, createObjectInputStream, createObjectOutputStream, getBackingStoreConfiguration, removeExpired, updateTimestampprotected void initialize(BackingStoreConfiguration<K,V> conf) throws BackingStoreException
initialize in class BackingStore<K extends Serializable,V extends Serializable>BackingStoreExceptionpublic BackingStoreFactory getBackingStoreFactory()
getBackingStoreFactory in class BackingStore<K extends Serializable,V extends Serializable>public V load(K key, String version) throws BackingStoreException
BackingStoresave() method.load in class BackingStore<K extends Serializable,V extends Serializable>key - the key whose value must be returnedBackingStoreException - if the underlying store implementation encounters any
exceptionpublic String save(K key, V value, boolean isNew) throws BackingStoreException
BackingStoresave in class BackingStore<K extends Serializable,V extends Serializable>key - the idvalue - The Metadata to be storedBackingStoreException - if the underlying store implementation encounters any
exceptionpublic void remove(K key) throws BackingStoreException
BackingStoreload(id) must return
null. In addition, any association between id and
container extra params must also be removed.remove in class BackingStore<K extends Serializable,V extends Serializable>key - the id of the MetadataBackingStoreException - if the underlying store implementation encounters any
exceptionpublic String updateTimestamp(K key, String version, Long accessTime) throws BackingStoreException
BackingStoreupdateTimestamp in class BackingStore<K extends Serializable,V extends Serializable>BackingStoreExceptionpublic int removeExpired()
throws BackingStoreException
BackingStoreremoveExpired in class BackingStore<K extends Serializable,V extends Serializable>BackingStoreExceptionpublic int size()
throws BackingStoreException
BackingStoresize in class BackingStore<K extends Serializable,V extends Serializable>BackingStoreException - if the underlying store implementation encounters any
exceptionpublic void destroy()
throws BackingStoreException
BackingStoredestroy in class BackingStore<K extends Serializable,V extends Serializable>BackingStoreExceptionCopyright © 2017-2019 Eclipse Foundation. All Rights Reserved.