Package org.cache2k.io
Interface AsyncCacheLoader.Callback<V>
-
- All Superinterfaces:
EventListener
- Enclosing interface:
- AsyncCacheLoader<K,V>
public static interface AsyncCacheLoader.Callback<V> extends EventListener
Callback for async cache load.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
onLoadFailure(Throwable t)
Called if a failure happened.void
onLoadSuccess(V value)
Called to provide the loaded value to be stored in the cache.
-
-
-
Method Detail
-
onLoadSuccess
void onLoadSuccess(V value)
Called to provide the loaded value to be stored in the cache.- Throws:
IllegalStateException
- if the callback was already made
-
onLoadFailure
void onLoadFailure(Throwable t)
Called if a failure happened. The exception is propagated to the clients accessing the associated key.- Throws:
IllegalStateException
- if the callback was already made
-
-