Interface AotContributingBeanPostProcessor
- All Superinterfaces:
BeanPostProcessor
,Ordered
,PriorityOrdered
- All Known Implementing Classes:
AutowiredAnnotationBeanPostProcessor
,CommonAnnotationBeanPostProcessor
,InitDestroyAnnotationBeanPostProcessor
Specialization of a priority ordered
BeanPostProcessor
that
contributes to bean instantiation ahead of time, providing generated code
that is equivalent to its runtime behavior.
Contrary to other bean post processors, implementations of this interface are instantiated at build-time and should not rely on other beans in the context.
- Since:
- 6.0
- Author:
- Stephane Nicoll
-
Field Summary
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
-
Method Summary
Modifier and TypeMethodDescriptioncontribute
(RootBeanDefinition beanDefinition, Class<?> beanType, String beanName) Contribute aBeanInstantiationContribution
for the given bean definition, if applicable.Methods inherited from interface org.springframework.beans.factory.config.BeanPostProcessor
postProcessAfterInitialization, postProcessBeforeInitialization
-
Method Details
-
contribute
@Nullable BeanInstantiationContribution contribute(RootBeanDefinition beanDefinition, Class<?> beanType, String beanName) Contribute aBeanInstantiationContribution
for the given bean definition, if applicable.- Parameters:
beanDefinition
- the merged bean definition for the beanbeanType
- the inferred type of the beanbeanName
- the name of the bean- Returns:
- the contribution to use or
null
if the bean should not be processed
-