public class ProvidedPartitionableObjectStoreWrapper<T extends Serializable> extends ProvidedObjectStoreWrapper<T> implements PartitionableObjectStore<T>
PHASE_NAME
Constructor and Description |
---|
ProvidedPartitionableObjectStoreWrapper(PartitionableObjectStore<T> providedObjectStore,
org.apache.commons.collections.Factory objectStoreFactory)
Wraps the
providedObjectStore if given, or uses the objectStoreFactory to create one. |
Modifier and Type | Method and Description |
---|---|
List<Serializable> |
allKeys() |
List<Serializable> |
allKeys(String partitionName) |
List<String> |
allPartitions() |
void |
clear(String partitionName) |
void |
close()
Close the underlying store.
|
void |
close(String partitionName) |
boolean |
contains(Serializable key,
String partitionName) |
void |
disposePartition(String partitionName) |
protected PartitionableObjectStore<T> |
getWrapped() |
void |
open()
Open the underlying store.
|
void |
open(String partitionName) |
T |
remove(Serializable key,
String partitionName) |
T |
retrieve(Serializable key,
String partitionName) |
void |
store(Serializable key,
T value,
String partitionName) |
clear, contains, dispose, isPersistent, remove, retrieve, store
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
clear, contains, isPersistent, remove, retrieve, store
public ProvidedPartitionableObjectStoreWrapper(PartitionableObjectStore<T> providedObjectStore, org.apache.commons.collections.Factory objectStoreFactory)
providedObjectStore
if given, or uses the objectStoreFactory
to create one.providedObjectStore
- the objectStroe provided through config to use. May be null.objectStoreFactory
- the factory to use to build an object store if providedObjectStore
is null.public void open() throws ObjectStoreException
ListableObjectStore
open
in interface ListableObjectStore<T extends Serializable>
ObjectStoreException
- if an exception occurred while opening the underlying store.public void close() throws ObjectStoreException
ListableObjectStore
close
in interface ListableObjectStore<T extends Serializable>
ObjectStoreException
- if an exception occurred while closing the underlying store.public List<Serializable> allKeys() throws ObjectStoreException
allKeys
in interface ListableObjectStore<T extends Serializable>
ObjectStoreException
- if an exception occurred while collecting the list of all keys.public boolean contains(Serializable key, String partitionName) throws ObjectStoreException
contains
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public void store(Serializable key, T value, String partitionName) throws ObjectStoreException
store
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public T retrieve(Serializable key, String partitionName) throws ObjectStoreException
retrieve
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public T remove(Serializable key, String partitionName) throws ObjectStoreException
remove
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public List<Serializable> allKeys(String partitionName) throws ObjectStoreException
allKeys
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public List<String> allPartitions() throws ObjectStoreException
allPartitions
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public void open(String partitionName) throws ObjectStoreException
open
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public void close(String partitionName) throws ObjectStoreException
close
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public void disposePartition(String partitionName) throws ObjectStoreException
disposePartition
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
public void clear(String partitionName) throws ObjectStoreException
clear
in interface PartitionableObjectStore<T extends Serializable>
ObjectStoreException
protected PartitionableObjectStore<T> getWrapped()
getWrapped
in class ProvidedObjectStoreWrapper<T extends Serializable>
Copyright © 2003–2016 MuleSoft, Inc.. All rights reserved.