|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--oracle.ias.cache.CacheAttributes
CacheAttributes has the Cache configuration information. It is a structure which is passed to Cache.init(CacheAttributes) to do the system wide configuration. All the fileds are public and user can access the fields directly. Two constructors and a set of convenient methods are provided.
Cache.init(CacheAttributes)
Field Summary |
Type | Field |
---|---|
int |
cleanInterval
Number of seconds between cache cleanings |
boolean |
cleanIntervalSet
|
java.lang.String |
diskPath
Absolute path to the the root of the disk cache directory |
int |
diskSize
The size of the disk cache in megabytes |
boolean |
diskSizeSet
|
boolean |
distribute
Indicates the cache is distributed, updates and invalidates are propagated to other caches in the system |
java.lang.String |
logFileName
Log file name for the default logger implementation. |
java.lang.String |
logger
The logger object which is used to log cache messages. |
int |
logSeverity
Log severity, see CacheLogger for details |
boolean |
logSeveritySet
|
int |
maxObjects
Maximum number of in-memory objects in the cache |
boolean |
maxObjectsSet
indicates attribute has been reset |
int |
maxSize
The size of the memory cache in megabytes |
boolean |
maxSizeSet
|
int |
pingInterval
Number of seconds between cache death detection(pinging) |
java.lang.String |
version
Version of the cache software |
Constructor Summary |
CacheAttributes()
Constructs a default CacheAttributes which will set all the values to default. |
Method Summary |
Type | Method |
---|---|
void |
addCacheAddr(java.net.InetAddress ipAddr,
int port)
adds a new ipAddr/port to the list of cache addresses |
void |
addCacheAddr(java.net.InetAddress ipAddr,
int port,
boolean replace)
adds a new ipAddr/port to the list of cache addresses |
java.lang.String |
getAddrListString()
Returns the list of cache addresses in a formatted string, if the list is null, set to the default |
java.util.Enumeration |
getCacheAddrs()
gets an enumeration of the list of cache addresses, if the list is null the enumerator will return the default address. |
void |
setCleanInterval(int pCleanInterval)
sets number of seconds between cache cleanings |
void |
setDiskPath(java.lang.String pDiskPath)
sets absolute path to the root of the disk cache directory. |
void |
setDiskSize(int pDiskSize)
sets the disk cache size |
void |
setDistribute(boolean pDistribute)
sets the distribute flag to indicate if the cache is local to the process of not |
void |
setLogFileName(java.lang.String pLogFileName)
sets the log file name for the DefaultCacheLogger. |
void |
setLogger(java.lang.String pLogger)
sets the logger object which will be used to log cache messages. |
void |
setLogSeverity(int severity)
sets the log severity which determines which log messages are published to the log |
void |
setMaxObjects(int pMaxObjects)
sets the maximum number of in-memory objects in the cache. |
void |
setMaxSize(int pMaxSize)
sets the maximum number of bytes available to the in-memory cache |
void |
setPingInterval(int pPingInterval)
sets number of seconds between cache death detection |
java.lang.String |
toString()
converts this object into a formatted string |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
public boolean distribute
public java.lang.String version
public int maxObjects
public int maxSize
public int diskSize
public java.lang.String diskPath
public int cleanInterval
public int pingInterval
public java.lang.String logger
public java.lang.String logFileName
public int logSeverity
public boolean maxObjectsSet
public boolean maxSizeSet
public boolean diskSizeSet
public boolean logSeveritySet
public boolean cleanIntervalSet
Constructor Detail |
public CacheAttributes() throws CacheException
Method Detail |
public void setDistribute(boolean pDistribute)
pDistribute
- is true, means the cache is part of the distributed
cache otherwise, the cache is local to the process.public void setMaxObjects(int pMaxObjects)
pMaxObjects
- maximum number of in-memory objects in the cachepublic void setMaxSize(int pMaxSize)
pMaxObjects
- maximum number of bytes available to the cachepublic void setDiskSize(int pDiskSize)
pDiskSize
- the disk cache size in megabytespublic void setDiskPath(java.lang.String pDiskPath)
pDiskPath
- the absolute path to the root of the disk cache directorypublic void setCleanInterval(int pCleanInterval)
pCleanInterval
- number of seconds between cache cleaningspublic void setPingInterval(int pPingInterval)
pPingInterval
- number of seconds between cache death detectionpublic void setLogger(java.lang.String pLogger)
pLogger
- an object extends CacheLoggerpublic void setLogSeverity(int severity)
severity
- log severitypublic void setLogFileName(java.lang.String pLogFileName)
pLogFileName
- the log file name for the DefaultCacheLogger.public void addCacheAddr(java.net.InetAddress ipAddr, int port)
ipAddr
- the inet addressport
- the portpublic void addCacheAddr(java.net.InetAddress ipAddr, int port, boolean replace)
ipAddr
- the inet addressport
- the portreplace
- if the IP address already exists. The previous address
would be discarded.public java.util.Enumeration getCacheAddrs()
public java.lang.String getAddrListString()
public java.lang.String toString()
toString
in class java.lang.Object
|
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |