K - type of the keysV - type of the valuespublic interface MemoizeCache<K,V>
| Modifier and Type | Interface and Description | 
|---|---|
| static interface  | MemoizeCache.ValueProvider<K,V>Represents a provider used to create value | 
| Modifier and Type | Method and Description | 
|---|---|
| void | cleanUpNullReferences()Invoked when some of the held SoftReferences have been evicted by the garbage collector and so should be removed from the cache. | 
| V | get(K key)Gets a value from the cache | 
| V | getAndPut(K key,
         MemoizeCache.ValueProvider<? super K,? extends V> valueProvider)Try to get the value from cache. | 
| V | put(K key,
   V value)Associates the specified value with the specified key in the cache. | 
V put(K key, V value)
key - key with which the specified value is to be associatedvalue - value to be associated with the specified keyV get(K key)
key - the key whose associated value is to be returnedV getAndPut(K key, MemoizeCache.ValueProvider<? super K,? extends V> valueProvider)
MemoizeCache.ValueProvider and put it into the cache, at last return the valuekey - void cleanUpNullReferences()