|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
This is an interface for defining Jetspeed objects that may be cached in the object cache.
Each such object must be able to prodive a caching handle that will uniquely identify it within the cache system
Method Summary | |
java.lang.Long |
getExpirationMillis()
Return the expiration time in milliseconds. |
Expire |
getExpire()
Used by a Cacheable object to determine when it should expire itself from the cache. |
java.lang.String |
getHandle()
Deprecated. cacheable classes should now implement a static getHandle(config) method |
boolean |
isCacheable()
Return true if this Cacheable is allowed to be cached. |
void |
setCacheable(boolean cacheable)
Set this cacheable status. |
void |
setCachedObject(org.apache.turbine.services.cache.CachedObject co)
This allows the associated CachedObject to be known. |
void |
setExpirationMillis(long expirationMillis)
Set the expiration time in milliseconds. |
void |
setHandle(java.lang.String handle)
Deprecated. cacheable classes should now implement a static getHandle(config) method |
Method Detail |
public boolean isCacheable()
TRUE
if object is cachableFALSE
if object is not cacheablepublic void setCacheable(boolean cacheable)
cacheable
- Set the cacheability of the objectpublic Expire getExpire()
public java.lang.String getHandle()
Used by the cache to get a unique reference on what you want to add and then retrieve in the future from the cache
Most implementations should just call the CacheHandleManager with the given params within the implementation and just return this.
public void setHandle(java.lang.String handle)
Set the handle for this Cacheable.
Note that factories should call setHandle() so that getHandle() always returns a value correctly.
public java.lang.Long getExpirationMillis()
public void setExpirationMillis(long expirationMillis)
expirationMillis
- Set expiration in millispublic void setCachedObject(org.apache.turbine.services.cache.CachedObject co)
co
is to set the expiration time
co
- Handle to the CachedObject
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |