<?xml version="1.0" encoding="GBK"?><!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 2.0//EN" "">
<hibernate-mapping>
<class name="javamxj.inheritance.two.Vehicle"
dynamic-update="false" dynamic-insert="false"
select-before-update="false" optimistic-lock="version"
>
<id name="id" column="ID" type="java.lang.Long"
unsaved-value="null"
>
<generator class="hilo">
<!-- To add non XDoclet generator parameters,
create a file named hibernate-generator-params-
Vehicle.xml containing the additional parameters
and place it in your merge dir.
-->
</generator>
</id>
<property name="name" type="java.lang.String" update="true"
insert="true" access="property" column="name"
length="24" />
<!-- To add non XDoclet property mappings, create a file named
hibernate-properties-Vehicle.xml containing the additional
properties and place it in your merge dir.
-->
<joined-subclass name="javamxj.inheritance.two.Truck"
dynamic-update="false" dynamic-insert="false"
>
<key column="id" />
<property name="load" type="java.lang.String" update="true"
insert="true" access="property" column="载重"
length="24"
/>
</joined-subclass>
<joined-subclass name="javamxj.inheritance.two.Car"
dynamic-update="false" dynamic-insert="false"
>
<key column="id" />
<property name="seat" type="java.lang.String"
update="true" insert="true" access="property"
column="载客" length="24"
/>
</joined-subclass>
</class>
</hibernate-mapping>
|