KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > test > ejb > jdo > Staff


1 package test.ejb.jdo;
2
3 import java.util.Date JavaDoc;
4
5 /**
6  * A simple test class to test for generation of Castor's mapping.xml.
7  *
8  * @castor.class
9  * id="id"
10  * table="staff"
11  * @author Dmitri Colebatch (dim@bigpond.net.au)
12  */

13 public class Staff
14 {
15     private int id;
16     private String JavaDoc name;
17     private Date JavaDoc startDate;
18
19     /**
20      * @castor.field
21      * @castor.field-sql
22      * type="integer"
23      * @castor.field-xml
24      */

25     public int getId()
26     {
27         return id;
28     }
29
30     public void setId(int id)
31     {
32         this.id = id;
33     }
34
35     /**
36      * @castor.field
37      * @castor.field-sql
38      * type="varchar"
39      * @castor.field-xml
40      */

41     public String JavaDoc getName()
42     {
43         return name;
44     }
45
46     public void setName(String JavaDoc name)
47     {
48         this.name = name;
49     }
50
51     /**
52      * @castor.field
53      * @castor.field-sql
54      * type="date"
55      * @castor.field-xml
56      */

57     public Date JavaDoc getStartDate()
58     {
59         return startDate;
60     }
61
62     public void setStartDate(Date JavaDoc startDate)
63     {
64         this.startDate = startDate;
65     }
66 }
67
Popular Tags