Package com.google.common.cache
Class CacheLoader.FunctionToCacheLoader<K,V>
- java.lang.Object
-
- com.google.common.cache.CacheLoader<K,V>
-
- com.google.common.cache.CacheLoader.FunctionToCacheLoader<K,V>
-
- All Implemented Interfaces:
java.io.Serializable
- Enclosing class:
- CacheLoader<K,V>
private static final class CacheLoader.FunctionToCacheLoader<K,V> extends CacheLoader<K,V> implements java.io.Serializable
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from class com.google.common.cache.CacheLoader
CacheLoader.InvalidCacheLoadException, CacheLoader.UnsupportedLoadingOperationException
-
-
Field Summary
Fields Modifier and Type Field Description private Function<K,V>
computingFunction
private static long
serialVersionUID
-
Constructor Summary
Constructors Constructor Description FunctionToCacheLoader(Function<K,V> computingFunction)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description V
load(K key)
Computes or retrieves the value corresponding tokey
.-
Methods inherited from class com.google.common.cache.CacheLoader
asyncReloading, from, from, loadAll, reload
-
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
-
Method Detail
-
load
public V load(K key)
Description copied from class:CacheLoader
Computes or retrieves the value corresponding tokey
.- Specified by:
load
in classCacheLoader<K,V>
- Parameters:
key
- the non-null key whose value should be loaded- Returns:
- the value associated with
key
; must not be null
-
-