「 MYBATIS篇 」 二月 27, 2018
关于通用 Mapper Example 使用记录
文章字数 3.9k 阅读约需 4 mins.
- 项目整合 通用 mapper 和 pagehelper 插件,这部分以前有写过,略
- 需要集成 mybatis 的 generator 插件,方便自动生成 实体类和 mapper 类,还可以生成xml,不过一般我们都不用 xml
- baseMapper 需要继承 ExampleMapper
不过只需要继承 Mapper 就可以了,因为 Mapper 已经继承了 ExampleMapper
首先需要说明一点 ,和 Example 使用相同的还有 Condition 类 该类继承自 Example...
查看全文