public class AdminCacheWeakReference extends Object implements AdminCache
AdminCache based on week references and backgrounded by
AdminCacheFileStore layer. AdminCacheFileStore.| Modifier and Type | Method and Description |
|---|---|
boolean |
contains(String key)
Checked if content is in the cache.
|
<A> A |
get(String key,
Class<A> clazz)
Retrieve data from cache.
|
static AdminCacheWeakReference |
getInstance() |
Date |
lastUpdated(String key)
Date when was cached data last updated.
|
void |
put(String key,
Object data)
Puts data to cache.
|
public <A> A get(String key, Class<A> clazz)
AdminCacheget in interface AdminCachekey - in the cacheclazz - Cache data will be converted to requested type using
appropriate AdminCacheObjectProvidernull if not cachedpublic void put(String key, Object data)
AdminCacheput in interface AdminCachekey - in the cachedata - Cached data will be converted to raw bytes using
appropriate AdminCacheObjectProviderpublic boolean contains(String key)
AdminCachecontains in interface AdminCachekey - in the cachepublic Date lastUpdated(String key)
AdminCachelastUpdated in interface AdminCachekey - in the cacheDate of last update or null if does not exist in cachepublic static AdminCacheWeakReference getInstance()
Copyright © 2017. All rights reserved.