Class AbstractImportingAnnotationConfiguration<B extends AnnotationBuilder<O>,O>
java.lang.Object
org.springframework.statemachine.config.common.annotation.AbstractImportingAnnotationConfiguration<B,O>
- Type Parameters:
O- The object that used builder returnsB- The type of the builder
- All Implemented Interfaces:
org.springframework.beans.factory.Aware,org.springframework.beans.factory.BeanFactoryAware,org.springframework.context.annotation.ImportBeanDefinitionRegistrar,org.springframework.context.EnvironmentAware
- Direct Known Subclasses:
StateMachineConfiguration,StateMachineFactoryConfiguration
public abstract class AbstractImportingAnnotationConfiguration<B extends AnnotationBuilder<O>,O>
extends Object
implements org.springframework.context.annotation.ImportBeanDefinitionRegistrar, org.springframework.beans.factory.BeanFactoryAware, org.springframework.context.EnvironmentAware
Base class for
Configuration which works on a bean definition level
relying on ImportBeanDefinitionRegistrar phase to register beans.-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionprotected static classAbstractImportingAnnotationConfiguration.BeanDelegatingFactoryBean<T,B extends AnnotationBuilder<O>, O> -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected abstract org.springframework.beans.factory.config.BeanDefinitionbuildBeanDefinition(org.springframework.core.type.AnnotationMetadata importingClassMetadata, Class<? extends Annotation> namedAnnotation) Called to get a bean definition to register.protected abstract List<Class<? extends Annotation>>Gets the annotations specific for this configurer.protected org.springframework.beans.factory.BeanFactoryGets the bean factory.protected org.springframework.core.env.EnvironmentGets the environment.voidregisterBeanDefinitions(org.springframework.core.type.AnnotationMetadata importingClassMetadata, org.springframework.beans.factory.support.BeanDefinitionRegistry registry) voidsetBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) voidsetEnvironment(org.springframework.core.env.Environment environment) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.springframework.context.annotation.ImportBeanDefinitionRegistrar
registerBeanDefinitions
-
Constructor Details
-
AbstractImportingAnnotationConfiguration
public AbstractImportingAnnotationConfiguration()
-
-
Method Details
-
registerBeanDefinitions
public void registerBeanDefinitions(org.springframework.core.type.AnnotationMetadata importingClassMetadata, org.springframework.beans.factory.support.BeanDefinitionRegistry registry) - Specified by:
registerBeanDefinitionsin interfaceorg.springframework.context.annotation.ImportBeanDefinitionRegistrar
-
setBeanFactory
public void setBeanFactory(org.springframework.beans.factory.BeanFactory beanFactory) throws org.springframework.beans.BeansException - Specified by:
setBeanFactoryin interfaceorg.springframework.beans.factory.BeanFactoryAware- Throws:
org.springframework.beans.BeansException
-
setEnvironment
public void setEnvironment(org.springframework.core.env.Environment environment) - Specified by:
setEnvironmentin interfaceorg.springframework.context.EnvironmentAware
-
buildBeanDefinition
protected abstract org.springframework.beans.factory.config.BeanDefinition buildBeanDefinition(org.springframework.core.type.AnnotationMetadata importingClassMetadata, Class<? extends Annotation> namedAnnotation) throws Exception Called to get a bean definition to register.- Parameters:
importingClassMetadata- annotation metadata of the importing classnamedAnnotation- found annotations for bean names- Returns:
- the bean definition to register
- Throws:
Exception- if error occurred
-
getAnnotations
Gets the annotations specific for this configurer.- Returns:
- the annotations
-
getBeanFactory
protected org.springframework.beans.factory.BeanFactory getBeanFactory()Gets the bean factory.- Returns:
- the bean factory
-
getEnvironment
protected org.springframework.core.env.Environment getEnvironment()Gets the environment.- Returns:
- the environment
-