Mybatis对mysql数据库分页
在generator中加入插件,下载地址http://download.csdn.net/detail/shunlongjin/6937045
<plugintype="org.mybatis.generator.plugins.EqualsHashCodePlugin" />
<plugintype="org.duoku.groom.mybatis.plugin.PaginationPlugin"></plugin>
自动生成java对象和mapper后,可以对数据库进行分页处理,具体代码如下