ssm框架整合
也就是:spring + springmvc + mybatis
具体思路如下:
springmvc,负责实现MVC设计模式
mybatis,负责数据持久层
spring,负责管理这两个框架相关对象的创建和依赖注入。
因为springmvc是spring的一个子模块,所以ssm整合,其实就是spring和mybatis的整合。
整合
1.创建一个maven工程,打钩,现在webapp
2.删掉单元测试依赖
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.11</version>
<scope>test</scope>
</dependency>
2.去pom添加依赖(加在删掉哪里)