]> SALOME platform Git repositories - tools/siman.git/blob - Workspace/Siman-Common/src/org/splat/dal/bo/som/Document.hbm.xml
Salome HOME
StepServiceImpl doesn't use Database class anymore.
[tools/siman.git] / Workspace / Siman-Common / src / org / splat / dal / bo / som / Document.hbm.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 3.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" >
3 <!--
4   - Mapping of the Document class and its type information implemented by the DocumentType class.
5   -
6   - @author    Daniel Brunier-Coulin
7   - @copyright OPEN CASCADE 2012
8   -->
9
10 <hibernate-mapping>
11
12 <!--   <class name="org.splat.dal.bo.som.Document" table="document" lazy="false"> -->
13         <union-subclass name="org.splat.dal.bo.som.Document" extends="org.splat.dal.bo.kernel.Entity" table="document" lazy="false">
14 <!-- Properties inherited from Entity
15   -->
16     <!-- <id name="rid" type="int" column="rid" unsaved-value="0" access="field">
17       <generator class="org.splat.dal.bo.kernel.IDGenerator"/>
18     </id>
19     
20     <set name="attributes" inverse="true" lazy="false" cascade="all-delete-orphan" access="field">
21       <key         column="owner" />
22       <one-to-many class="org.splat.dal.bo.kernel.Attribute" />
23     </set> 
24     <set name="relations" inverse="true" lazy="false" cascade="all-delete-orphan" access="field">
25       <key         column="owner" />
26       <one-to-many class="org.splat.dal.bo.kernel.Relation" />
27     </set>-->
28   
29 <!-- Document properties
30   -
31   -      String        did       -->
32     <property name="did"       column="did"     access="field" not-null="true" />    
33     
34     <!-- DocumentType  type      -->    
35     <many-to-one name="type"   column="type"    access="field" not-null="true" />
36     
37     <!-- File          myfile    -->    
38     <many-to-one name="myfile" column="myfile" unique="true" cascade="all-delete-orphan" access="field" not-null="true" />
39     
40     <!-- String        name      -->    
41     <property name="name"      column="name"    access="field" not-null="true" />
42   
43     <!-- ProgressState state     -->
44     <property name="state"     column="state" type="ProgressState" access="field" not-null="true" />    
45     
46     <!-- int           step      -->    
47     <property name="step"      column="step"    access="field" not-null="true" />
48     
49     <!-- String        version   -->    
50     <property name="version"   column="version" access="field" />
51     
52     <!-- int           countag   -->    
53     <property name="countag"   column="countag" access="field" not-null="true" />
54     
55     <!-- int           history   -->    
56     <property name="history"   column="history" access="field" not-null="true" />
57   
58     <!-- User          author    -->    
59     <many-to-one name="author" column="author" access="field" not-null="true" />
60     
61     <!-- Date          lasdate   -->    
62     <property name="lasdate"   column="lasdate" access="field" not-null="true" />
63   </union-subclass>
64
65 <!-- Class DocumentType 
66   -->
67   <class name="org.splat.dal.bo.som.DocumentType" table="doctype" lazy="false">
68     <id name="rid" column="rid" access="field">
69       <generator class="increment"/>
70     </id>
71     <property name="name"   column="name"    access="field" not-null="true" />
72     <property name="state"  column="state" type="ProgressState" access="field" not-null="true" />    
73     <property name="step"   column="step"    access="field" not-null="true" />
74     <property name="result" column="result"  access="field" />
75     <set name="uses" table="docuse" lazy="false" access="field">
76       <key          column="owner" />
77       <many-to-many column="rid" class="org.splat.dal.bo.som.DocumentType" />
78     </set>
79   </class>
80   
81 </hibernate-mapping>