public interface BasicCacheContainer extends Lifecycle
org.infinispan.api.BasicCache
.
EmbeddedCacheManager
,
RemoteCacheManager
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_CACHE_NAME
Deprecated.
|
Modifier and Type | Method and Description |
---|---|
<K,V> BasicCache<K,V> |
getCache()
Retrieves the default cache associated with this cache container.
|
<K,V> BasicCache<K,V> |
getCache(String cacheName)
Retrieves a named cache from the system.
|
@Deprecated static final String DEFAULT_CACHE_NAME
<K,V> BasicCache<K,V> getCache()
<K,V> BasicCache<K,V> getCache(String cacheName)
EmbeddedCacheManager
: when creating a new cache, this method will
use the configuration passed in to the EmbeddedCacheManager on construction, as a template, and then optionally
apply any overrides previously defined for the named cache using the EmbeddedCacheManager#defineConfiguration(String, org.infinispan.config.Configuration)
or EmbeddedCacheManager#defineConfiguration(String, String, org.infinispan.config.Configuration)
methods, or declared in the configuration file.
NB: Shared caches are supported (and in fact encouraged) but if they are used it's the users responsibility to
ensure that at least one but only one caller calls stop() on the cache, and it does so with the awareness
that others may be using the cache.cacheName
- name of cache to retrieveCopyright © 2017 JBoss, a division of Red Hat. All rights reserved.