K - Type of the cache key.T - Type of the result.public abstract class AbstractCacheElementProvider<K extends CacheKey,T extends Serializable> extends Object implements CacheElementProvider<K,T>
ETERNAL_TIME_TO_LIVE| Constructor and Description | 
|---|
AbstractCacheElementProvider(String contentType,
                            int timeToLive)
Constructor. 
 | 
| Modifier and Type | Method and Description | 
|---|---|
String | 
getContentType()
Returns a unique string naming the content type of the elements provided by this provider
 (e.g. 
 | 
int | 
getTimeToLive()
Returns the time in seconds describing how long a provided element will be cached without
 expiring (when it is not replaced manually). 
 | 
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitloadpublic AbstractCacheElementProvider(String contentType, int timeToLive)
contentType - See CacheElementProvider.getContentType().timeToLive - See CacheElementProvider.getTimeToLive().public String getContentType()
getContentType in interface CacheElementProvider<K extends CacheKey,T extends Serializable>public int getTimeToLive()
CacheElementProvider.ETERNAL_TIME_TO_LIVE when the
 element should never expire.getTimeToLive in interface CacheElementProvider<K extends CacheKey,T extends Serializable>Copyright © 2019 Communote team. All rights reserved.