@ThreadSafe public final class BoundedCache<K,V> extends Object
When the cache is full, batch eviction of random values will be performed, with a default evictionBatchSize of 10.
The user can configure the maximum size of the cache, which is set to a default of 150.
Keys must not be null, otherwise an error will be thrown. Null values are not cached.
| Modifier and Type | Class and Description |
|---|---|
static class |
BoundedCache.Builder<K,V> |
public V get(K key)
BoundedCache.Builder.mappingFunction(Function).public static <K,V> BoundedCache.Builder builder()