public class Cache
extends java.lang.Object
Constructor and Description |
---|
Cache(CacheStore cacheStore) |
Modifier and Type | Method and Description |
---|---|
void |
clear(java.lang.String key)
Removes the value from the cache associated with the key
|
void |
clearAll()
Clears all the entries in the cache
|
boolean |
entryExists(java.lang.Object key)
Returns if a value is associated with the key
|
java.lang.Object |
get(java.lang.Object key)
Get an object from the cache.
|
boolean |
isCacheEntryStale(java.lang.Object key,
java.util.Calendar updateTime)
Returns whether the object in the cache associated with the key is valid given the last update time of the key
|
java.lang.Object |
put(java.lang.Object key,
java.lang.Object value,
java.util.Calendar modifiedTime)
Put an object in the cache with a key that can be used to retrieve the object later.
|
public Cache(CacheStore cacheStore)
public java.lang.Object put(java.lang.Object key, java.lang.Object value, java.util.Calendar modifiedTime)
key
- Key against which the value is stored in cachevalue
- value to store in the cachepublic java.lang.Object get(java.lang.Object key)
key
- public void clearAll()
public void clear(java.lang.String key)
key
- key associated with the object that has to be removedpublic boolean isCacheEntryStale(java.lang.Object key, java.util.Calendar updateTime)
key
- Key of the object whose validity has to be checkedupdateTime
- Calendar Instance of the update time of thepublic boolean entryExists(java.lang.Object key)
key
- Copyright © 2010 - 2020 Adobe. All Rights Reserved