Atitit mybatis 3 3.2 3.3 3.4 新特性attilax总结
Atitit mybatis 3 3.2 3.3 3.4 新特性attilax总结
1.2. MyBatis团队于2013年2月21日正式发布 MyBatis 3.2.01
1.3. MyBatis 3.3.0 发布,此版本主要有两个改进:1
1.4. 持久层框架 MyBatis v3.4.1 发布 2016-06-26 2
2. Mybatis直接执行sql的改进 SqlMapper2
1.1. iBATIS 3 内的新特性.html
随着开发团队转投Google Code旗下,ibatis3.x正式更名为Mybatis
1.2. MyBatis团队于2013年2月21日正式发布 MyBatis 3.2.0
新特性包括:
· 支持可扩展脚本引擎
· 支持可扩展字节码提供器和Java辅助类
· 缓存嵌套查询
· 改善日志
· 修正了40余处BUG
1.3. MyBatis 3.3.0 发布,此版本主要有两个改进:
·
Ognl 升级至最新版本 3.0.11
·
·
默认代理工具是 Javassist,放置在 mybatis jar 内
·
1.4. 持久层框架 MyBatis v3.4.1 发布 2016-06-26
更新日志
改进
· Allow referencing parameters by their declared names when compiled with Java 8 -parametersoption. #549
· Added auto-detection of Year/MonthTypeHandler added in mybatis-typehandlers-jsr310 1.0.1. #646
· @Select can now return an array of objects. #669
· Allow specifying custom reflectorFactory in XML config. #657
2. Mybatis直接执行sql的改进 SqlMapper
为了让通用Mapper更彻底的支持多表操作以及更灵活的操作,在2.2.0版本增加了一个可以直接执行SQL的新类SqlMapper。
通过这篇博客,我们来了解一下SqlMapper。
2.1. SqlMapper提供的方法
SqlMapper提供了以下这些公共方法:
·
Map<String,Object> selectOne(String sql)
·
·
Map<String,Object> selectOne(String sql, Object value)
·
·
<T> T selectOne(String sql, Class<T> resultType)
·
·
<T> T selectOne(String sql, Object value, Class<T> resultType)
·
·
List<Map<String,Object>> selectList(String sql)
·
·
List<Map<String,Object>> selectList(String sql, Object value)
·
·
<T> List<T> selectList(String sql, Class<T> resultType)
·
·
<T> List<T> selectList(String sql, Object value, Class<T> resultType)
·
·
int insert(String sql)
·
·
int insert(String sql, Object value)
·
·
int update(String sql)
·
·
int update(String sql, Object value)
·
·
int delete(String sql)
·
·
int delete(String sql, Object value)
//查询,返回List<Map> List<Map<String, Object>> list = sqlMapper.selectList("select * from country where id < 11")
//insert int result = sqlMapper.insert("insert into country values(1921,'天朝','TC')");
//update result = sqlMapper.update("update country set countryname = '天朝' where id = 35");
//delete result = sqlMapper.delete("delete from country where id = 35");
3. 参考资料
持久层框架 MyBatis v3.4.1 发布 - OPEN资讯.html
MyBatis 3.3.0 发布,Ognl 升级至版本 3.0.11 - 开源中国社区.html
ibatis2.x与mybatis(ibatis3.x)的比较 - 赵先生不知何许人也的日志 - 网易博客.html
MyBatis直接执行SQL的工具SqlMapper - 偶尔记一下 - 博客频道 - CSDN.NET.html
Atitit mybatis 3 3.2 3.3 3.4 新特性attilax总结的更多相关文章
- Atitit opencv版本新特性attilax总结
Atitit opencv版本新特性attilax总结 1.1. :OpenCV 3.0 发布,史上功能最全,速度最快的版1 1.2. 应用领域2 1.3. OPENCV2.4.3改进 2.4.2就有 ...
- Atitit mac os 版本 新特性 attilax大总结
Atitit mac os 版本 新特性 attilax大总结 1. Macos概述1 2. 早期2 2.1. Macintosh OS (系统 1.0) 1984年2 2.2. Mac OS 7. ...
- atitit.TokenService v3 qb1 token服务模块的设计 新特性.docx
atitit.TokenService v3 qb1 token服务模块的设计 新特性.docx 1.1. V3 新特性1 1.2. V2 新特性1 2. Token的归类1 3. Token的用途 ...
- Atitit python3.0 3.3 3.5 3.6 新特性 Python2.7新特性1Python 3_x 新特性1python3.4新特性1python3.5新特性1值得关注的新特性1Pyth
Atitit python3.0 3.3 3.5 3.6 新特性 Python2.7新特性1 Python 3_x 新特性1 python3.4新特性1 python3.5新特性1 值得关注的新特性1 ...
- Atitit.jquery 版本号新特性attilax总结
Atitit.jquery 版本号新特性attilax总结 1. Jq1.4 1 2. 1.5 1 3. 1.6 3 4. Jq1.7 3 ⒉提升了事件委派时的性能有了大幅度的提升.尤其是在ie7下: ...
- Atitit hibernate3 hinernate4 hibernate5新特性attilax总结
Atitit hibernate3 hinernate4 hibernate5新特性attilax总结 1.1. Hibernate3的新特性 1 1.2. hibernate4.1版本中的新特性和h ...
- Atitit js es5 es6新特性 attilax总结
Atitit js es5 es6新特性 attilax总结 1.1. JavaScript发展时间轴:1 1.2. 以下是ES6排名前十的最佳特性列表(排名不分先后):1 1.3. Es6 支持情况 ...
- Atitit opencv3.0 3.1 3.2 新特性attilax总结
Atitit opencv3.0 3.1 3.2 新特性attilax总结 1. 3.0OpenCV 3 的改动在哪?1 1.1. 模块构成该看哪些模块?2 2. 3.1新特性 2015-12-21 ...
- Atitit html5.1 新特性attilax总结
Atitit html5.1 新特性attilax总结 9. 嵌入 header 和 footer1 7. 校验表单1 6. 浏览器的上下文菜单2 1. 响应式图像2 Attilax觉得还不错的心特性 ...
随机推荐
- 【Linux】常见Linux默认的shell
常见的操作系统下的shell: Linux下默认的shell是Bourne Again shell(bash) Solaris和FreeBSD下默认的是Bourne shell(sh) AIX系统下默 ...
- 8、redis之事务1-redis命令
一.概述: 和众多其它数据库一样,Redis作为NoSQL数据库也同样提供了事务机制.在Redis中,MULTI/EXEC/DISCARD/WATCH这四个命令是我们实现事务的基石.相信对有 ...
- Jenkins中集成jmeter-maven插件
转自:http://my.oschina.net/u/1377774/blog/168969 目录[-] 第一步.先在maven工程中单独使用jmeter-maven插件 0.环境 1.在POM.xm ...
- [解决]java.lang.IllegalArgumentException: Bad level "DEBUG"
Tomcat启动报错,搞得烦的一比.常规思维就会迷瞪,谁让tomcat的日志级别特殊ne.... http://tomcat.apache.org/tomcat-7.0-doc/ 错误现象: Hand ...
- Liability
Liability li·a·bil·i·ty ˌlīəˈbilədē/ noun A person or thing whose presence or behavior is likely ...
- [转载]在VirtualBox中收缩虚拟磁盘映像文件
原文地址:在VirtualBox中收缩虚拟磁盘映像文件作者:bobby 由于经常要测试一些软件,我在VirtualBox虚拟机中安装了一套Windows.使用过虚拟机的朋友都知道,为了节省硬盘空间,一 ...
- webshell文件下载器
拥有webshell的服务器可以ping通主机A,这就表明webshell可以向主机A post一些数据. 在主机A上开启一个接受文件的http服务,在webshell中使用文件上传命令进行上传. 主 ...
- libgdx游戏引擎教程
第一讲:libgdx游戏引擎教程(一)性能优良的游戏引擎—libgdx http://www.apkbus.com/android-57355-1-1.html 第二讲: libgdx游戏引擎教程(二 ...
- mac 终端添加颜色
1.打开终端,然后找到终端偏好设置,选择自己喜欢的颜色 2.然后切换到当前用户的家目录: cd ~ 3.打开文件,开始编辑".bash_profile", 添加下面两句 expor ...
- TCP详解 (1)
网络层: IP 被称为洲际协议,ICMP称为互联网控制报文协议 IGMP 为互联网组管理协议 传输层: 传输层的作用是把应用程序给他的任务划分为数据包,然后传递给下面的层: 应用层: 应用层的协 ...