1 package org.lsst.ccs.localdb.statusdb.model;
2
3 import javax.persistence.Column;
4 import javax.persistence.Entity;
5 import javax.persistence.GeneratedValue;
6 import javax.persistence.GenerationType;
7 import javax.persistence.Id;
8 import javax.persistence.ManyToOne;
9 import javax.persistence.Table;
10
11 @Entity
12 @org.hibernate.annotations.Entity(dynamicUpdate = true, dynamicInsert = true)
13 @Table(name = "statdesc")
14 public class StatDesc {
15
16 private long id;
17 private DataDesc rawDescr;
18 private long timeBinWidth;
19 private long preservationDelay;
20
21
22
23
24 @Id()
25 @GeneratedValue(strategy = GenerationType.AUTO)
26 public long getId() {
27 return id;
28 }
29
30
31
32
33 public void setId(long id) {
34 this.id = id;
35 }
36
37
38
39
40 @ManyToOne
41 public DataDesc getRawDescr() {
42 return rawDescr;
43 }
44
45
46
47
48 public void setRawDescr(DataDesc rawDescr) {
49 this.rawDescr = rawDescr;
50 }
51
52
53
54
55 public long getTimeBinWidth() {
56 return timeBinWidth;
57 }
58
59
60
61
62 public void setTimeBinWidth(long timeBinWidth) {
63 this.timeBinWidth = timeBinWidth;
64 }
65
66
67
68
69 @Column(columnDefinition = "int default 0")
70 public long getPreservationDelay() {
71 return preservationDelay;
72 }
73
74
75
76
77 public void setPreservationDelay(long preservationDelay) {
78 this.preservationDelay = preservationDelay;
79 }
80 }