Save This Page
Home » hibernate-distribution-3.3.1.GA-dist » org.hibernate » cache » jbc2 » builder » [javadoc | source]
org.hibernate.cache.jbc2.builder
public class: MultiplexingCacheInstanceManager [javadoc | source]
java.lang.Object
   org.hibernate.cache.jbc2.builder.MultiplexingCacheInstanceManager

All Implemented Interfaces:
    CacheInstanceManager

Direct Known Subclasses:
    JndiMultiplexingCacheInstanceManager

Allows building separate Cache instances for each type of region, with the expectation that a single multiplexed JGroups resource (i.e. a multiplexed channel or a shared transport channel) will be shared between the caches.

Field Summary
public static final  String CACHE_FACTORY_RESOURCE_PROP    Classpath or filesystem resource containing JBoss Cache configurations the factory should use. 
public static final  String CHANNEL_FACTORY_RESOURCE_PROP    Classpath or filesystem resource containing JGroups protocol stack configurations the org.jgroups.ChannelFactory should use. 
public static final  String ENTITY_CACHE_RESOURCE_PROP    Name of the configuration that should be used for entity caches. 
public static final  String COLLECTION_CACHE_RESOURCE_PROP    Name of the configuration that should be used for collection caches. No default value, as by default we try to use the same JBoss Cache instance we use for entity caching. 
public static final  String TIMESTAMP_CACHE_RESOURCE_PROP    Name of the configuration that should be used for timestamp caches. 
public static final  String QUERY_CACHE_RESOURCE_PROP    Name of the configuration that should be used for query caches. 
public static final  String DEF_CACHE_FACTORY_RESOURCE    Default value for #CACHE_FACTORY_RESOURCE_PROP . Specifies the "jbc2-configs.xml" file in this package. 
public static final  String DEF_JGROUPS_RESOURCE    Default value for #CHANNEL_FACTORY_RESOURCE_PROP . Specifies the "jgroups-stacks.xml" file in this package. 
public static final  String DEF_ENTITY_RESOURCE    Default value for #ENTITY_CACHE_RESOURCE_PROP
public static final  String DEF_TS_RESOURCE    Default value for #TIMESTAMP_CACHE_RESOURCE_PROP
public static final  String DEF_QUERY_RESOURCE    Default value for #ENTITY_CACHE_RESOURCE_PROP
Constructor:
 public MultiplexingCacheInstanceManager() 
 public MultiplexingCacheInstanceManager(Cache jbcEntityCache,
    Cache jbcCollectionCache,
    Cache jbcTsCache,
    Cache jbcQueryCache) 
    Create a new MultiplexingCacheInstanceManager using the provided Cache s.

    If this constructor is used, the #start(Settings, Properties) method will make no attempt to create a cache factory or obtain caches from it. Only the Caches passed as arguments to this constructor will be available.

    Parameters:
    jbcEntityCache - The entity cache
    jbcCollectionCache - the collection cache
    jbcTsCache - The timestamps cache
    jbcQueryCache - The query cache
Method from org.hibernate.cache.jbc2.builder.MultiplexingCacheInstanceManager Summary:
getCacheFactory,   getChannelFactory,   getCollectionCacheInstance,   getEntityCacheInstance,   getQueryCacheInstance,   getTimestampsCacheInstance,   setCacheFactory,   setChannelFactory,   start,   stop
Methods from java.lang.Object:
equals,   getClass,   hashCode,   notify,   notifyAll,   toString,   wait,   wait,   wait
Method from org.hibernate.cache.jbc2.builder.MultiplexingCacheInstanceManager Detail:
 public CacheManager getCacheFactory() 
    Getter for property 'cacheFactory'.
 public ChannelFactory getChannelFactory() 
    Getter for property 'channelFactory'.
 public Cache getCollectionCacheInstance() 
    {@inheritDoc}
 public Cache getEntityCacheInstance() 
    {@inheritDoc}
 public Cache getQueryCacheInstance() 
    {@inheritDoc}
 public Cache getTimestampsCacheInstance() 
    {@inheritDoc}
 public  void setCacheFactory(CacheManager factory) 
    Setter for property 'cacheFactory'.
 public  void setChannelFactory(ChannelFactory factory) 
    Setter for property 'channelFactory'.
 public  void start(Settings settings,
    Properties properties) throws CacheException 
    {@inheritDoc}
 public  void stop() 
    {@inheritDoc}