spring源码解读二
上一篇文章说到了生命周期的初始化refresh方法 在refresh里面有如下方法,这里只讲关键的几个方法比如说invokeBeanFactoryPostProcessors和finishBeanFactoryInitialization prepareRefresh(); // Tell the subclass to refresh the internal bean factory. ConfigurableListableBeanFactory beanFactory = obtainFreshBeanFactory(); // Prepare the bean factory for use in this context. prepareBeanFactory(beanFactory); // Allows post-processing of the bean factory in context subclasses. postProcessBeanFactory(beanFactory); // Invoke factory processors registered as beans in the context. invokeBeanFactoryPostProcessors(beanFactory); // Register bean processors