Class PeekableTouchableCaffeineMap<K,V>
java.lang.Object
org.infinispan.commons.util.AbstractDelegatingMap<K, InternalCacheEntry<K,V>>
org.infinispan.commons.util.AbstractDelegatingConcurrentMap<K, InternalCacheEntry<K,V>>
org.infinispan.container.impl.PeekableTouchableCaffeineMap<K,V>
- All Implemented Interfaces:
ConcurrentMap<K, InternalCacheEntry<K,V>>, Map<K, InternalCacheEntry<K, V>>, PeekableTouchableMap<K, V>
public class PeekableTouchableCaffeineMap<K,V>
extends AbstractDelegatingConcurrentMap<K, InternalCacheEntry<K,V>>
implements PeekableTouchableMap<K,V>
-
Nested Class Summary
-
Constructor Summary
ConstructorsConstructorDescriptionPeekableTouchableCaffeineMap(com.github.benmanes.caffeine.cache.Cache<K, InternalCacheEntry<K, V>> cache) -
Method Summary
Modifier and TypeMethodDescriptionvoidcleanUp()protected ConcurrentMap<K, InternalCacheEntry<K, V>> delegate()Peaks at a value for the given key.com.github.benmanes.caffeine.cache.Policy<K, InternalCacheEntry<K, V>> policy()voidvoidtouchAll(long currentTimeMillis) Touches all entries in the map setting the recency timestamps for both expiration eviction appropriately.Methods inherited from class AbstractDelegatingMap
clear, compute, computeIfAbsent, computeIfPresent, containsKey, containsValue, entrySet, forEach, get, getOrDefault, isEmpty, keySet, merge, put, putAll, putIfAbsent, remove, remove, replace, replace, replaceAll, size, valuesMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface ConcurrentMap
compute, computeIfAbsent, computeIfPresent, forEach, getOrDefault, merge, putIfAbsent, remove, replace, replace, replaceAllMethods inherited from interface Map
clear, containsKey, containsValue, entrySet, equals, get, hashCode, isEmpty, keySet, put, putAll, remove, size, valuesMethods inherited from interface PeekableTouchableMap
putNoReturn, touchKey
-
Constructor Details
-
PeekableTouchableCaffeineMap
public PeekableTouchableCaffeineMap(com.github.benmanes.caffeine.cache.Cache<K, InternalCacheEntry<K, V>> cache)
-
-
Method Details
-
delegate
- Specified by:
delegatein classAbstractDelegatingConcurrentMap<K, InternalCacheEntry<K,V>>
-
peek
Description copied from interface:PeekableTouchableMapPeaks at a value for the given key. Note that this does not update any expiration or eviction information when this is performed on the map, unlike the get method.- Specified by:
peekin interfacePeekableTouchableMap<K,V> - Parameters:
key- The key to find the value for- Returns:
- The value mapping to this key
-
touchAll
public void touchAll(long currentTimeMillis) Description copied from interface:PeekableTouchableMapTouches all entries in the map setting the recency timestamps for both expiration eviction appropriately.- Specified by:
touchAllin interfacePeekableTouchableMap<K,V> - Parameters:
currentTimeMillis- the recency timestamp to set
-
removeAll
-
policy
-
cleanUp
public void cleanUp()
-