Miscellany 2

1.ApplicationContext and ApplicationContextAware
First of all I need to know about the Spring container.
As we all know, Spring-framework uses inversion of control container technology allows objects to be responsible for the life cycle (creation, assembly, destruction).
When the BeanFactory container base, the Spring-framework, all components are considered the bean, it includes a data source, Hibernate of the SessionFactory, the transaction manager and the like. BeanFactory is responsible for generating the bean instance.
ApplicationContext inherited the BeanFactory, in addition to achieving its basic functions, you can also configure parsing text messages and other functions, it is also the most commonly used container
beanFactory structure

ApplicationContextAware, can be used to get ApplicationContext

Guess you like

Origin www.cnblogs.com/bestefforts/p/11898419.html