[html]代码库
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE ibatorConfiguration PUBLIC "-//Apache Software Foundation//DTD Apache iBATIS Ibator Configuration 1.0//EN" "http://ibatis.apache.org/dtd/ibator-config_1_0.dtd" >
<ibatorConfiguration>
<!--数据库驱动jar -->
<classPathEntry location="C:/app/apache-maven-3.3.9/repo/postgresql/postgresql/9.4.1208-jdbc42-atlassian-hosted/postgresql-9.4.1208-jdbc42-atlassian-hosted.jar" />
<ibatorContext id="context1">
<jdbcConnection driverClass="org.postgresql.Driver"
connectionURL="jdbc:postgresql://127.0.0.1:5432/bike" userId="postgres"
password="root" />
<!--targetPackage指定一个包名存放model bean,targetProject是工程名 -->
<javaModelGenerator targetPackage="com.liang.bean"
targetProject="demo/src" />
<!--sqlMapGenerator 指定一个包名存放sqlMap.xml -->
<sqlMapGenerator targetPackage="com.liang.sqlmap" targetProject="demo/src" />
<!--daoGenerator 指定一个包名存放dao以及daoImpl -->
<daoGenerator targetPackage="com.liang.dao" targetProject="demo/src"
type="GENERIC-CI" />
<!--表名,可以多个,默认不写columnOverride的话生成所有字段 -->
<table schema="" tableName="bike">
<!-- <columnOverride column="???" property="???" /> -->
</table>
</ibatorContext>
</ibatorConfiguration>
[源代码打包下载]