Environment env = new Environment("test",new JdbcTransactionFactory(),ds);
Configuration config = new Configuration(env);
config.addMapper(BlogMapper.class);
SqlSessionFactoryBuilder builder = new SqlSessionFactoryBuilder();
SqlSessionFactory sqlMapper = builder.build(config);
SqlSession session = sqlMapper.openSession();
try {
BlogMapper mapper = session.getMapper(BlogMapper.class);
int n = 0;
try {
n = mapper.insertAuthor(new Author(99999,"barney","******","barney@iloveyou.com",null, Section.NEWS));