WIP:site
[hibernate4-maven-plugin] / schemaexport / domain / Department.java
1 package de.test.schemaexport.domain;\r
2 \r
3 import javax.persistence.Column;\r
4 import javax.persistence.Entity;\r
5 import javax.persistence.GeneratedValue;\r
6 import javax.persistence.GenerationType;\r
7 import javax.persistence.Id;\r
8 import javax.persistence.Table;\r
9 import org.hibernate.annotations.Type;\r
10 \r
11 /**\r
12  * Abteilungsklasse (Generator-Beispielcode).\r
13  * \r
14  * copyright\r
15  *\r
16  */\r
17 @Entity\r
18 @Table(name = "ABTEILUNG")\r
19 public class Department {\r
20 \r
21         @Id\r
22         @Column(name = "OID")\r
23         @GeneratedValue(strategy = GenerationType.AUTO)\r
24         private long oid;\r
25         \r
26         @Column(name = "name", nullable = false)\r
27         private String name;\r
28 \r
29         @Type(type = "genderType")\r
30         private Gender gender;\r
31 \r
32         public long getOid() {\r
33                 return oid;\r
34         }\r
35 \r
36         public void setOid(long oid) {\r
37                 this.oid = oid;\r
38         }\r
39 \r
40         public String getName() {\r
41                 return name;\r
42         }\r
43 \r
44         public void setName(String name) {\r
45                 this.name = name;\r
46         }\r
47         \r
48         \r
49         \r
50 }\r