程序包 org.springframework.context.annotation
Annotation support for the Application Context, including JSR-250 "common" annotations, component-scanning, and Java-based metadata for creating Spring-managed objects.
接口概要 接口 说明 AnnotationConfigRegistry Common interface for annotation config application contexts, definingAnnotationConfigRegistry.register(java.lang.Class<?>...)andAnnotationConfigRegistry.scan(java.lang.String...)methods.Condition A singleconditionthat must be matched in order for a component to be registered.ConditionContext Context information for use byConditions.ConfigurationCondition AConditionthat offers more fine-grained control when used with@Configuration.DeferredImportSelector A variation ofImportSelectorthat runs after all@Configurationbeans have been processed.ImportAware Interface to be implemented by any @Configurationclass that wishes to be injected with theAnnotationMetadataof the @Configurationclass that imported it.ImportBeanDefinitionRegistrar Interface to be implemented by types that register additional bean definitions when processing @Configurationclasses.ImportSelector Interface to be implemented by types that determine which @Configurationclass(es) should be imported based on a given selection criteria, usually one or more annotation attributes.LoadTimeWeavingConfigurer Interface to be implemented by@Configurationclasses annotated with@EnableLoadTimeWeavingthat wish to customize theLoadTimeWeaverinstance to be used.ScopeMetadataResolver Strategy interface for resolving the scope of bean definitions.类概要 类 说明 AdviceModeImportSelector<A extends Annotation> Convenient base class forImportSelectorimplementations that select imports based on anAdviceModevalue from an annotation (such as the@Enable*annotations).AnnotatedBeanDefinitionReader Convenient adapter for programmatic registration of annotated bean classes.AnnotationBeanNameGenerator BeanNameGeneratorimplementation for bean classes annotated with the@Componentannotation or with another annotation that is itself annotated with@Componentas a meta-annotation.AnnotationConfigApplicationContext Standalone application context, accepting annotated classes as input - in particular@Configuration-annotated classes, but also plain@Componenttypes and JSR-330 compliant classes usingjavax.injectannotations.AnnotationConfigBeanDefinitionParser Parser for the <context:annotation-config/> element.AnnotationConfigUtils Utility class that allows for convenient registration of commonBeanPostProcessorandBeanFactoryPostProcessordefinitions for annotation-based configuration.AnnotationScopeMetadataResolver AScopeMetadataResolverimplementation that by default checks for the presence of Spring's@Scopeannotation on the bean class.AutoProxyRegistrar Registers an auto proxy creator against the currentBeanDefinitionRegistryas appropriate based on an@Enable*annotation havingmodeandproxyTargetClassattributes set to the correct values.ClassPathBeanDefinitionScanner A bean definition scanner that detects bean candidates on the classpath, registering corresponding bean definitions with a given registry (BeanFactoryorApplicationContext).ClassPathScanningCandidateComponentProvider A component provider that scans the classpath from a base package.CommonAnnotationBeanPostProcessor BeanPostProcessorimplementation that supports common Java annotations out of the box, in particular the JSR-250 annotations in thejavax.annotationpackage.ComponentScanBeanDefinitionParser Parser for the<context:component-scan/>element.ConfigurationClassPostProcessor BeanFactoryPostProcessorused for bootstrapping processing of@Configurationclasses.ContextAnnotationAutowireCandidateResolver Complete implementation of theAutowireCandidateResolverstrategy interface, providing support for qualifier annotations as well as for lazy resolution driven by theLazyannotation in thecontext.annotationpackage.Jsr330ScopeMetadataResolver SimpleScopeMetadataResolverimplementation that follows JSR-330 scoping rules: defaulting to prototype scope unlessSingletonis present.LoadTimeWeavingConfiguration @Configurationclass that registers aLoadTimeWeaverbean.MBeanExportConfiguration @Configurationclass that registers aAnnotationMBeanExporterbean.ScannedGenericBeanDefinition Extension of theGenericBeanDefinitionclass, based on an ASM ClassReader, with support for annotation metadata exposed through theAnnotatedBeanDefinitioninterface.ScopeMetadata Describes scope characteristics for a Spring-managed bean including the scope name and the scoped-proxy behavior.枚举概要 枚举 说明 AdviceMode Enumeration used to determine whether JDK proxy-based or AspectJ weaving-based advice should be applied.ConfigurationCondition.ConfigurationPhase The various configuration phases where the condition could be evaluated.EnableLoadTimeWeaving.AspectJWeaving FilterType Enumeration of the type filters that may be used in conjunction with@ComponentScan.MBeanExportConfiguration.SpecificPlatform ScopedProxyMode Enumerates the various scoped-proxy options.注释类型概要 注释类型 说明 Bean Indicates that a method produces a bean to be managed by the Spring container.ComponentScan Configures component scanning directives for use with @Configurationclasses.ComponentScan.Filter Declares the type filter to be used as an include filter or exclude filter.ComponentScans Container annotation that aggregates severalComponentScanannotations.Conditional Indicates that a component is only eligible for registration when all specified conditions match.Configuration Indicates that a class declares one or more@Beanmethods and may be processed by the Spring container to generate bean definitions and service requests for those beans at runtime, for example:DependsOn Beans on which the current bean depends.Description EnableAspectJAutoProxy Enables support for handling components marked with AspectJ's@Aspectannotation, similar to functionality found in Spring's<aop:aspectj-autoproxy>XML element.EnableLoadTimeWeaving Activates a SpringLoadTimeWeaverfor this application context, available as a bean with the name "loadTimeWeaver", similar to the<context:load-time-weaver>element in Spring XML.EnableMBeanExport Enables default exporting of all standardMBeans from the Spring context, as well as well all@ManagedResourceannotated beans.Import Indicates one or more@Configurationclasses to import.ImportResource Indicates one or more resources containing bean definitions to import.Lazy Indicates whether a bean is to be lazily initialized.Primary Indicates that a bean should be given preference when multiple candidates are qualified to autowire a single-valued dependency.Profile Indicates that a component is eligible for registration when one or more specified profiles are active.PropertySource Annotation providing a convenient and declarative mechanism for adding aPropertySourceto Spring'sEnvironment.PropertySources Container annotation that aggregates severalPropertySourceannotations.Role Indicates the 'role' hint for a given bean.Scope When used as a type-level annotation in conjunction with@Component,@Scopeindicates the name of a scope to use for instances of the annotated type.