|
Oracle Application Server Java Object Cache API Reference 10g Release 2 (10.1.2) B14018-02 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object
oracle.ias.cache.Cache
The Cache class provides APIs for cache administration tasks, such as initialization, termination and monitoring.
CacheAttributes
, CacheObjectInfo
Constructor Summary | |
Cache() |
Method Summary | |
static void |
close() marks the cache as " not ready" and shutdown the cache. |
static void |
destroy() globally destroys all the objects in the cache system, includes all processes, memory and disk. |
static void |
destroy(boolean localOnly) globally destroys all the objects in the cache memory and disk. |
static void |
dump() dumps all the objects in cache to the log file. |
static CacheHostInfo[] |
getActiveHostInfo() returns an array of CacheHostInfo objects, one for each active member of the cache system |
static CacheAttributes |
getAttributes() returns the attributes currently associated with the cache. |
static java.lang.String |
getCacheAddress() returns the String representation of the address currently being used by this instance of the cache, or null if the cache is not on the network. |
static oracle.ias.cache.CacheAddress |
getCacheAddressObject() returns the Object representation of the address of the current instance of the cache, or null if the cache is not on the network. |
static int |
getCacheId() returns the global cache Id in a distributed cache system. |
static CacheLogger |
getCacheLogger() returns a reference to the CacheLogger currently being used by the cache |
static long |
getCacheSize() returns an estimate of the number of bytes consumed by objects in the memory cache. |
static long |
getDistributedDiskCacheSize() returns the number of bytes consumed by objects in the distributed disk cache. |
static long |
getLocalDiskCacheSize() returns the number of bytes consumed by objects in the local disk cache. |
static int |
getObjectCount() returns the current count of objects in the cache. |
static java.lang.String |
getVersion() GetVersion returns the current version of the cache. |
static void |
init(CacheAttributes attr) initializes the cache. |
static void |
invalidate() globally invalidates all the objects in the cache system, includes all processes, memory and disk. |
static void |
invalidate(boolean localOnly) globally invalidates all the objects in the cache memory and disk. |
static boolean |
isDistributed() returns true if the cache is currently in distributed mode, that it is distributing updates and invalidates within the site, false if all cache actions are local to the process only. |
static boolean |
isReady() returns true if the cache has been initialized, false otherwise. |
static java.util.Enumeration |
listCacheObjects() returns an Enumeration of CacheObjectInfo objects describing the objects in all regions in the cache. |
static java.util.Enumeration |
listCacheObjects(java.lang.String region) returns an Enumeration of CacheObjectInfo objects describing the objects in specified region in the cache. |
static void |
open() reads the configuration files and establishs the Java caching system in the process. |
static void |
open(java.lang.String configFile) reads the configuration files and establishs the Java caching system in the process. |
static void |
resetAttributes(CacheAttributes attr) allows some cache attributes to be reset while the cache is running. |
static void |
setLogSeverity(int severity) sets the log severity of the cache system. |
static void |
updateStats() aggregate the statics for the cache. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public Cache()
Method Detail |
public static void open() throws CacheException
CacheException
- if the open()
fails.public static void open(java.lang.String configFile) throws CacheException
configFile
- the name of the configuration file to read the configuration information fromCacheException
- if the open()
fails.public static void init(CacheAttributes attr) throws CacheException
attr
- CacheAttributes which has the cache configuration information.CacheException
- if the init()
fails.public static void close()
public static CacheAttributes getAttributes() throws CacheNotAvailableException
CacheNotAvailableException
- if the cache has not been intialized.public static int getObjectCount() throws CacheNotAvailableException
CacheNotAvailableException
- if the cache has not been intialized.public static long getCacheSize() throws CacheNotAvailableException
CacheNotAvailableException
- if the cache has not been intialized.public static long getLocalDiskCacheSize() throws CacheNotAvailableException
If the disk cache is not configured, this method will return 0.
CacheNotAvailableException
- if the cache has not been intialized.public static long getDistributedDiskCacheSize() throws CacheNotAvailableException
CacheNotAvailableException
- if the cache has not been intialized.public static void resetAttributes(CacheAttributes attr) throws CacheNotAvailableException
attr
- CacheAttributes which has the cache configuration information.CacheNotAvailableException
- if the cache has not been intialized.public static void invalidate() throws CacheException
CacheException
- if any cache error occurspublic static void invalidate(boolean localOnly) throws CacheException
localOnly
- if true only objects in the local cache are invalidatedCacheException
- if any cache error occurspublic static void destroy() throws CacheException
CacheException
- if any cache error occurspublic static void destroy(boolean localOnly) throws CacheException
localOnly
- if true only objects in the local cache are invalidatedCacheException
- if any cache error occurspublic static java.lang.String getVersion()
public static void dump()
public static boolean isReady()
public static boolean isDistributed()
public static java.util.Enumeration listCacheObjects()
CacheObjectInfo
public static java.util.Enumeration listCacheObjects(java.lang.String region)
CacheObjectInfo
public static void setLogSeverity(int severity)
CacheLogger
public static int getCacheId()
public static void updateStats()
The statistics for the cache are aggregated as a background task at the interval specified by the "cleanInterval" configuration parameter or by directly calling updateStats. If a cache is already in the process of aggregating statistics, updateStats will block until the aggregation is complete.
AggregateStatus
public static java.lang.String getCacheAddress()
public static oracle.ias.cache.CacheAddress getCacheAddressObject() throws CacheException
CacheException
public static CacheHostInfo[] getActiveHostInfo() throws CacheException
CacheException
public static CacheLogger getCacheLogger()
|
Oracle Application Server Java Object Cache API Reference 10g Release 2 (10.1.2) B14018-02 |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |