Package com.hao.bos.entity;
Generated 2017-8-15 16:30:28 by Hibernate Tools 4.0.0
Import Java.util.HashSet;
Import Java.util.Set;
/**
* Fixed Area
*/
public class Decidedzone implements Java.io.Serializable {
Private static final long serialversionuid = 1L;
Private String ID;
Private staff and staff;
private String name;
Private set<subarea> subareas = new hashset<subarea> (0);
Public Decidedzone () {
}
Public Decidedzone (String ID) {
This.id = ID;
}
Public Decidedzone (string ID, staff staff, string name,
Set<subarea> subareas) {
This.id = ID;
This.staff = staff;
THIS.name = name;
This.subareas = subareas;
}
Public String getId () {
return this.id;
}
public void SetId (String id) {
This.id = ID;
}
Public Staff Getstaff () {
return this.staff;
}
public void Setstaff (staff staff) {
This.staff = staff;
}
Public String GetName () {
return this.name;
}
public void SetName (String name) {
THIS.name = name;
}
Public set<subarea> Getsubareas () {
return this.subareas;
}
public void Setsubareas (set<subarea> subareas) {
This.subareas = subareas;
}
}
Package com.hao.bos.entity;
Import Java.util.HashSet;
Import Java.util.Set;
/**
* Area
*/
public class Region implements Java.io.Serializable {
Private static final long serialversionuid = 1L;
Private String ID;
Private String Province;
Private String City;
Private String District;
Private String postcode;
Private String Shortcode;
Private String Citycode;
Private set<subarea> subareas = new hashset<subarea> (0);
Public region () {
}
Public region (String ID) {
This.id = ID;
}
Public region (string ID, String province, String city, String district,
String postcode, String shortcode, String Citycode,
Set<subarea> subareas) {
This.id = ID;
this.province = Province;
this.city = City;
this.district = District;
This.postcode = postcode;
This.shortcode = Shortcode;
This.citycode = Citycode;
This.subareas = subareas;
}
Public String getId () {
return this.id;
}
public void SetId (String id) {
This.id = ID;
}
Public String getprovince () {
return this.province;
}
public void Setprovince (String province) {
this.province = Province;
}
Public String getcity () {
return this.city;
}
public void Setcity (String city) {
this.city = City;
}
Public String getdistrict () {
return this.district;
}
public void Setdistrict (String district) {
this.district = District;
}
Public String Getpostcode () {
return this.postcode;
}
public void Setpostcode (String postcode) {
This.postcode = postcode;
}
Public String Getshortcode () {
return this.shortcode;
}
public void Setshortcode (String shortcode) {
This.shortcode = Shortcode;
}
Public String Getcitycode () {
return this.citycode;
}
public void Setcitycode (String citycode) {
This.citycode = Citycode;
}
Public set<subarea> Getsubareas () {
return this.subareas;
}
public void Setsubareas (set<subarea> subareas) {
This.subareas = subareas;
}
}
Package com.hao.bos.entity;
Import Java.util.HashSet;
Import Java.util.Set;
/**
* Pick up the dispatch staff
*/
Public class staff implements Java.io.Serializable {
Private static final long serialversionuid = 1L;
Private String ID;
private String name;
Private String telephone;
Private Character HASPDA;
Private Character Deltag;
Private String station;
Private String Standard;
Private set<decidedzone> Decidedzones = new hashset<decidedzone> (0);
Public staff () {
}
Public staff (String ID) {
This.id = ID;
}
Public staff (string ID, string name, string telephone, Character HASPDA,
Character Deltag, String station, String standard,
Set<decidedzone> decidedzones) {
This.id = ID;
THIS.name = name;
This.telephone = telephone;
THIS.HASPDA = HASPDA;
This.deltag = Deltag;
This.station = station;
This.standard = standard;
This.decidedzones = Decidedzones;
}
Public String getId () {
return this.id;
}
public void SetId (String id) {
This.id = ID;
}
Public String GetName () {
return this.name;
}
public void SetName (String name) {
THIS.name = name;
}
Public String Gettelephone () {
return this.telephone;
}
public void Settelephone (String telephone) {
This.telephone = telephone;
}
Public Character Gethaspda () {
return THIS.HASPDA;
}
public void Sethaspda (Character haspda) {
THIS.HASPDA = HASPDA;
}
Public Character Getdeltag () {
return this.deltag;
}
public void Setdeltag (Character deltag) {
This.deltag = Deltag;
}
Public String getstation () {
return this.station;
}
public void Setstation (String station) {
This.station = station;
}
Public String Getstandard () {
return this.standard;
}
public void Setstandard (String standard) {
This.standard = standard;
}
Public set<decidedzone> Getdecidedzones () {
return this.decidedzones;
}
public void Setdecidedzones (set<decidedzone> decidedzones) {
This.decidedzones = Decidedzones;
}
}
Package com.hao.bos.entity;
/**
* Partition
*/
public class Subarea implements Java.io.Serializable {
Private static final long serialversionuid = 1L;
Private String ID;
Private Decidedzone Decidedzone; Fixed area
Private region; Regional
Private String Addresskey;
Private String Startnum;
Private String Endnum;
Private Character single;
private String position;
Public Subarea () {
}
Public Subarea (String ID) {
This.id = ID;
}
Public Subarea (String ID, Decidedzone decidedzone, Region region,
String Addresskey, String startnum, String endnum,
Character single, String position) {
This.id = ID;
This.decidedzone = Decidedzone;
this.region = region;
This.addresskey = Addresskey;
This.startnum = Startnum;
This.endnum = Endnum;
This.single = single;
This.position = position;
}
Public String getId () {
return this.id;
}
public void SetId (String id) {
This.id = ID;
}
Public Decidedzone Getdecidedzone () {
return this.decidedzone;
}
public void Setdecidedzone (Decidedzone decidedzone) {
This.decidedzone = Decidedzone;
}
Public Region getregion () {
return this.region;
}
public void Setregion (region) {
this.region = region;
}
Public String Getaddresskey () {
return this.addresskey;
}
public void Setaddresskey (String addresskey) {
This.addresskey = Addresskey;
}
Public String Getstartnum () {
return this.startnum;
}
public void Setstartnum (String startnum) {
This.startnum = Startnum;
}
Public String Getendnum () {
return this.endnum;
}
public void Setendnum (String endnum) {
This.endnum = Endnum;
}
Public Character Getsingle () {
return this.single;
}
public void SetSingle (Character) {
This.single = single;
}
Public String getPosition () {
return this.position;
}
public void SetPosition (String position) {
This.position = position;
}
}
<?xml version= "1.0"?>
<! DOCTYPE hibernate-mapping Public "-//hibernate/hibernate mapping DTD 3.0//en"
"Http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd" >
<!--Generated 2017-8-15 16:30:28 by Hibernate Tools 4.0.0--
<class name= "Com.hao.bos.entity.Decidedzone" table= "Bc_decidedzone" >
<id name= "id" type= "string" >
<column name= "id" length= "/>"
<generator class= "Assigned"/>
</id>
<many-to-one name= "Staff" class= "Staff" fetch= "select" >
<column name= "staff_id" length= "/>"
</many-to-one>
<property name= "Name" type= "string" >
<column name= "name" length= "/>"
</property>
<set name= "subareas" table= "Bc_subarea" inverse= "true" lazy= "true" fetch= "select" >
<key>
<column name= "decidedzone_id" length= "/>"
</key>
<one-to-many class= "Subarea"/>
</set>
</class>
<?xml version= "1.0"?>
<! DOCTYPE hibernate-mapping Public "-//hibernate/hibernate mapping DTD 3.0//en"
"Http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd" >
<!--Generated 2017-8-15 16:30:28 by Hibernate Tools 4.0.0--
<class name= "com.hao.bos.entity.Region" table= "Bc_region" >
<id name= "id" type= "string" >
<column name= "id" length= "/>"
<generator class= "Assigned"/>
</id>
<property name= "province" type= "string" >
<column name= "province" length= "/>"
</property>
<property name= "City" type= "string" >
<column name= "city" length= "/>"
</property>
<property name= "District" type= "string" >
<column name= "District" length= "/>"
</property>
<property name= "Postcode" type= "string" >
<column name= "postcode" length= "/>"
</property>
<property name= "Shortcode" type= "string" >
<column name= "Shortcode" length= "/>"
</property>
<property name= "Citycode" type= "string" >
<column name= "Citycode" length= "/>"
</property>
<set name= "subareas" table= "Bc_subarea" inverse= "true" lazy= "true" fetch= "select" >
<key>
<column name= "region_id" length= "/>"
</key>
<one-to-many class= "Subarea"/>
</set>
</class>
<?xml version= "1.0"?>
<! DOCTYPE hibernate-mapping Public "-//hibernate/hibernate mapping DTD 3.0//en"
"Http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd" >
<!--Generated 2017-8-15 16:30:28 by Hibernate Tools 4.0.0--
<class name= "Com.hao.bos.entity.Staff" table= "Bc_staff" >
<id name= "id" type= "string" >
<column name= "id" length= "/>"
<generator class= "Assigned"/>
</id>
<property name= "Name" type= "string" >
<column name= "name" length= "/>"
</property>
<property name= "Telephone" type= "string" >
<column name= "Telephone" length= "/>"
</property>
<property name= "HASPDA" type= "Java.lang.Character" >
<column name= "HASPDA" length= "1"/>
</property>
<property name= "Deltag" type= "Java.lang.Character" >
<column name= "Deltag" length= "1"/>
</property>
<property name= "Station" type= "string" >
<column name= "station" length= "Max"/>
</property>
<property name= "Standard" type= "string" >
<column name= "standard" length= "/>"
</property>
<set name= "Decidedzones" table= "Bc_decidedzone" inverse= "true" lazy= "true" fetch= "select" >
<key>
<column name= "staff_id" length= "/>"
</key>
<one-to-many class= "Decidedzone"/>
</set>
</class>
<?xml version= "1.0"?>
<! DOCTYPE hibernate-mapping Public "-//hibernate/hibernate mapping DTD 3.0//en"
"Http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd" >
<!--Generated 2017-8-15 16:30:28 by Hibernate Tools 4.0.0--
<class name= "Com.hao.bos.entity.Subarea" table= "Bc_subarea" >
<id name= "id" type= "string" >
<column name= "id" length= "/>"
<generator class= "Assigned"/>
</id>
<many-to-one name= "Decidedzone" class= "Decidedzone" fetch= "select" >
<column name= "decidedzone_id" length= "/>"
</many-to-one>
<many-to-one name= "Region" class= "Region" fetch= "select" >
<column name= "region_id" length= "/>"
</many-to-one>
<property name= "Addresskey" type= "string" >
<column name= "Addresskey" length= "/>"
</property>
<property name= "Startnum" type= "string" >
<column name= "Startnum" length= "/>"
</property>
<property name= "Endnum" type= "string" >
<column name= "Endnum" length= "/>"
</property>
<property name= "single" Type= "Java.lang.Character" >
<column name= "single" length= "1"/>
</property>
<property name= "Position" type= "string" >
<column name= "position"/>
</property>
</class>
011 Hibernate reverse Engineering Building entities and HBM files-Bos