1.注解的方式
- Mapper
public interface UserMapper extends BaseMapper
- 测试
@Test void testFindALl() { List
2. 使用XML的方式
- Mapper
List
- MapperXml
<?xml version=”1.0” encoding=”UTF-8” ?><!DOCTYPE mapper PUBLIC “-//mybatis.org//DTD Mapper 3.0//EN” “http://mybatis.org/dtd/mybatis-3-mapper.dtd">
- application.properties