]> git.somenet.org - pub/jan/dst18.git/blob - ass1-jpa/src/main/resources/META-INF/Material.xml
[2.3.1] working plugin finder and executor.
[pub/jan/dst18.git] / ass1-jpa / src / main / resources / META-INF / Material.xml
1 <?xml version="1.0" encoding="UTF-8"?>
2 <entity-mappings xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
3                  xmlns="http://java.sun.com/xml/ns/persistence/orm"
4                  xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm http://java.sun.com/xml/ns/persistence/orm_2_0.xsd"
5                  version="2.0">
6
7     <description>Mappings for Material</description>
8     <entity name="Material" class="dst.ass1.jpa.model.impl.Material">
9         <entity-listeners>
10             <entity-listener class="dst.ass1.jpa.listener.MaterialListener"/>
11         </entity-listeners>
12         <attributes>
13             <id name="id">
14                 <generated-value/>
15             </id>
16             <basic name="urn">
17                 <column unique="true"/>
18             </basic>
19             <basic name="type"/>
20             <basic name="uploaded">
21                 <temporal>DATE</temporal>
22             </basic>
23             <basic name="lastUpdate">
24                 <temporal>DATE</temporal>
25             </basic>
26             <many-to-one name="lesson" target-entity="dst.ass1.jpa.model.impl.Lesson">
27                 <join-column name="lesson_id"/>
28             </many-to-one>
29             <many-to-many name="materialServers" target-entity="dst.ass1.jpa.model.impl.MaterialServer"
30                           mapped-by="materials"/>
31         </attributes>
32     </entity>
33 </entity-mappings>