KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > demo > drupal > persistence > History


1 package demo.drupal.persistence;
2
3 import javax.persistence.Id;
4 import javax.persistence.Entity;
5 import javax.persistence.Table;
6
7 @Entity
8 @Table(name="history")
9 public class History {
10   /**
11    * CREATE TABLE `history` (
12    * `uid` int(10) NOT NULL default '0',
13    * `nid` int(10) NOT NULL default '0',
14    * `timestamp` int(11) NOT NULL default '0',
15    * PRIMARY KEY (`uid`,`nid`)
16    * );
17    */

18
19   @Id
20   private int uid;
21   @Id
22   private int nid;
23
24   private int timestamp;
25 }
26
Popular Tags