public class MemoryCache extends Cache
Constructor and Description |
---|
MemoryCache() |
Modifier and Type | Method and Description |
---|---|
void |
clear()
Clears the cache by effectively removing all cached data.
|
boolean |
contains(java.lang.String cacheEntryName)
Checks if the cache contains an entry with the given name.
|
boolean |
isExpired(java.lang.String cacheEntryName)
Checks if the specified entry is expired.
|
java.io.InputStream |
load(java.lang.String cacheEntryName)
Loads the specified entry from the cache and returns an InputStream to be read from.
|
void |
remove(java.lang.String cacheEntryName)
Removes the specified entry from the cache if available.
|
void |
store(java.lang.String cacheEntryName,
java.io.InputStream inputStream,
long expirationDate)
Stores a request in the cache.
|
createCacheEntryName, getExpirationPolicy, setExpirationPolicy, setHashCacheEntryNames
public boolean contains(java.lang.String cacheEntryName)
Cache
public java.io.InputStream load(java.lang.String cacheEntryName)
Cache
null
if the cache does not contain the specified cacheEntryName.public void remove(java.lang.String cacheEntryName)
Cache
public void store(java.lang.String cacheEntryName, java.io.InputStream inputStream, long expirationDate)
Cache
public boolean isExpired(java.lang.String cacheEntryName)
Cache