public class SimpleBackingCacheEntryStore<K extends Serializable,V extends Cacheable<K>,E extends BackingCacheEntry<K,V>> extends AbstractBackingCacheEntryStore<K,V,E>
BackingCacheEntryStore that stores in a simple Map and delegates to a provided
PersistentObjectStore for persistence.| Constructor and Description |
|---|
SimpleBackingCacheEntryStore(PersistentObjectStore<K,E> store,
ServerEnvironment environment,
StatefulTimeoutInfo timeout,
BackingCacheEntryStoreConfig config)
Create a new SimpleIntegratedObjectStore.
|
| Modifier and Type | Method and Description |
|---|---|
E |
get(K key,
boolean lock)
Gets the entry with the given id from the store.
|
org.jboss.ejb.client.Affinity |
getStrictAffinity()
Returns the strict affinity associated with the entries of this cache
|
org.jboss.ejb.client.Affinity |
getWeakAffinity(K key)
Returns the weak affinity associated with the specified entry of this cache
|
boolean |
hasAffinity(K key)
Indicates whether the cache has an affinity for the specified key.
|
Set<K> |
insert(E entry)
Put a new entry into the store.
|
boolean |
isClustered()
Gets whether this store supports clustering functionality.
|
boolean |
isCompatibleWith(GroupCompatibilityChecker other)
Gets whether this object can work compatibly with another in the management of
SerializationGroups. |
void |
passivate(E entry)
Remove the entry with the given key from any in-memory store while retaining it in the persistent store.
|
E |
remove(K id)
Remove the object with the given key from the store.
|
void |
start()
Perform any initialization work.
|
void |
stop()
Perform any shutdown work.
|
void |
update(E entry,
boolean modified)
Update an already cached item.
|
getConfig, getTimeoutpublic SimpleBackingCacheEntryStore(PersistentObjectStore<K,E> store, ServerEnvironment environment, StatefulTimeoutInfo timeout, BackingCacheEntryStoreConfig config)
public org.jboss.ejb.client.Affinity getStrictAffinity()
AffinitySupportpublic org.jboss.ejb.client.Affinity getWeakAffinity(K key)
AffinitySupportpublic boolean hasAffinity(K key)
AffinitySupportkey - a candidate keypublic boolean isClustered()
BackingCacheEntryStoretrue if clustering is supported, false otherwisepublic E get(K key, boolean lock)
BackingCacheEntryStorekey - id of the entry. Cannot be null.id. May return null.public Set<K> insert(E entry)
BackingCacheEntryStoreentry - the object to store. Cannot be null.public void update(E entry, boolean modified)
BackingCacheEntryStoreentry - the entry to updatemodified - was the entry modified since BackingCacheEntryStore.get(java.io.Serializable, boolean) was called?public void passivate(E entry)
BackingCacheEntryStoreentry - the entry to passivatepublic E remove(K id)
BackingCacheEntryStoreid - id of the entry. Cannot be null.keypublic void start()
BackingCacheEntryStorepublic void stop()
BackingCacheEntryStorepublic boolean isCompatibleWith(GroupCompatibilityChecker other)
GroupCompatibilityCheckerSerializationGroups.other - the other checker. May be null.true if this object is compatible with other, false otherwiseCopyright © 2013 JBoss, a division of Red Hat, Inc.. All Rights Reserved.