Interface Cache<K,V>
- Type Parameters:
K- the key typeV- the value type
public interface Cache<K,V>
A level-one cache of server-side state.
- Author:
- Paul Ferraro
-
Method Summary
Modifier and TypeMethodDescriptioncomputeIfAbsent(K key, BiFunction<K, Runnable, V> factory) Returns the value associated with the specified key from this cache, generating it from the specified function, if necessary.keySet()Returns the set of keys of this cache.
-
Method Details
-
computeIfAbsent
Returns the value associated with the specified key from this cache, generating it from the specified function, if necessary.- Parameters:
key- a key by which the value may be referencedfactory- a factory for creating the value if it does not already exist within this context.- Returns:
- the value, obtained from this context, or generated from the specified factory.
-
keySet
-