注释类型 EnableMethodCache
@Target(TYPE)
@Retention(RUNTIME)
@Documented
@Import({CommonConfiguration.class,ConfigSelector.class})
public @interface EnableMethodCache
Created on 2016/11/16.
-
必需元素概要
所需元素 -
可选元素概要
可选元素修饰符和类型可选元素说明org.springframework.context.annotation.AdviceModeIndicate how caching advice should be applied.intIndicate the ordering of the execution of the caching advisor when multiple advices are applied at a specific joinpoint.booleanIndicate whether subclass-based (CGLIB) proxies are to be created as opposed to standard Java interface-based proxies.
-
元素详细资料
-
basePackages
String[] basePackages
-
-
-
proxyTargetClass
boolean proxyTargetClassIndicate whether subclass-based (CGLIB) proxies are to be created as opposed to standard Java interface-based proxies. The default isfalse. Applicable only ifmode()is set toAdviceMode.PROXY.Note that setting this attribute to
truewill affect all Spring-managed beans requiring proxying, not just those marked with@Cacheable. For example, other beans marked with Spring's@Transactionalannotation will be upgraded to subclass proxying at the same time. This approach has no negative impact in practice unless one is explicitly expecting one type of proxy vs another, e.g. in tests.- 默认值:
- false
-
mode
org.springframework.context.annotation.AdviceMode modeIndicate how caching advice should be applied. The default isAdviceMode.PROXY.- 另请参阅:
-
AdviceMode
- 默认值:
- PROXY
-
order
int orderIndicate the ordering of the execution of the caching advisor when multiple advices are applied at a specific joinpoint. The default isOrdered.LOWEST_PRECEDENCE.- 默认值:
- 2147483647
-