mybatis添加扫描.xml文件

来源:互联网 发布:java 16进制颜色转rgb 编辑:程序博客网 时间:2024/05/01 19:11

不要将mybatis 的.xml文件放在普通的java包下,要放在resources文件夹下。


entity扫描级别设为包


手动添加就是在sqlmapconfig.xml全局文件中加入


<mappers>  <mapper resource="config/mapper/UserMapper.xml" />    </mappers>




原创粉丝点击