Interface ResultCache<K,T>
-
- Type Parameters:
K
-T
-
- All Superinterfaces:
Clearable
- All Known Implementing Classes:
LRUResultCache
public interface ResultCache<K,T> extends Clearable
- Since:
- 4.0.0
- Author:
- Florian Kleedorfer
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
bypassForCurrentThread()
Calling this method instructs the cache to returnnull
to all#get(K)
calls and ignore any#put(K, T)
calls from the current thread until the cache is cleared.T
get(K key)
void
put(K key, T cachedObject)
-
Methods inherited from interface org.eclipse.rdf4j.spring.resultcache.Clearable
clearCachedResults, markDirty
-
-
-
-
Method Detail
-
bypassForCurrentThread
void bypassForCurrentThread()
Calling this method instructs the cache to returnnull
to all#get(K)
calls and ignore any#put(K, T)
calls from the current thread until the cache is cleared. Context: after a write operation on a connection (which is assumed to be handled exclusively by a dedicated thread), the local cache must be cleared and the global cache bypassed until the connection is returned.
-
-