public class JavaxCacheLevel2Cache extends AbstractLevel2Cache
cacheName, clearAtClose, expiryMillis, maxSize, nucleusCtx| Constructor and Description |
|---|
JavaxCacheLevel2Cache(NucleusContext nucleusCtx)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
close()
Method to close the cache when no longer needed.
|
boolean |
containsOid(Object oid)
Accessor for whether the cache contains the specified id.
|
void |
evict(Object oid)
Evict the parameter instance from the second-level cache.
|
void |
evictAll()
Evict the parameter instances from the second-level cache.
|
void |
evictAll(Class pcClass,
boolean subclasses)
Evict the parameter instances from the second-level cache.
|
void |
evictAll(Collection oids)
Evict the parameter instances from the second-level cache.
|
void |
evictAll(Object[] oids)
Evict the parameter instances from the second-level cache.
|
CachedPC |
get(Object oid)
Accessor for an object in the cache.
|
Map<Object,CachedPC> |
getAll(Collection oids)
Accessor for a collection of objects from the cache.
|
CachedPC |
getUnique(CacheUniqueKey key)
Method to retrieve the id represented by the specified unique key.
|
CachedPC |
put(Object oid,
CachedPC pc)
Method to add an object to the cache under its id
|
void |
putAll(Map<Object,CachedPC> objs)
Method to put several objects into the cache.
|
CachedPC |
putUnique(CacheUniqueKey key,
CachedPC pc)
Method to store a persistable object for this unique key.
|
void |
putUniqueAll(Map<CacheUniqueKey,CachedPC> objs)
Method to put several objects into the cache.
|
void |
removeUnique(CacheUniqueKey key)
Method to remove any object cached against the provided unique key.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitgetNumberOfPinnedObjects, getNumberOfUnpinnedObjects, getSize, isEmpty, pin, pinAll, pinAll, pinAll, unpin, unpinAll, unpinAll, unpinAllpublic JavaxCacheLevel2Cache(NucleusContext nucleusCtx)
nucleusCtx - Contextpublic void close()
public boolean containsOid(Object oid)
oid - The object idLevel2Cache.containsOid(java.lang.Object)public CachedPC get(Object oid)
oid - The Object IDLevel2Cache.get(java.lang.Object)public Map<Object,CachedPC> getAll(Collection oids)
Level2Cacheoids - The Object IDspublic CachedPC put(Object oid, CachedPC pc)
oid - The identitypc - The cacheable objectpublic void putAll(Map<Object,CachedPC> objs)
Level2Cacheobjs - Map of cacheable object keyed by its oid.public void evict(Object oid)
oid - the object id of the instance to evict.public void evictAll()
public void evictAll(Collection oids)
oids - the object ids of the instance to evict.public void evictAll(Object[] oids)
oids - the object ids of the instance to evict.public void evictAll(Class pcClass, boolean subclasses)
pcClass - the class of instances to evictsubclasses - if true, evict instances of subclasses alsopublic CachedPC getUnique(CacheUniqueKey key)
Level2Cachekey - Unique keypublic CachedPC putUnique(CacheUniqueKey key, CachedPC pc)
Level2Cachekey - The unique keypc - The representation of the persistable object to cachepublic void putUniqueAll(Map<CacheUniqueKey,CachedPC> objs)
Level2Cacheobjs - Map of cacheable object keyed by the unique keys.public void removeUnique(CacheUniqueKey key)
Level2Cachekey - Unique keyCopyright © 2019. All rights reserved.