Class ConfigurationClassPostProcessor
java.lang.Object
org.springframework.context.annotation.ConfigurationClassPostProcessor
- All Implemented Interfaces:
BeanFactoryInitializationAotProcessor,BeanRegistrationAotProcessor,Aware,BeanClassLoaderAware,BeanFactoryPostProcessor,BeanDefinitionRegistryPostProcessor,ApplicationStartupAware,EnvironmentAware,ResourceLoaderAware,Ordered,PriorityOrdered
public class ConfigurationClassPostProcessor
extends Object
implements BeanDefinitionRegistryPostProcessor, BeanRegistrationAotProcessor, BeanFactoryInitializationAotProcessor, PriorityOrdered, ResourceLoaderAware, ApplicationStartupAware, BeanClassLoaderAware, EnvironmentAware
BeanFactoryPostProcessor used for bootstrapping processing of
@Configuration classes.
Registered by default when using <context:annotation-config/> or
<context:component-scan/>. Otherwise, may be declared manually as
with any other BeanFactoryPostProcessor.
This post processor is priority-ordered as it is important that any
@Bean methods declared in @Configuration classes have
their corresponding bean definitions registered before any other
BeanFactoryPostProcessor executes.
- Since:
- 3.0
- Author:
- Chris Beams, Juergen Hoeller, Phillip Webb, Sam Brannen
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final AnnotationBeanNameGeneratorABeanNameGeneratorusing fully qualified class names as default bean names.Fields inherited from interface org.springframework.beans.factory.aot.BeanRegistrationAotProcessor
IGNORE_REGISTRATION_ATTRIBUTEFields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidPost-processes a BeanFactory in search of Configuration class BeanDefinitions; any candidates are then enhanced by aConfigurationClassEnhancer.intgetOrder()Get the order value of this object.voidDerive further bean definitions from the configuration classes in the registry.voidpostProcessBeanFactory(ConfigurableListableBeanFactory beanFactory) Prepare the Configuration classes for servicing bean requests at runtime by replacing them with CGLIB-enhanced subclasses.processAheadOfTime(ConfigurableListableBeanFactory beanFactory) Process the givenConfigurableListableBeanFactoryinstance ahead-of-time and return a contribution ornull.