K
- V
- public class MemoryCacheEntity<K,V> extends java.lang.Object implements CacheEntity<K,V>, java.io.Serializable
限定符和类型 | 字段和说明 |
---|---|
private java.util.Map<K,CacheValue<V>> |
cachedMap |
private java.util.concurrent.locks.ReentrantReadWriteLock |
lock |
protected org.apache.commons.logging.Log |
log |
private static long |
serialVersionUID |
private int |
size |
构造器和说明 |
---|
MemoryCacheEntity() |
限定符和类型 | 方法和说明 |
---|---|
java.util.List<V> |
clear(boolean recycling) |
private java.util.List<V> |
clearCache() |
boolean |
contains(K key) |
V |
get(K key) |
CacheEntity<K,V> |
init(java.lang.String region,
java.util.Properties properties) |
java.util.List<V> |
put(K key,
V value) |
void |
put(K key,
V value,
java.lang.Long expiryInSeconds) |
V |
remove(K key) |
void |
setSize(int size) |
private static final long serialVersionUID
private int size
protected final transient org.apache.commons.logging.Log log
private java.util.Map<K,CacheValue<V>> cachedMap
private java.util.concurrent.locks.ReentrantReadWriteLock lock
public java.util.List<V> clear(boolean recycling)
clear
在接口中 CacheEntity<K,V>
private java.util.List<V> clearCache()
public void setSize(int size)
size
- public boolean contains(K key)
contains
在接口中 CacheEntity<K,V>
public CacheEntity<K,V> init(java.lang.String region, java.util.Properties properties)
init
在接口中 CacheEntity<K,V>