K
- keyV
- valuepublic abstract class AbstractCacheMap<K,V> extends Object implements Cache<K,V>
Modifier and Type | Class and Description |
---|---|
static class |
AbstractCacheMap.CachedValue |
Constructor and Description |
---|
AbstractCacheMap(int size,
long timeToLiveInMillis,
long maxIdleInMillis) |
Modifier and Type | Method and Description |
---|---|
void |
clear() |
boolean |
containsKey(Object key) |
boolean |
containsValue(Object value) |
protected AbstractCacheMap.CachedValue |
create(K key,
V value,
long ttl,
long maxIdleTime) |
Set<Map.Entry<K,V>> |
entrySet() |
V |
get(Object key) |
boolean |
isEmpty() |
Set<K> |
keySet() |
protected abstract void |
onMapFull() |
protected void |
onValueCreate(AbstractCacheMap.CachedValue entry) |
protected void |
onValueRead(AbstractCacheMap.CachedValue value) |
protected void |
onValueRemove(AbstractCacheMap.CachedValue value) |
V |
put(K key,
V value) |
V |
put(K key,
V value,
long ttl,
TimeUnit ttlUnit,
long maxIdleTime,
TimeUnit maxIdleUnit) |
void |
putAll(Map<? extends K,? extends V> m) |
protected V |
readValue(AbstractCacheMap.CachedValue entry) |
V |
remove(Object key) |
int |
size() |
Collection<V> |
values() |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
compute, computeIfAbsent, computeIfPresent, equals, forEach, getOrDefault, hashCode, merge, putIfAbsent, remove, replace, replace, replaceAll
public AbstractCacheMap(int size, long timeToLiveInMillis, long maxIdleInMillis)
protected void onValueRead(AbstractCacheMap.CachedValue value)
protected void onValueRemove(AbstractCacheMap.CachedValue value)
public boolean containsKey(Object key)
containsKey
in interface Map<K,V>
public boolean containsValue(Object value)
containsValue
in interface Map<K,V>
protected V readValue(AbstractCacheMap.CachedValue entry)
public V put(K key, V value, long ttl, TimeUnit ttlUnit, long maxIdleTime, TimeUnit maxIdleUnit)
protected AbstractCacheMap.CachedValue create(K key, V value, long ttl, long maxIdleTime)
protected void onValueCreate(AbstractCacheMap.CachedValue entry)
protected abstract void onMapFull()
Copyright © 2014–2017 The Redisson Project. All rights reserved.