1.用文件路径引入映射器
<mappers>
<mapper reource="com/learn/ssm/chapter4/mapper/roleMapper.xml"/>
</mappers>
2.用包名引入映射器
<mappers>
<package name="com.learn.ssm.chapter4.mapper">
</mappers>
3.用类注册引入映射器
<mappers>
<mapper class="com.learn.ssm.chapter4.mapper.UserMapper"/>
<mapper class="com.learn.ssm.chapter4.mapper.RoleMapper"/>
</mappers>
4.用userMapper.xml引入映射器
<mappers>
<mapper url="file:///var/mappers/com/learn/ssm/chapter4/mapper/roleMapper.xml"/>
<mapper url="file:///var/mappers/com/learn/ssm/chapter4/mapper/RoleMapper.xml"/>
</mappers>