public class OnHeapPollingCache<K,V> extends Object implements PollingCache<K,V>
| Modifier and Type | Class and Description |
|---|---|
static class |
OnHeapPollingCache.OnHeapPollingCacheProvider<K,V> |
| Constructor and Description |
|---|
OnHeapPollingCache(Iterable<Map.Entry<K,V>> entries) |
| Modifier and Type | Method and Description |
|---|---|
void |
close()
close and clean the resources used by the cache
|
V |
get(K key) |
List<K> |
getKeys(V value) |
public V get(K key)
get in interface PollingCache<K,V>key - Given key to lookup its value from the cache.key or null if no value exist.public List<K> getKeys(V value)
getKeys in interface PollingCache<K,V>value - Given value to reverse lookup its keys.List of keys associated to the given value otherwise Collections.EmptyListpublic void close()
PollingCacheclose in interface PollingCache<K,V>Copyright © 2011–2017. All rights reserved.