ApplicationContext对象

xiaoxiao2021-02-28  59

Spring框架中有一个类: org.springframework.context.ApplicationContext.

获得途径:

ApplicationContext applicationContext = new ClassPathXmlApplicationContext("classpath:spring/applicationContext.xml"); 配置文件路径

通过这个对象可以获得配置文件里面配置的Bean对象等....

转载请注明原文地址: https://www.6miu.com/read-73736.html

最新回复(0)