com.ibm.websphere.cache

Class DynamicCacheAccessor

  1. java.lang.Object
  2. extended bycom.ibm.websphere.cache.DynamicCacheAccessor

  1. public final class DynamicCacheAccessor
  2. extends java.lang.Object
This class provides applications with access to the Dynamic Cache, allowing programmatic inspection and manipulation of WebSphere's cache.

Constructor Summary

Constructor and Description
DynamicCacheAccessor()

Method Summary

Modifier and Type Method and Description
  1. static
  2. Cache
getCache()
Deprecated. Use DistributedMap to store and manage objects in cache. DynamicCacheAccessor#getDistributedMap will return a DistributedMap for accessing base cache.
  1. static
  2. DistributedMap
getDistributedMap()
Deprecated. baseCache is used for servlet caching. It should not be used as a DistributedMap.
  1. static
  2. DistributedNioMap
getProxyCacheInstance(java.lang.String name)
This method will return a DistributedObjectCache reference to a Proxy Server or On Demand Router's cache instance.
  1. static
  2. boolean
isCachingEnabled()
This determines if Dynamic caching (either servlet or object cache) is enabled.
  1. static
  2. boolean
isObjectCachingEnabled()
This determines if Dynamic object caching is enabled.
  1. static
  2. boolean
isServletCachingEnabled()
This determines if Dynamic servlet caching is enabled.
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

Constructor Detail

DynamicCacheAccessor

  1. public DynamicCacheAccessor()

Method Detail

getCache

  1. public static Cache getCache()
Deprecated. Use DistributedMap to store and manage objects in cache. DynamicCacheAccessor#getDistributedMap will return a DistributedMap for accessing base cache.
This obtains a reference to the dynamic cache.
Returns:
Reference to the cache or null if caching is disabled
See Also:

isCachingEnabled

  1. public static boolean isCachingEnabled( )
This determines if Dynamic caching (either servlet or object cache) is enabled.
Returns:
true if caching is enabled, false if it is disabled.

isServletCachingEnabled

  1. public static boolean isServletCachingEnabled( )
This determines if Dynamic servlet caching is enabled.
Returns:
true if caching is enabled, false if it is disabled.

isObjectCachingEnabled

  1. public static boolean isObjectCachingEnabled( )
This determines if Dynamic object caching is enabled.
Returns:
true if caching is enabled, false if it is disabled.

getDistributedMap

  1. public static DistributedMap getDistributedMap( )
Deprecated. baseCache is used for servlet caching. It should not be used as a DistributedMap.
This method will return a DistributedMap reference to the dynamic cache.
Returns:
Reference to the DistributedMap or null if caching is disabled.
Since:
v6.0

getProxyCacheInstance

  1. public static DistributedNioMap getProxyCacheInstance( java.lang.String name)
This method will return a DistributedObjectCache reference to a Proxy Server or On Demand Router's cache instance.
Parameters:
name - The in-memory name of the proxy's cache instance
Returns:
Reference to the Proxy's cache instance. Null if instance is not found or if we are not in a Proxy Server