public class

AnnotationConfigUtils

extends Object
java.lang.Object
   ↳ org.springframework.context.annotation.AnnotationConfigUtils

Class Overview

Utility class that allows for convenient registration of common BeanPostProcessor and BeanFactoryPostProcessor definitions for annotation-based configuration.

Summary

Constants
String AUTOWIRED_ANNOTATION_PROCESSOR_BEAN_NAME The bean name of the internally managed Autowired annotation processor.
String COMMON_ANNOTATION_PROCESSOR_BEAN_NAME The bean name of the internally managed JSR-250 annotation processor.
String CONFIGURATION_ANNOTATION_PROCESSOR_BEAN_NAME The bean name of the internally managed Configuration annotation processor.
String PERSISTENCE_ANNOTATION_PROCESSOR_BEAN_NAME The bean name of the internally managed JPA annotation processor.
String REQUIRED_ANNOTATION_PROCESSOR_BEAN_NAME The bean name of the internally managed Required annotation processor.
Public Constructors
AnnotationConfigUtils()
Public Methods
static Set<BeanDefinitionHolder> registerAnnotationConfigProcessors(BeanDefinitionRegistry registry, Object source)
Register all relevant annotation post processors in the given registry.
static void registerAnnotationConfigProcessors(BeanDefinitionRegistry registry)
Register all relevant annotation post processors in the given registry.
[Expand]
Inherited Methods
From class java.lang.Object

Constants

public static final String AUTOWIRED_ANNOTATION_PROCESSOR_BEAN_NAME

The bean name of the internally managed Autowired annotation processor.

Constant Value: "org.springframework.context.annotation.internalAutowiredAnnotationProcessor"

public static final String COMMON_ANNOTATION_PROCESSOR_BEAN_NAME

The bean name of the internally managed JSR-250 annotation processor.

Constant Value: "org.springframework.context.annotation.internalCommonAnnotationProcessor"

public static final String CONFIGURATION_ANNOTATION_PROCESSOR_BEAN_NAME

The bean name of the internally managed Configuration annotation processor.

Constant Value: "org.springframework.context.annotation.internalConfigurationAnnotationProcessor"

public static final String PERSISTENCE_ANNOTATION_PROCESSOR_BEAN_NAME

The bean name of the internally managed JPA annotation processor.

Constant Value: "org.springframework.context.annotation.internalPersistenceAnnotationProcessor"

public static final String REQUIRED_ANNOTATION_PROCESSOR_BEAN_NAME

The bean name of the internally managed Required annotation processor.

Constant Value: "org.springframework.context.annotation.internalRequiredAnnotationProcessor"

Public Constructors

public AnnotationConfigUtils ()

Public Methods

public static Set<BeanDefinitionHolder> registerAnnotationConfigProcessors (BeanDefinitionRegistry registry, Object source)

Register all relevant annotation post processors in the given registry.

Parameters
registry the registry to operate on
source the configuration source element (already extracted) that this registration was triggered from. May be null.
Returns
  • a Set of BeanDefinitionHolders, containing all bean definitions that have actually been registered by this call

public static void registerAnnotationConfigProcessors (BeanDefinitionRegistry registry)

Register all relevant annotation post processors in the given registry.

Parameters
registry the registry to operate on