<bean>
) tags. Decoration may also occur based on custom attributes applied to the <bean>
tag. Implementations are free to turn the metadata in the custom tag into as many {@link org.springframework.beans.factory.config.BeanDefinition BeanDefinitions} asrequired and to transform the {@link org.springframework.beans.factory.config.BeanDefinition} of the enclosing<bean>
tag, potentially even returning a completely different {@link org.springframework.beans.factory.config.BeanDefinition} to replace theoriginal.
{@link BeanDefinitionDecorator BeanDefinitionDecorators} should be aware thatthey may be part of a chain. In particular, a {@link BeanDefinitionDecorator} shouldbe aware that a previous {@link BeanDefinitionDecorator} may have replaced theoriginal {@link org.springframework.beans.factory.config.BeanDefinition} with a{@link org.springframework.aop.framework.ProxyFactoryBean} definition allowing forcustom {@link org.aopalliance.intercept.MethodInterceptor interceptors} to be added.
{@link BeanDefinitionDecorator BeanDefinitionDecorators} that wish to add aninterceptor to the enclosing bean should extend {@link org.springframework.aop.config.AbstractInterceptorDrivenBeanDefinitionDecorator}which handles the chaining ensuring that only one proxy is created and that it contains all interceptors from the chain.
The parser locates a {@link BeanDefinitionDecorator} from the{@link NamespaceHandler} for the namespace in which the custom tag resides. @author Rob Harrop @since 2.0 @see NamespaceHandler @see BeanDefinitionParser
|
|
|
|