public class NamedCaffeineCache<K,V>
extends java.lang.Object
implements com.github.benmanes.caffeine.cache.Cache<K,V>
Constructor and Description |
---|
NamedCaffeineCache(java.lang.String name,
com.github.benmanes.caffeine.cache.Cache<K,V> cache) |
Modifier and Type | Method and Description |
---|---|
java.util.concurrent.ConcurrentMap<K,V> |
asMap() |
void |
cleanUp() |
long |
estimatedSize() |
V |
get(K key,
java.util.function.Function<? super K,? extends V> mappingFunction) |
java.util.Map<K,V> |
getAllPresent(java.lang.Iterable<?> keys) |
V |
getIfPresent(java.lang.Object key) |
java.lang.String |
getName() |
void |
invalidate(java.lang.Object key) |
void |
invalidateAll() |
void |
invalidateAll(java.lang.Iterable<?> keys) |
com.github.benmanes.caffeine.cache.Policy<K,V> |
policy() |
void |
put(K key,
V value) |
void |
putAll(java.util.Map<? extends K,? extends V> map) |
com.github.benmanes.caffeine.cache.stats.CacheStats |
stats() |
public java.lang.String getName()
@CheckForNull public V getIfPresent(@Nonnull java.lang.Object key)
@CheckForNull public V get(@Nonnull K key, @Nonnull java.util.function.Function<? super K,? extends V> mappingFunction)
public void invalidate(@Nonnull java.lang.Object key)
public void invalidateAll(@Nonnull java.lang.Iterable<?> keys)
public void invalidateAll()
public long estimatedSize()
@Nonnull public com.github.benmanes.caffeine.cache.stats.CacheStats stats()
public void cleanUp()