joblog/build/classes/generatorConfig.xml

(开头部分) 3KB

这里只显示每个文件的开头 60 行。登录后可以解锁完整代码。

<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE generatorConfiguration PUBLIC "-//mybatis.org//DTD MyBatis Generator Configuration 1.0//EN" "http://mybatis.org/dtd/mybatis-generator-config_1_0.dtd" >
<generatorConfiguration>
	<!-- 引入配置文件 -->
	<properties resource="app.properties"/>
	
	<!-- 指定数据连接驱动jar地址 -->
	<classPathEntry location="${classPath}" />
	
	<!-- 一个数据库一个context -->
	<context id="infoGuardian">
		<!-- 注释 -->
		<commentGenerator >
			<property name="suppressAllComments" value="true"/><!-- 是否取消注释 -->
			<property name="suppressDate" value="true" /> <!-- 是否生成注释代时间戳-->
		</commentGenerator>
		
		<!-- jdbc连接 -->
		<jdbcConnection driverClass="com.mysql.jdbc.Driver"
		 connectionURL="${db.jdbc.url}" userId="${db.jdbc.username}" password="${db.jdbc.password}"/>
		<!-- <jdbcConnection driverClass="${jdbc_driver}"
			connectionURL="${jdbc_url}" userId="${jdbc_user}"
			password="${jdbc_password}" /> -->
		
		<!-- 类型转换 -->
		<javaTypeResolver>
			<!-- 是否使用bigDecimal, false可自动转化以下类型(Long, Integer, Short, etc.) -->
			<property name="forceBigDecimals" value="false"/>
		</javaTypeResolver>
		
		<!-- 生成实体类地址 -->	
		<javaModelGenerator targetPackage="com.wei.manager.bean"
			targetProject="${project}" >
			<!-- 是否在当前路径下新加一层schema,eg:fase路径com.fable.dwjd.common.bean, true:com.fable.dwjd.common.bean.[schemaName] -->
			<property name="enableSubPackages" value="false"/>
			<!-- 是否针对string类型的字段在set的时候进行trim调用 -->
			<property name="trimStrings" value="true"/>
		</javaModelGenerator>
		
		<!-- 生成mapxml文件 -->
		<sqlMapGenerator targetPackage="com.wei.manager.mapper"
			targetProject="${project}" >
			<!-- 是否在当前路径下新加一层schema,eg:fase路径com.fable.dwjd.common.bean, true:com.fable.dwjd.common.bean.[schemaName] -->
			<property name="enableSubPackages" value="false" />
		</sqlMapGenerator>
		
		<!-- 生成mapxml对应client,也就是接口dao -->	
		<javaClientGenerator targetPackage="com.wei.manager.mapper"
			targetProject="${project}" type="XMLMAPPER" >
			<!-- 是否在当前路径下新加一层schema,eg:fase路径com.fable.dwjd.common.bean, true:com.fable.dwjd.common.bean.[schemaName] -->
			<property name="enableSubPackages" value="false" />
		</javaClientGenerator>
		
		<!-- 配置表信息 -->	
		<table tableName="JOBLOG" domainObjectName="Joblog" 
			enableCountByExample="false"
			enableDeleteByExample="false" enableSelectByExample="false"
			enableUpdateByExample="false">
			<!-- schema即为数据库名 tableName为对应的数据库表 domainObjectName是要生成的实体类 enable*ByExample 
				是否生成 example类   -->
后面还有 8 行代码,购买后查看完整代码

24 小时内免费解锁 3 个项目,之后 1 积分/个。 规则说明

AI 解读

登录后可用,每次 10 积分,解读结果公开显示在下面。

还没有人解读过这个文件。