CacheRefType - the type of the key used to access
AsyncDataLink instances in the cache. In case the
CachedLinkContainer is being used by an AsyncDataQuery,
it can typically be the input used to
create the
AsyncDataLink.public interface CachedLinkContainer<CacheRefType>
AsyncDataLink instances.
How AsyncDataLink instances are added to the cache is completely
implementation dependent, this interface only defines methods for removing
AsyncDataLink instances from the cache.
This interface is intended to be used by AsyncDataQuery
implementations caching AsyncDataLink instances.
| Modifier and Type | Method and Description |
|---|---|
Collection<CacheRefType> |
clearCache()
Removes every
AsyncDataLink instances from the cache currently
cached by this query. |
boolean |
removeFromCache(CacheRefType arg)
Removes a cached
AsyncDataLink which was cached by the specified
input. |
Collection<CacheRefType> clearCache()
AsyncDataLink instances from the cache currently
cached by this query. A subsequent retrieval request from the cache will
fail to find any required AsyncDataLink, therefore causing the
implementation to fallback to recreate the required AsyncDataLink
instance.AsyncDataLink instances
were cached before calling this method. This method never returns
null.boolean removeFromCache(CacheRefType arg)
AsyncDataLink which was cached by the specified
input. A subsequent retrieval request from the cache requiring the
AsyncDataLink associated with the specified input will fail,
therefore causing the implementation to fallback to recreate the required
AsyncDataLink instance.arg - the input for which the associated AsyncDataLink is to
be removed from the cache. This argument can be null.true if an AsyncDataLink instance was cached for
the specified input, false otherwise. If this method returns
false, it did nothing because there was no
AsyncDataLink associated with the given input in the cache.