Package org.springframework.cache.interceptor

# Interface CacheResolver

All Known Implementing Classes:
  `AbstractCacheResolver`, `NamedCacheResolver`, `SimpleCacheResolver`

Functional Interface:
  This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.

@FunctionalInterface public interface CacheResolver
Determine the `Cache` instance(s) to use for an intercepted method invocation.

Implementations must be thread-safe.

Since:
  4.1
Author:
  Stephane Nicoll

## Method Summary

Modifier and Type
Method
Description
`Collection<? extends Cache>`
`resolveCaches(CacheOperationInvocationContext<?> context)`
Return the cache(s) to use for the specified invocation.

## Method Details

### resolveCaches

Collection<? extends Cache> resolveCaches(CacheOperationInvocationContext<?> context)
Return the cache(s) to use for the specified invocation.

Parameters:
  `context` - the context of the particular invocation
Returns:
  the cache(s) to use (never `null`)
Throws:
  `IllegalStateException` - if cache resolution failed