public interface CacheStrategy<T,CacheType,QueryType extends Query<T>>
Modifier and Type | Method and Description |
---|---|
byte[] |
computeCacheKey(QueryType query)
Computes the cache key for the given query
|
com.fasterxml.jackson.core.type.TypeReference<CacheType> |
getCacheObjectClazz()
Returns the class type of what is used in the cache
|
com.google.common.base.Function<T,CacheType> |
prepareForCache()
Returns a function that converts from the QueryType's result type to something cacheable.
|
com.google.common.base.Function<CacheType,T> |
pullFromCache()
A function that does the inverse of the operation that the function prepareForCache returns
|
byte[] computeCacheKey(QueryType query)
query
- the query to compute a cache key forcom.fasterxml.jackson.core.type.TypeReference<CacheType> getCacheObjectClazz()
com.google.common.base.Function<T,CacheType> prepareForCache()
Copyright © 2011–2016. All rights reserved.