Class AbstractDiskCacheAttributes
java.lang.Object
org.apache.commons.jcs3.auxiliary.AbstractAuxiliaryCacheAttributes
org.apache.commons.jcs3.auxiliary.disk.AbstractDiskCacheAttributes
- All Implemented Interfaces:
Serializable,Cloneable,AuxiliaryCacheAttributes,IDiskCacheAttributes
- Direct Known Subclasses:
BlockDiskCacheAttributes,IndexedDiskCacheAttributes,JDBCDiskCacheAttributes
public abstract class AbstractDiskCacheAttributes
extends AbstractAuxiliaryCacheAttributes
implements IDiskCacheAttributes
This has common attributes that any conceivable disk cache would need.
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from interface org.apache.commons.jcs3.auxiliary.disk.behavior.IDiskCacheAttributes
IDiskCacheAttributes.DiskLimitType -
Field Summary
Fields inherited from interface org.apache.commons.jcs3.auxiliary.disk.behavior.IDiskCacheAttributes
MAX_PURGATORY_SIZE_DEFAULT -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionGets the diskPath attribute of the attributes objectintGets the maxKeySize attribute of the DiskCacheAttributes objectintGet the amount of time in seconds we will wait for elements to move to disk during shutdown for a particular region.booleanIf this is true then remove all is not prohibited.voidsetAllowRemoveAll(boolean allowRemoveAll) If this is false, then remove all requests will not be honored.voidsetDiskLimitType(IDiskCacheAttributes.DiskLimitType diskLimitType) set the type of the limit of the cache sizevoidsetDiskLimitTypeName(String diskLimitTypeName) Translates and stores String values of DiskLimitType Allowed values: "COUNT" and "SIZE"voidsetDiskPath(File diskPath) Sets the diskPath attribute of the DiskCacheAttributes objectvoidsetDiskPath(String path) Sets the diskPath attribute of the DiskCacheAttributes objectvoidsetMaxPurgatorySize(int maxPurgatorySize) Sets the maxPurgatorySize attribute of the DiskCacheAttributes objectvoidsetShutdownSpoolTimeLimit(int shutdownSpoolTimeLimit) Sets the amount of time in seconds we will wait for elements to move to disk during shutdown for a particular region.toString()Includes the common attributes for a debug message.Methods inherited from class org.apache.commons.jcs3.auxiliary.AbstractAuxiliaryCacheAttributes
clone, getCacheName, getEventQueuePoolName, getEventQueueType, getName, setCacheName, setEventQueuePoolName, setEventQueueType, setNameMethods inherited from class java.lang.Object
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface org.apache.commons.jcs3.auxiliary.AuxiliaryCacheAttributes
clone, getCacheName, getEventQueuePoolName, getEventQueueType, getName, setCacheName, setEventQueuePoolName, setEventQueueType, setName
-
Constructor Details
-
AbstractDiskCacheAttributes
public AbstractDiskCacheAttributes()
-
-
Method Details
-
setDiskPath
Sets the diskPath attribute of the DiskCacheAttributes object- Specified by:
setDiskPathin interfaceIDiskCacheAttributes- Parameters:
path- The new diskPath value
-
setDiskPath
Sets the diskPath attribute of the DiskCacheAttributes object- Parameters:
diskPath- The new diskPath value
-
getDiskPath
Gets the diskPath attribute of the attributes object- Specified by:
getDiskPathin interfaceIDiskCacheAttributes- Returns:
- The diskPath value
-
getMaxPurgatorySize
Gets the maxKeySize attribute of the DiskCacheAttributes object- Specified by:
getMaxPurgatorySizein interfaceIDiskCacheAttributes- Returns:
- The maxPurgatorySize value
-
setMaxPurgatorySize
Sets the maxPurgatorySize attribute of the DiskCacheAttributes object- Specified by:
setMaxPurgatorySizein interfaceIDiskCacheAttributes- Parameters:
maxPurgatorySize- The new maxPurgatorySize value
-
getShutdownSpoolTimeLimit
Get the amount of time in seconds we will wait for elements to move to disk during shutdown for a particular region.- Specified by:
getShutdownSpoolTimeLimitin interfaceIDiskCacheAttributes- Returns:
- the time in seconds.
-
setShutdownSpoolTimeLimit
Sets the amount of time in seconds we will wait for elements to move to disk during shutdown for a particular region.This is how long we give the event queue to empty.
The default is 60 seconds.
- Specified by:
setShutdownSpoolTimeLimitin interfaceIDiskCacheAttributes- Parameters:
shutdownSpoolTimeLimit- the time in seconds
-
setAllowRemoveAll
Description copied from interface:IDiskCacheAttributesIf this is false, then remove all requests will not be honored.This provides a safety mechanism for the persistent store.
- Specified by:
setAllowRemoveAllin interfaceIDiskCacheAttributes- Parameters:
allowRemoveAll- The allowRemoveAll to set.
-
isAllowRemoveAll
Description copied from interface:IDiskCacheAttributesIf this is true then remove all is not prohibited.- Specified by:
isAllowRemoveAllin interfaceIDiskCacheAttributes- Returns:
- Returns the allowRemoveAll.
-
toString
Includes the common attributes for a debug message. -
setDiskLimitType
Description copied from interface:IDiskCacheAttributesset the type of the limit of the cache size- Specified by:
setDiskLimitTypein interfaceIDiskCacheAttributes- Parameters:
diskLimitType- COUNT - limit by count of the elements, SIZE, limit by sum of element's size
-
setDiskLimitTypeName
Description copied from interface:IDiskCacheAttributesTranslates and stores String values of DiskLimitType Allowed values: "COUNT" and "SIZE"- Specified by:
setDiskLimitTypeNamein interfaceIDiskCacheAttributes
-
getDiskLimitType
- Specified by:
getDiskLimitTypein interfaceIDiskCacheAttributes- Returns:
- active DiskLimitType
-