@Order public class BeanMethodContainerRegistrar extends ContainerMethodAnnotationProcessor implements org.springframework.beans.factory.InitializingBean, org.springframework.beans.factory.SmartInitializingSingleton, org.springframework.context.ApplicationContextAware, org.springframework.beans.factory.DisposableBean
Post process the bean, scan the method with
ContainerMethod annotation in the class or method of class,
and adapt it to Container instance
according to MethodContainerFactory registered in the Spring context.
ContainerMethod,
MethodContainerFactory,
Crane4jGlobalConfigurationannotationFinder, nonAnnotatedClassesmethodContainerFactories| 构造器和说明 |
|---|
BeanMethodContainerRegistrar(AnnotationFinder annotationFinder,
Crane4jGlobalConfiguration configuration)
Create an
BeanMethodContainerRegistrar instance. |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
afterPropertiesSet() |
void |
afterSingletonsInstantiated()
Scan and process the method with the specified annotation in the class.
|
void |
destroy()
Clear resources when destroying beans
|
void |
register(Object target,
Class<?> targetType)
register method containers which scanned from the bean methods.
|
void |
register(Object target,
Class<?> targetType,
@Nullable UnaryOperator<Container<Object>> customizer)
register method containers which scanned from the bean methods.
|
collectClassLevelAnnotatedMethods, collectMethodLevelAnnotatedMethods, process, processAnnotatedMethod, resolveAnnotationsForClass, resolveAnnotationsForMethodcreateMethodContainer, findMatchedMethodForAnnotation, findMostMatchMethod, registerMethodContainerFactorypublic BeanMethodContainerRegistrar(AnnotationFinder annotationFinder, Crane4jGlobalConfiguration configuration)
BeanMethodContainerRegistrar instance.annotationFinder - annotation finderconfiguration - crane4j global configurationpublic void destroy()
destroy 在接口中 org.springframework.beans.factory.DisposableBeanpublic void register(Object target, Class<?> targetType)
register method containers which scanned from the bean methods.
target - targettargetType - target typeContainerMethodAnnotationProcessor.process(java.lang.Object, java.lang.Class<?>)public void register(Object target, Class<?> targetType, @Nullable UnaryOperator<Container<Object>> customizer)
register method containers which scanned from the bean methods.
target - targettargetType - target typecustomizer - container customizerContainerMethodAnnotationProcessor.process(java.lang.Object, java.lang.Class<?>)public void afterPropertiesSet()
afterPropertiesSet 在接口中 org.springframework.beans.factory.InitializingBeanpublic void afterSingletonsInstantiated()
Scan and process the method with the specified annotation in the class. If the annotation also exists in the class, find and process the corresponding method in the class.
afterSingletonsInstantiated 在接口中 org.springframework.beans.factory.SmartInitializingSingletonCopyright © 2024. All rights reserved.