当前位置:网站首页>BeanFactoryPostProcessor 与 BeanPostProcessor 相关子类概述
BeanFactoryPostProcessor 与 BeanPostProcessor 相关子类概述
2022-07-04 05:16:00 【小刘说】
BeanFactoryPostProcessor
主要用于处理 BeanFactory 和 BeanDefinition
子类概述
类图
BeanDefinitionRegistryPostProcessor
主要针对的操作对象是 BeanDefinitionConfigurableListableBeanFactory
1、解析加了@Configuration的配置类
2、解析@ComponentScan扫描的包
3、解析@ComponentScans扫描的包
4、解析@Import注解PlaceholderConfigurerSupport
用于解析bean定义中属性值里面的占位符DeprecatedBeanWarner
检测废弃的bean对象,并记录用户指定的bean类型CustomScopeConfigurer
自定义作用域的配置器EventListenerMethodProcessor
1、解析@EventListener,获取拦截方法
2、对拦截方法进行转换,变成ApplicationListener
3、将转换的ApplicationListener放到Spring容器中CustomAutowireConfigurer
允许方便地注册自定义autowire限定符类型CustomEditorConfigurer
此类用来方便的注册一个用户自定义的属性编辑器
BeanPostProcessor
在实例化属性注入后或初始化完成后调用
子类概述
类图
ApplicationContextAwareProcessor
向某些实现了Aware的接口的bean设置ApplicationContext中的相应属性
ApplicationListenerDetector
此类用来检测bean是否实现了 ApplicationListener 接口,两个作用:
1、实例化完成之后,如果bean的单例的并且属于 ApplicationListener 接口,则加入到多播器中
2、bean销毁之前,如果bean是一个 applicationListener ,则从多播器中提前删除CommonAnnotationBeanPostProcessor
负责解析@Resource、@WebServiceRef、@EJB三个注解AutowiredAnnotationBeanPostProcessor
完成bean中@Autowired,@Inject,@Value注解的解析并注入的功能AbstractAutoProxyCreator
ProxyProcessorSupport 的重要子类。SpringAOP中的核心类。
实现了SmartInstantiationAwareBeanPostProcessor、BeanFactoryAware接口。
自动创建代理对象的类。我们在使用AOP的时候基本上都是用的这个类来进程Bean的拦截,创建代理对象。AbstractAdvisorAutoProxyCreator
AbstractAutoProxyCreator 的子类。SpringAOP中的核心类。用来创建Advisor和代理对象。AspectJAwareAdvisorAutoProxyCreator
AbstractAdvisorAutoProxyCreator 的子类。使用AspectJ语法创建Advisor和代理对象。
其他
02 Spring 源码总结 - invokeBeanFactoryPostProcessors()
04 Spring 源码总结 - registerBeanPostProcessors()
边栏推荐
- Flutter ‘/usr/lib/libswiftCore. dylib‘ (no such file)
- Ping port artifact psping
- Void convolution, deformable convolution, deformable ROI pooling
- Basic concept of bus
- VB. Net GIF (making and disassembling - optimizing code, class library - 5)
- Electronic components mall and data manual download website summary
- 2022 t elevator repair operation certificate examination question bank and simulation examination
- [matlab] matlab simulation - narrow band Gaussian white noise
- Viewing and using binary log of MySQL
- How to use postman to realize simple interface Association [add, delete, modify and query]
猜你喜欢

Character types of C language
![[interested reading] advantageous filtering modeling on long term user behavior sequences for click through rate pre](/img/3e/b5df691ca1790469eb1b4e8ea5b4c0.png)
[interested reading] advantageous filtering modeling on long term user behavior sequences for click through rate pre

Daily question brushing record (12)

BUU-Reverse-easyre

Flask

LM小型可编程控制器软件(基于CoDeSys)笔记二十二:错误4268/4052

1480. 一维数组的动态和

2022年T电梯修理操作证考试题库及模拟考试
![[high concurrency, high performance and high availability of massive data MySQL practice-7] - memory data drop disk](/img/b9/cf4db4f8a5d2ef3fb344258f0e30f5.jpg)
[high concurrency, high performance and high availability of massive data MySQL practice-7] - memory data drop disk

C语言简易学生管理系统(含源码)
随机推荐
BUU-Crypto-[GXYCTF2019]CheckIn
Supplement the JS of a video website to decrypt the video
2022年A特种设备相关管理(电梯)考试题模拟考试平台操作
Viewing and using binary log of MySQL
RSA加密应用常见缺陷的原理与实践
2022 a special equipment related management (elevator) examination questions simulation examination platform operation
BUU-Real-[PHP]XXE
Write a complete answer applet (including single choice questions, judgment questions and multiple topics) (III) single choice questions, judgment questions, and the first question display
Programming example of stm32f1 and stm32subeide -74hc595 drives 4-bit 7-segment nixie tube
力扣 第 300 场周赛
2022g2 power station boiler stoker special operation certificate examination question bank and answers
Signification des lettres du module optique et abréviation des paramètres Daquan
With the advent of the IP era, how can E-sports hotels take advantage of the "east wind" of games?
Zhongke Panyun - data analysis and forensics packet flag
Basic concept of bus
Flink1.13 SQL basic syntax (I) DDL, DML
2022 R2 mobile pressure vessel filling retraining question bank and answers
企业级日志分析系统ELK(如果事与愿违那一定另有安排)
PostgreSQL has officially surpassed mysql. Is this guy too strong!
FreeRTOS 中 RISC-V-Qemu-virt_GCC 的 锁机制 分析