public final class CacheManager
extends java.lang.Object
Cache
Constructor | Description |
---|---|
CacheManager() |
Modifier and Type | Method | Description |
---|---|---|
static Cache |
getCache(java.lang.String cacheName) |
Returns an instance of
Cache for this application. |
static Cache |
getCache(java.lang.String cacheName,
CacheConnectionOptions cacheConnectionOptions) |
Returns an instance of
Cache for this application. |
static Cache |
getCache(java.lang.String cacheName,
CacheConnectionOptions cacheConnectionOptions,
java.lang.String clientCacheName,
CacheConnectionOptions clientCacheConnectionOptions) |
Returns an instance of
Cache for this application. |
static CacheCollection |
getCaches() |
Returns
CacheCollection of the caches initialized within the same application domain. |
static void |
setConfigPath(java.lang.String path) |
hidden
|
static void |
startCache(java.lang.String cacheName,
CacheConnection connection) |
Starts an out-proc cache.
|
static void |
stopCache(java.lang.String cacheName,
CacheConnection connection,
boolean gracefullyShutDownNode) |
Stops an out-proc cache.
|
public static CacheCollection getCaches()
CacheCollection
of the caches initialized within the same application domain.public static void setConfigPath(java.lang.String path)
path
- public static Cache getCache(java.lang.String cacheName) throws java.lang.Exception
Cache
for this application.public static Cache getCache(java.lang.String cacheName, CacheConnectionOptions cacheConnectionOptions) throws java.lang.Exception
Cache
for this application.cacheName
- The identifier for the Cache
.cacheConnectionOptions
- CacheConnectionOptions
parameters for cache connection.Cache
.java.lang.Exception
public static Cache getCache(java.lang.String cacheName, CacheConnectionOptions cacheConnectionOptions, java.lang.String clientCacheName, CacheConnectionOptions clientCacheConnectionOptions) throws java.lang.Exception
Cache
for this application.cacheName
- The identifier for the Cache
.cacheConnectionOptions
- CacheConnectionOptions
parameters for cache connection.clientCacheName
- The identifier for the ClientCache.clientCacheConnectionOptions
- CacheConnectionOptions
parameters for ClientCache connection.Cache
.java.lang.Exception
public static void startCache(java.lang.String cacheName, CacheConnection connection) throws Alachisoft.NCache.Common.Exceptions.ManagementException, java.net.UnknownHostException, ConfigurationException
ManagementException
exception.
It tries to get the Security Parameters from the client.ncconf.cacheName
- The identifier for the Cache
.connection
- CacheConnection
parameters for connection to Cache.Alachisoft.NCache.Common.Exceptions.ManagementException
java.net.UnknownHostException
ConfigurationException
public static void stopCache(java.lang.String cacheName, CacheConnection connection, boolean gracefullyShutDownNode) throws Alachisoft.NCache.Common.Exceptions.ManagementException, java.net.UnknownHostException, ConfigurationException
ManagementException
exception.
It tries to get the Security Parameters from the client.ncconf.cacheName
- The identifier for the Cache
.connection
- CacheConnection
parameters for connection to Cache.gracefullyShutDownNode
- The flag for graceful node shutdown.Alachisoft.NCache.Common.Exceptions.ManagementException
java.net.UnknownHostException
ConfigurationException