Interface CacheResultPostProcessor
-
- All Superinterfaces:
org.springframework.core.Ordered
public interface CacheResultPostProcessor extends org.springframework.core.OrderedImplementations can post process results returned from the cache before they are returned from the call toCacheStateManager.computeIfAbsent(Supplier, CacheInfo)orCacheStateManager.computeIfAbsent(Function, ImperativeListCacheInfo). This is commonly used to apply additional handling, like sorting.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default intgetOrder()<P> Ppost(P result, boolean isImperativeProcessing)Post process the result.
-
-
-
Method Detail
-
post
<P> P post(P result, boolean isImperativeProcessing)Post process the result.- Type Parameters:
P- The result type- Parameters:
result- The input to processisImperativeProcessing- Whether or not this post process is the result of an imperative based cache call. SeeCacheStateManager.computeIfAbsent(Function, ImperativeListCacheInfo).- Returns:
- The processed result
-
getOrder
default int getOrder()
- Specified by:
getOrderin interfaceorg.springframework.core.Ordered
-
-