public interface

FeatureAnnotationParser

org.springframework.context.annotation.FeatureAnnotationParser

Class Overview

Interface for parsing AnnotationMetadata from a FeatureAnnotation into a FeatureSpecification object. Used in conjunction with a FeatureSpecificationExecutor to provide a source-agnostic approach to handling configuration metadata.

For example, Spring's component-scanning can be configured via XML using the context:component-scan element or via the ComponentScan annotation. In either case, the metadata is the same -- only the source format differs. ComponentScanBeanDefinitionParser is used to create a specification from the <context:component-scan> XML element, while ComponentScanAnnotationParser creates a specification from the the annotation style. They both produce a ComponentScanSpec object that is ultimately delegated to a ComponentScanExecutor which understands how to configure a ClassPathBeanDefinitionScanner, perform actual scanning, and register actual bean definitions against the container.

Implementations must be instantiable via a no-arg constructor. TODO SPR-7420: documentation (clean up) TODO SPR-7420: rework so annotations declare their creator.

See Also

Summary

Public Methods
abstract FeatureSpecification process(AnnotationMetadata metadata)
Parse the given annotation metadata and populate a FeatureSpecification object suitable for execution by a FeatureSpecificationExecutor.

Public Methods

public abstract FeatureSpecification process (AnnotationMetadata metadata)

Parse the given annotation metadata and populate a FeatureSpecification object suitable for execution by a FeatureSpecificationExecutor.