KickJava   Java API By Example, From Geeks To Geeks.

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


1 package demo.drupal.persistence;
2
3 import javax.persistence.Table;
4
5 // XXX: no primary key @Entity
6
@Table(name="search_index")
7 public class SearchIndex {
8   /**
9    * CREATE TABLE `search_index` (
10    * `word` varchar(50) NOT NULL default '',
11    * `sid` int(10) unsigned NOT NULL default '0',
12    * `type` varchar(16) default NULL,
13    * `fromsid` int(10) unsigned NOT NULL default '0',
14    * `fromtype` varchar(16) default NULL,
15    * `score` float default NULL,
16    * KEY `sid_type` (`sid`,`type`),
17    * KEY `from_sid_type` (`fromsid`,`fromtype`),
18    * KEY `word` (`word`)
19    * );
20    */

21
22   private String JavaDoc word;
23   private int sid;
24   private String JavaDoc type;
25   private int fromsid;
26   private String JavaDoc fromtype;
27   private float score;
28 }
29
Popular Tags