锘??xml version="1.0" encoding="utf-8" standalone="yes"?> 浣嗘槸濡傛灉浣犱嬌鐢↗DK5.0鎴栨洿楂樼増鏈椂錛屾繪槸璀﹀憡璇ョ被緙哄皯涓?font face="瀹?huà)浣?>static final long serialVersionUID錛屽浣曟墠鑳藉湪hbm2java鐢熸垚java婧愪唬鐮佹椂鑷姩鍔犱笂鍛紵榪欏氨瑕佷慨鏀筯ibernate-tools.jar涓嚜甯︾殑pojo妯℃澘浜?jiǎn)銆?/font> 棣栧厛錛屼綘灝唄ibernate-toosl.jar涓殑pojo/Pojo.ftl鏂囦歡瑙e帇鍑烘潵錛屽湪 鐒跺悗灝嗘Pojo.ftl鏂囦歡瑕嗙洊hibernate-tools.jar鍘嬬緝鍖呬腑鐨勫嵆鍙?/p>
鏈鍚庯紝鍐嶆榪愯浣犵殑ant錛宐uild.xml涓嶉渶瑕佷慨鏀圭敓鎴愮殑綾誨氨鑷姩鏈変簡(jiǎn)錛歴tatic final long serialVersionUID = 1L;public class Child implements java.io.Serializable {
private int cid;
private String childName;
public int getCid() {
return this.cid;
}
public void setCid(int cid) {
this.cid = cid;
}
public String getChildName() {
return this.childName;
}
public void setChildName(String childName) {
this.childName = childName;
}
}
${pojo.getPackageDeclaration()}
// Generated ${date} by Hibernate Tools ${version}
<#assign classbody>
<#include "PojoTypeDeclaration.ftl"/> {
<#if !pojo.isInterface()>
static final long serialVersionUID = 1L;
<#include "PojoFields.ftl"/>
<#include "PojoConstructors.ftl"/>
<#include "PojoPropertyAccessors.ftl"/>
<#include "PojoToString.ftl"/>
<#include "PojoEqualsHashcode.ftl"/>
<#else>
<#include "PojoInterfacePropertyAccessors.ftl"/>
</#if>
<#include "PojoExtraClassCode.ftl"/>
}
</#assign>
${pojo.generateImports()}
${classbody}
鍛靛懙錛屽緢濂界帺鍚с傛垜浠繕鍙互鍦≒ojo.ftl妯℃澘鏂囦歡涓鍔犲叾浠栬嚜宸遍渶瑕佺殑浠g爜浜?jiǎn)锛?/p>
org.hibernate.tool.ant.HibernateToolTask
涓嬮潰鏄痓uild.xml鏂囦歡涓湁鍏崇殑涓孌碉細(xì)