View Javadoc

1   package org.lsst.ccs.localdb.statusdb.model;
2   
3   import java.io.Serializable;
4   
5   import javax.persistence.Column;
6   import javax.persistence.Entity;
7   import javax.persistence.GeneratedValue;
8   import javax.persistence.GenerationType;
9   import javax.persistence.Id;
10  import javax.persistence.Table;
11  import javax.persistence.ManyToOne;
12  
13  @Entity
14  @org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
15  @Table(name = "datametadata")
16  public class DataMetaData implements Serializable {
17  
18      private DataDesc rawDescr;
19      private long tstart, tstop = -1;
20      private String name, value;
21      private long id;
22  
23      /**
24       * @return the id
25       */
26      @Id
27      @GeneratedValue(strategy = GenerationType.AUTO)
28      public long getId() {
29          return id;
30      }
31  
32      /**
33       * @param id the id to set
34       */
35      public void setId(long id) {
36          this.id = id;
37      }
38  
39      /**
40       * @return the name
41       */
42      public String getName() {
43          return name;
44      }
45  
46      /**
47       * @param name
48       *            the name to set
49       */
50      public void setName(String name) {
51          this.name = name;
52      }
53  
54      /**
55       * @return the value
56       */
57      public String getValue() {
58          return value;
59      }
60  
61      /**
62       * @param value
63       *            the value to set
64       */
65      public void setValue(String value) {
66          this.value = value;
67      }
68  
69      /**
70       * @return the rawDescr
71       */
72      @ManyToOne
73      public DataDesc getRawDescr() {
74          return rawDescr;
75      }
76  
77      /**
78       * @param rawDescr the rawDescr to set
79       */
80      public void setRawDescr(DataDesc rawDescr) {
81          this.rawDescr = rawDescr;
82      }
83  
84      /**
85       * @return the tstart
86       */
87      @Column(name = "tstartmillis")
88      public long getTstart() {
89          return tstart;
90      }
91  
92      /**
93       * @param tstart the tstart to set
94       */
95      public void setTstart(long tstart) {
96          this.tstart = tstart;
97      }
98  
99      /**
100      * @return the tstop
101      */
102     @Column(name = "tstopmillis")
103     public long getTstop() {
104         return tstop;
105     }
106 
107     /**
108      * @param tstop the tstop to set
109      */
110     public void setTstop(long tstop) {
111         this.tstop = tstop;
112     }
113 }