V - serializable type of the mapped value
public abstract class AbstractDataStore<V extends Serializable> extends Objectimplements DataStore <V>
| Modifier | Constructor and Description |
|---|---|
protected |
AbstractDataStore(DataStoreFactory
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
containsKey(String
Returns whether the store contains the given key.
|
boolean |
containsValue(V value)
Returns whether the store contains the given value.
|
DataStoreFactory |
getDataStoreFactory()
Returns the data store factory.
|
String |
getId()
Returns the data store ID.
|
boolean |
isEmpty()
Returns whether there are any stored keys.
|
int |
size()
Returns the number of stored keys.
|
protected AbstractDataStore(DataStoreFactorydataStoreFactory, String id)
dataStoreFactory - data store factory
id - data store ID
public DataStoreFactorygetDataStoreFactory()
Overriding is only supported for the purpose of calling the super implementation and changing the return type, but nothing else.
public final StringgetId()
DataStore
public boolean containsKey(Stringkey) throws IOException
Default implementation is to call DataStore and check if it is null.
containsKey in interface
DataStore<V extends Serializable>
IOException
public boolean containsValue(V value) throws IOException
Default implementation is to call Collection on DataStore.
containsValue in interface
DataStore<V extends Serializable>
IOException
public boolean isEmpty()
throws IOException
Default implementation is to check if size() is 0.
isEmpty in interface
DataStore<V extends Serializable>
IOException
public int size()
throws IOException
Default implementation is to call Set on DataStore.
size in interface
DataStore<V extends Serializable>
IOException