|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.apache.jcs.engine.control.CompositeCacheManager
Manages a composite cache.
Field Summary | |
protected java.util.Hashtable |
auxAttrs
??? |
protected java.util.Hashtable |
auxFacs
Used to keep track of configured auxiliaries |
protected java.util.Hashtable |
caches
Caches managed by this cache manager |
private int |
clients
Number of clients accessing this cache manager |
protected java.lang.String |
defaultAuxValues
The default auxiliary caches to be used if not preconfigured |
protected ICompositeCacheAttributes |
defaultCacheAttr
Default cache attributes for this cache manager |
protected IElementAttributes |
defaultElementAttr
Default elemeent attributes for this cache manager |
protected static CompositeCacheManager |
instance
The Singleton Instance |
private static org.apache.commons.logging.Log |
log
|
protected java.util.Properties |
props
Properties with which this manager was configured |
protected java.util.Hashtable |
systemCaches
Internal system caches for this cache manager |
Fields inherited from interface org.apache.jcs.auxiliary.remote.behavior.IRemoteCacheConstants |
REMOTE_ALLOW_CLUSTER_GET, REMOTE_CACHE_SERVICE_NAME, REMOTE_CACHE_SERVICE_PORT, REMOTE_CACHE_SERVICE_VAL, REMOTE_LOCAL_CLUSTER_CONSISTENCY, TOMCAT_ON, TOMCAT_XML |
Constructor Summary | |
CompositeCacheManager()
|
Method Summary | |
void |
configure()
Configure with default properties file |
void |
configure(java.util.Properties props)
Configure from properties object |
void |
configure(java.lang.String propFile)
Configure from specific properties file |
protected static CompositeCacheManager |
createInstance()
Simple factory method, must override in subclasses so getInstance creates / returns the correct object. |
void |
freeCache(java.lang.String name)
|
void |
freeCache(java.lang.String name,
boolean fromRemote)
|
CompositeCache |
getCache(ICompositeCacheAttributes cattr)
Gets the cache attribute of the CacheHub object |
CompositeCache |
getCache(ICompositeCacheAttributes cattr,
IElementAttributes attr)
If the cache is created the CacheAttributes and the element Attributes will be ignored. |
CompositeCache |
getCache(java.lang.String cacheName)
Gets the cache attribute of the CacheHub object |
CompositeCache |
getCache(java.lang.String cacheName,
ICompositeCacheAttributes cattr)
Gets the cache attribute of the CacheHub object |
CompositeCache |
getCache(java.lang.String cacheName,
ICompositeCacheAttributes cattr,
IElementAttributes attr)
Gets the cache attribute of the CacheHub object |
java.lang.String[] |
getCacheNames()
Returns a list of the current cache names. |
int |
getCacheType()
|
ICompositeCacheAttributes |
getDefaultCacheAttributes()
Gets the defaultCacheAttributes attribute of the CacheHub object |
ICompositeCacheAttributes |
getDefaultCattr()
|
IElementAttributes |
getDefaultElementAttributes()
Gets the defaultElementAttributes attribute of the CacheHub object |
static CompositeCacheManager |
getInstance()
Gets the CacheHub instance. |
static CompositeCacheManager |
getInstance(java.lang.String propsFilename)
|
static CompositeCacheManager |
getUnconfiguredInstance()
Get a CacheHub instance which is not configured. |
protected void |
incrementClients()
|
(package private) AuxiliaryCacheAttributes |
registryAttrGet(java.lang.String name)
|
(package private) void |
registryAttrPut(AuxiliaryCacheAttributes auxAttr)
|
(package private) AuxiliaryCacheFactory |
registryFacGet(java.lang.String name)
|
(package private) void |
registryFacPut(AuxiliaryCacheFactory auxFac)
|
void |
release()
|
private void |
release(boolean fromRemote)
|
void |
setDefaultCacheAttributes(ICompositeCacheAttributes icca)
Sets the defaultCacheAttributes attribute of the CacheHub object |
void |
setDefaultElementAttributes(IElementAttributes iea)
Sets the defaultElementAttributes attribute of the CacheHub object |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
private static final org.apache.commons.logging.Log log
protected java.util.Hashtable caches
protected java.util.Hashtable systemCaches
private int clients
protected ICompositeCacheAttributes defaultCacheAttr
protected IElementAttributes defaultElementAttr
protected java.util.Hashtable auxFacs
protected java.util.Hashtable auxAttrs
protected java.util.Properties props
protected java.lang.String defaultAuxValues
protected static CompositeCacheManager instance
Constructor Detail |
public CompositeCacheManager()
Method Detail |
public static CompositeCacheManager getInstance()
getUnconfiguredInstance()
and then call configure()
public static CompositeCacheManager getInstance(java.lang.String propsFilename)
public static CompositeCacheManager getUnconfiguredInstance()
protected static CompositeCacheManager createInstance()
public void configure()
public void configure(java.lang.String propFile)
propFile
- Path within classpath to load configuration frompublic void configure(java.util.Properties props)
props
- public ICompositeCacheAttributes getDefaultCacheAttributes()
public void setDefaultCacheAttributes(ICompositeCacheAttributes icca)
icca
- The new defaultCacheAttributes valuepublic void setDefaultElementAttributes(IElementAttributes iea)
iea
- The new defaultElementAttributes valuepublic IElementAttributes getDefaultElementAttributes()
public CompositeCache getCache(java.lang.String cacheName)
public CompositeCache getCache(java.lang.String cacheName, ICompositeCacheAttributes cattr)
public CompositeCache getCache(java.lang.String cacheName, ICompositeCacheAttributes cattr, IElementAttributes attr)
public CompositeCache getCache(ICompositeCacheAttributes cattr)
public CompositeCache getCache(ICompositeCacheAttributes cattr, IElementAttributes attr)
public void freeCache(java.lang.String name)
public void freeCache(java.lang.String name, boolean fromRemote)
protected void incrementClients()
public void release()
private void release(boolean fromRemote)
public java.lang.String[] getCacheNames()
public int getCacheType()
public ICompositeCacheAttributes getDefaultCattr()
void registryFacPut(AuxiliaryCacheFactory auxFac)
AuxiliaryCacheFactory registryFacGet(java.lang.String name)
void registryAttrPut(AuxiliaryCacheAttributes auxAttr)
AuxiliaryCacheAttributes registryAttrGet(java.lang.String name)
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |