MyBatis笔记——通过过滤器Filter简化创建SqlSession对象
一 提出问题:为什么要优化代码
首先,先看不使用过滤器filter,直接在方法里面创建SqlSessionFactory工厂
public class StudentService {
public int insStudent(Student student) {
InputStream iStream = null;
int index = 0;
try {
iStream...
原创
2019-01-27 13:51:27 ·
3624 阅读 ·
1 评论