|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object org.springframework.context.annotation.ConfigurationClassBeanDefinitionReader
class ConfigurationClassBeanDefinitionReader
Reads a given fully-populated set of ConfigurationClass instances, registering bean
definitions with the given BeanDefinitionRegistry
based on its contents.
This class was modeled after the BeanDefinitionReader
hierarchy, but does
not implement/extend any of its artifacts as a set of configuration classes is not a
Resource
.
ConfigurationClassParser
Nested Class Summary | |
---|---|
private static class |
ConfigurationClassBeanDefinitionReader.ConfigurationClassBeanDefinition
RootBeanDefinition marker subclass used to signify that a bean definition
was created from a configuration class as opposed to any other configuration source. |
private static class |
ConfigurationClassBeanDefinitionReader.InvalidConfigurationImportProblem
Configuration classes must be annotated with @Configuration or
declare at least one @Bean method. |
Field Summary | |
---|---|
private static Log |
logger
|
private MetadataReaderFactory |
metadataReaderFactory
|
private ProblemReporter |
problemReporter
|
private BeanDefinitionRegistry |
registry
|
private ResourceLoader |
resourceLoader
|
private SourceExtractor |
sourceExtractor
|
Constructor Summary | |
---|---|
ConfigurationClassBeanDefinitionReader(BeanDefinitionRegistry registry,
SourceExtractor sourceExtractor,
ProblemReporter problemReporter,
MetadataReaderFactory metadataReaderFactory,
ResourceLoader resourceLoader)
Create a new ConfigurationClassBeanDefinitionReader instance that will be used
to populate the given BeanDefinitionRegistry . |
Method Summary | |
---|---|
private void |
doLoadBeanDefinitionForConfigurationClassIfNecessary(ConfigurationClass configClass)
Register the Configuration class itself as a bean definition. |
void |
loadBeanDefinitions(java.util.Set<ConfigurationClass> configurationModel)
Read configurationModel , registering bean definitions with registry
based on its contents. |
private void |
loadBeanDefinitionsForBeanMethod(BeanMethod beanMethod)
Read the given BeanMethod , registering bean definitions
with the BeanDefinitionRegistry based on its contents. |
private void |
loadBeanDefinitionsForConfigurationClass(ConfigurationClass configClass)
Read a particular ConfigurationClass , registering bean definitions for the
class itself, all its Bean methods |
private void |
loadBeanDefinitionsFromImportedResources(java.util.Map<java.lang.String,java.lang.Class<?>> importedResources)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
private static final Log logger
private final BeanDefinitionRegistry registry
private final SourceExtractor sourceExtractor
private final ProblemReporter problemReporter
private final MetadataReaderFactory metadataReaderFactory
private ResourceLoader resourceLoader
Constructor Detail |
---|
public ConfigurationClassBeanDefinitionReader(BeanDefinitionRegistry registry, SourceExtractor sourceExtractor, ProblemReporter problemReporter, MetadataReaderFactory metadataReaderFactory, ResourceLoader resourceLoader)
ConfigurationClassBeanDefinitionReader
instance that will be used
to populate the given BeanDefinitionRegistry
.
problemReporter
- metadataReaderFactory
- Method Detail |
---|
public void loadBeanDefinitions(java.util.Set<ConfigurationClass> configurationModel)
configurationModel
, registering bean definitions with registry
based on its contents.
private void loadBeanDefinitionsForConfigurationClass(ConfigurationClass configClass)
ConfigurationClass
, registering bean definitions for the
class itself, all its Bean
methods
private void doLoadBeanDefinitionForConfigurationClassIfNecessary(ConfigurationClass configClass)
Configuration
class itself as a bean definition.
private void loadBeanDefinitionsForBeanMethod(BeanMethod beanMethod)
BeanMethod
, registering bean definitions
with the BeanDefinitionRegistry based on its contents.
private void loadBeanDefinitionsFromImportedResources(java.util.Map<java.lang.String,java.lang.Class<?>> importedResources)
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |