protected abstract class EhcacheBase.Jsr107CacheBase extends java.lang.Object implements Jsr107Cache<K,V>
Modifier | Constructor and Description |
---|---|
protected |
Jsr107CacheBase() |
Modifier and Type | Method and Description |
---|---|
java.util.Map<K,V> |
getAll(java.util.Set<? extends K> keys)
Get all mappings for the provided set of keys
|
V |
getNoLoader(K key)
Perform a cache get that does not make use of any configured loader
|
void |
loadAll(java.util.Set<? extends K> keys,
boolean replaceExistingValues,
java.util.function.Function<java.lang.Iterable<? extends K>,java.util.Map<K,V>> loadFunction)
Invokes the cache loader for the given keys, optionally replacing the cache mappings with the loaded values.
|
boolean |
remove(K key)
Removes the mapping associated with the provided key.
|
void |
removeAll()
Removes all mapping from this cache.
|
java.util.Iterator<Cache.Entry<K,V>> |
specIterator()
Return an iterator that follows the JSR 107 spec.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
compute, getAndPut, getAndRemove
public void loadAll(java.util.Set<? extends K> keys, boolean replaceExistingValues, java.util.function.Function<java.lang.Iterable<? extends K>,java.util.Map<K,V>> loadFunction)
Jsr107Cache
loadAll
in interface Jsr107Cache<K,V>
keys
- the keys to laod value forreplaceExistingValues
- whether to update cache mappingsloadFunction
- the function performing the loadingpublic java.util.Iterator<Cache.Entry<K,V>> specIterator()
Jsr107Cache
specIterator
in interface Jsr107Cache<K,V>
public V getNoLoader(K key)
Jsr107Cache
getNoLoader
in interface Jsr107Cache<K,V>
key
- the keypublic java.util.Map<K,V> getAll(java.util.Set<? extends K> keys)
Jsr107Cache
getAll
in interface Jsr107Cache<K,V>
keys
- the keys to retrievepublic boolean remove(K key)
Jsr107Cache
remove
in interface Jsr107Cache<K,V>
key
- the key to lookuptrue
if a mapping was removed, false
otherwisepublic void removeAll()
Jsr107Cache
removeAll
in interface Jsr107Cache<K,V>