Class CaffeinatedGuavaCache<K,V>
- java.lang.Object
-
- com.github.benmanes.caffeine.guava.CaffeinatedGuavaCache<K,V>
-
- All Implemented Interfaces:
com.google.common.cache.Cache<K,V>,java.io.Serializable
- Direct Known Subclasses:
CaffeinatedGuavaLoadingCache
class CaffeinatedGuavaCache<K,V> extends java.lang.Object implements com.google.common.cache.Cache<K,V>, java.io.SerializableA Caffeine-backed cache through a Guava facade.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) static classCaffeinatedGuavaCache.CacheLoaderException
-
Field Summary
Fields Modifier and Type Field Description (package private) Cache<K,V>cache(package private) static longserialVersionUID
-
Constructor Summary
Constructors Constructor Description CaffeinatedGuavaCache(Cache<K,V> cache)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.concurrent.ConcurrentMap<K,V>asMap()voidcleanUp()Vget(K key, java.util.concurrent.Callable<? extends V> valueLoader)com.google.common.collect.ImmutableMap<K,V>getAllPresent(java.lang.Iterable<?> keys)@Nullable VgetIfPresent(java.lang.Object key)voidinvalidate(java.lang.Object key)voidinvalidateAll()voidinvalidateAll(java.lang.Iterable<?> keys)voidput(K key, V value)voidputAll(java.util.Map<? extends K,? extends V> m)longsize()com.google.common.cache.CacheStatsstats()
-
-
-
Field Detail
-
serialVersionUID
static final long serialVersionUID
- See Also:
- Constant Field Values
-
-
Method Detail
-
getIfPresent
public @Nullable V getIfPresent(java.lang.Object key)
-
get
public V get(K key, java.util.concurrent.Callable<? extends V> valueLoader) throws java.util.concurrent.ExecutionException
-
getAllPresent
public com.google.common.collect.ImmutableMap<K,V> getAllPresent(java.lang.Iterable<?> keys)
-
invalidate
public void invalidate(java.lang.Object key)
-
invalidateAll
public void invalidateAll(java.lang.Iterable<?> keys)
-
invalidateAll
public void invalidateAll()
-
stats
public com.google.common.cache.CacheStats stats()
-
-