当前位置:首页 > spring 3和mybatis 3集成,并用junit4进行测试
class=\Manager\ value=\ 4、JavaBean(Model、Entity)相关类、及mybatis 的mapper对象 javabean: package com.glen.model; import java.io.Serializable; import java.util.Date; public class Account implements Serializable { private static final long serialVersionUID = -7970848646314840509L; private Integer accountId; private String username; private String password; private Date createTime; public Account() { super(); } //下面是getter、setters account-resultMap.xml insert into account(account_id, username, password) values(#{accountId,jdbcType=BIGINT}, #{username}, #{password}) username = #{username}, password = #{password} where account_id = #{accountId} 5、创建dao: package com.glen.dao; import javax.annotation.Resource; import org.apache.ibatis.session.SqlSession;
共分享92篇相关文档