public class NamedCaffeineCache<K,V>
extends java.lang.Object
implements com.github.benmanes.caffeine.cache.AsyncCache<K,V>
Constructor and Description |
---|
NamedCaffeineCache(java.lang.String name,
com.github.benmanes.caffeine.cache.AsyncCache<K,V> cache) |
Modifier and Type | Method and Description |
---|---|
java.util.concurrent.ConcurrentMap<K,java.util.concurrent.CompletableFuture<V>> |
asMap() |
java.util.concurrent.CompletableFuture<V> |
get(K key,
java.util.function.BiFunction<? super K,java.util.concurrent.Executor,java.util.concurrent.CompletableFuture<V>> mappingFunction) |
java.util.concurrent.CompletableFuture<V> |
get(K key,
java.util.function.Function<? super K,? extends V> mappingFunction) |
java.util.concurrent.CompletableFuture<java.util.Map<K,V>> |
getAll(java.lang.Iterable<? extends K> keys,
java.util.function.BiFunction<java.lang.Iterable<? extends K>,java.util.concurrent.Executor,java.util.concurrent.CompletableFuture<java.util.Map<K,V>>> mappingFunction) |
java.util.concurrent.CompletableFuture<java.util.Map<K,V>> |
getAll(java.lang.Iterable<? extends K> keys,
java.util.function.Function<java.lang.Iterable<? extends K>,java.util.Map<K,V>> mappingFunction) |
java.util.concurrent.CompletableFuture<V> |
getIfPresent(java.lang.Object key) |
java.lang.String |
getName() |
void |
put(K key,
java.util.concurrent.CompletableFuture<V> value) |
com.github.benmanes.caffeine.cache.Cache<K,V> |
synchronous() |
public java.lang.String getName()
@CheckForNull public java.util.concurrent.CompletableFuture<V> getIfPresent(@Nonnull java.lang.Object key)
@CheckForNull public java.util.concurrent.CompletableFuture<V> get(@Nonnull K key, @Nonnull java.util.function.Function<? super K,? extends V> mappingFunction)
@Nonnull public java.util.concurrent.CompletableFuture<V> get(@Nonnull K key, @Nonnull java.util.function.BiFunction<? super K,java.util.concurrent.Executor,java.util.concurrent.CompletableFuture<V>> mappingFunction)
@Nonnull public java.util.concurrent.CompletableFuture<java.util.Map<K,V>> getAll(@Nonnull java.lang.Iterable<? extends K> keys, @Nonnull java.util.function.Function<java.lang.Iterable<? extends K>,java.util.Map<K,V>> mappingFunction)
@Nonnull public java.util.concurrent.CompletableFuture<java.util.Map<K,V>> getAll(@Nonnull java.lang.Iterable<? extends K> keys, @Nonnull java.util.function.BiFunction<java.lang.Iterable<? extends K>,java.util.concurrent.Executor,java.util.concurrent.CompletableFuture<java.util.Map<K,V>>> mappingFunction)
@Nonnull public java.util.concurrent.ConcurrentMap<K,java.util.concurrent.CompletableFuture<V>> asMap()