摘要: 1、扫描配置之前使用的Spring的Bean管理都是通过xml的配置文件来操作的,在Spring3.0之后已经引入了注解形式,Spring可以在指定路径下进行扫描,寻找标注了@Component、@Service、@Controller、@Repository注解的类,并将其纳入到Spring容器中进行管理。如果采用注解方式,需要首先在配置文件中指明扫描的包,如下配置: 1 1 base-p... 阅读全文
posted @ 2018-04-22 11:16 Dulk 阅读(319) 评论(0) 推荐(0) 编辑