读书人

Spring源码阅览:ContextLoaderListen

发布时间: 2012-11-05 09:35:12 作者: rapoo

Spring源码阅读:ContextLoaderListener
spring在web中的启动是由ContextLoaderListener开始的。ContextLoaderListener实现了ServlContextListener接口,并继承了ContextLoader类。

                wac.setParent(parent);        wac.setServletContext(sc);       //获取configLocation的配置        wac.setConfigLocation(sc.getInitParameter(CONFIG_LOCATION_PARAM));        customizeContext(sc, wac);// 用于自定义ContextClass时,扩充自定义Context        wac.refresh();// 完成context构造过程。

读书人网 >软件架构设计

热点推荐