接口 CacheAnnotationParser
- 所有已知实现类:
SpringCacheAnnotationParser
public interface CacheAnnotationParser
Strategy interface for parsing known caching annotation types.AnnotationCacheOperationSource
delegates to such parsers for supporting specific annotation types such as Spring's ownCacheable
,CachePut
andCacheEvict
.- 从以下版本开始:
- 3.1
- 作者:
- Costin Leau, Stephane Nicoll
- 另请参阅:
AnnotationCacheOperationSource
,SpringCacheAnnotationParser
方法概要
所有方法 实例方法 抽象方法 修饰符和类型 方法 说明 Collection<CacheOperation>
parseCacheAnnotations(Class<?> type)
Parse the cache definition for the given class, based on an annotation type understood by this parser.Collection<CacheOperation>
parseCacheAnnotations(Method method)
Parse the cache definition for the given method, based on an annotation type understood by this parser.
方法详细资料
parseCacheAnnotations
Collection<CacheOperation> parseCacheAnnotations(Class<?> type)
Parse the cache definition for the given class, based on an annotation type understood by this parser.This essentially parses a known cache annotation into Spring's metadata attribute class. Returns
null
if the class is not cacheable.- 参数:
type
- the annotated class- 返回:
- the configured caching operation, or
null
if none found - 另请参阅:
AnnotationCacheOperationSource.findCacheOperations(Class)
parseCacheAnnotations
Collection<CacheOperation> parseCacheAnnotations(Method method)
Parse the cache definition for the given method, based on an annotation type understood by this parser.This essentially parses a known cache annotation into Spring's metadata attribute class. Returns
null
if the method is not cacheable.- 参数:
method
- the annotated method- 返回:
- the configured caching operation, or
null
if none found - 另请参阅:
AnnotationCacheOperationSource.findCacheOperations(Method)