mybatis精讲(三)--标签及TypeHandler使用
目录 话引 XML配置标签 概览 properties 子标签property resource 程序注入 settings 别名 TypeHandler 自定义TypeHandler EnumTypeHandler EnumOrdinalTypeHandler SexTypeHandler typeHandler注意点 # 加入战队 微信公众号 话引 前两张我们分别介绍了Mybatis环境搭建及其组件的生命周期。这些都是我们Mybatis入门必备技能。有了前两篇的铺垫我们今天就来深入下Mybatis, 也为了填下之前埋下的坑。 XML配置标签 概览 <?xml version="1.0" encoding="UTF-8" ?> <!DOCTYPE configuration PUBLIC "-//mybatis.org//DTD Config 3.0//EN" "http://mybatis.org/dtd/mybatis-3-config.dtd"> <configuration> <!--引入外部配置文件--> <properties resource=""/> <!--设置--> <settings/> <!--定义别名--> <typeAliases> <package name=""/> </typeAliases> <!--类型处理器--> <typeHandlers