|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jboss.ha.framework.server.CacheManagerLocator
public class CacheManagerLocator
Service Locator utility for locating a PojoCacheManager
. Maintains
an internal ref to a manager, and if it that is null,
will attempt to find it in JNDI using a standard naming pattern.
Field Summary | |
---|---|
static String |
STANDARD_JNDI_NAME
Name of the standard JNDI context under which HAPartitions are bound |
Constructor Summary | |
---|---|
protected |
CacheManagerLocator()
Allow subclasses to create a new HAPartitionLocator. |
Method Summary | |
---|---|
void |
deregisterCacheManager()
Deregister the manager from this locator. |
protected org.jboss.cache.CacheManager |
findInJndi(Hashtable jndiProperties)
Find the given CacheManager in JNDI under a standard binding . |
org.jboss.cache.CacheManager |
getCacheManager(Hashtable jndiProperties)
Locates and returns the HAPartition whose partition name matches
the given partitionName . |
static CacheManagerLocator |
getCacheManagerLocator()
Gets the |
org.jboss.cache.CacheManager |
getDirectlyRegisteredManager()
|
void |
registerCacheManager(org.jboss.cache.CacheManager manager)
Register a CacheManager with this locator. |
protected static void |
setSharedInstance(CacheManagerLocator shared)
Allows replacement of the default implementation. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public static final String STANDARD_JNDI_NAME
Constructor Detail |
---|
protected CacheManagerLocator()
Method Detail |
---|
public static CacheManagerLocator getCacheManagerLocator()
null
protected static void setSharedInstance(CacheManagerLocator shared)
shared
- the locator to use. Cannot be null
.public org.jboss.cache.CacheManager getCacheManager(Hashtable jndiProperties)
HAPartition
whose partition name matches
the given partitionName
.
jndiProperties
- any naming properties to pass to new InitialContext()
if JNDI lookup is needed.
null
IllegalStateException
- if no cache manager can be foundpublic void registerCacheManager(org.jboss.cache.CacheManager manager)
manager
- the managerpublic org.jboss.cache.CacheManager getDirectlyRegisteredManager()
public void deregisterCacheManager()
protected org.jboss.cache.CacheManager findInJndi(Hashtable jndiProperties) throws NamingException
standard binding
.
jndiProperties
- any naming properties to pass to new InitialContext()
null
NamingException
- if there is a problem with the naming context. Will
not throw NameNotFoundException; if not found, will
return null
.STANDARD_JNDI_NAME
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |