Mercurial > dive4elements > river
comparison flys-backend/src/main/java/org/dive4elements/river/model/SedimentDensityValue.java @ 5828:dfb26b03b179
Moved directories to org.dive4elements.river
author | Sascha L. Teichmann <teichmann@intevation.de> |
---|---|
date | Thu, 25 Apr 2013 11:53:11 +0200 |
parents | flys-backend/src/main/java/de/intevation/flys/model/SedimentDensityValue.java@db6c7268b08e |
children | 18619c1e7c2a |
comparison
equal
deleted
inserted
replaced
5827:e308d4ecd35a | 5828:dfb26b03b179 |
---|---|
1 package de.intevation.flys.model; | |
2 | |
3 import java.io.Serializable; | |
4 import java.math.BigDecimal; | |
5 | |
6 import javax.persistence.Entity; | |
7 import javax.persistence.Id; | |
8 import javax.persistence.Table; | |
9 import javax.persistence.GeneratedValue; | |
10 import javax.persistence.Column; | |
11 import javax.persistence.SequenceGenerator; | |
12 import javax.persistence.GenerationType; | |
13 import javax.persistence.JoinColumn; | |
14 import javax.persistence.OneToOne; | |
15 | |
16 | |
17 @Entity | |
18 @Table(name = "sediment_density_values") | |
19 public class SedimentDensityValue implements Serializable { | |
20 | |
21 private Integer id; | |
22 | |
23 private SedimentDensity sedimentDensity; | |
24 | |
25 private BigDecimal station; | |
26 private BigDecimal shoreOffset; | |
27 private BigDecimal density; | |
28 private BigDecimal year; | |
29 | |
30 private String description; | |
31 | |
32 | |
33 public SedimentDensityValue() { | |
34 } | |
35 | |
36 | |
37 public SedimentDensityValue( | |
38 SedimentDensity sedimentDensity, | |
39 BigDecimal station, | |
40 BigDecimal shoreOffset, | |
41 BigDecimal density, | |
42 BigDecimal year, | |
43 String desc | |
44 ) { | |
45 this.sedimentDensity = sedimentDensity; | |
46 this.station = station; | |
47 this.shoreOffset = shoreOffset; | |
48 this.density = density; | |
49 this.year = year; | |
50 this.description = desc; | |
51 } | |
52 | |
53 @Id | |
54 @SequenceGenerator( | |
55 name = "SEQUENCE_SEDIMENT_DENSITY_VALUES_ID_SEQ", | |
56 sequenceName = "SEDIMENT_DENSITY_VALUES_ID_SEQ", | |
57 allocationSize = 1) | |
58 @GeneratedValue( | |
59 strategy = GenerationType.SEQUENCE, | |
60 generator = "SEQUENCE_SEDIMENT_DENSITY_VALUES_ID_SEQ") | |
61 @Column(name = "id") | |
62 public Integer getId() { | |
63 return id; | |
64 } | |
65 | |
66 public void setId(Integer id) { | |
67 this.id = id; | |
68 } | |
69 | |
70 @OneToOne | |
71 @JoinColumn(name = "sediment_density_id") | |
72 public SedimentDensity getSedimentDensity() { | |
73 return sedimentDensity; | |
74 } | |
75 | |
76 public void setSedimentDensity(SedimentDensity sedimentDensity) { | |
77 this.sedimentDensity = sedimentDensity; | |
78 } | |
79 | |
80 @Column(name = "station") | |
81 public BigDecimal getStation() { | |
82 return station; | |
83 } | |
84 | |
85 public void setStation(BigDecimal station) { | |
86 this.station = station; | |
87 } | |
88 | |
89 @Column(name = "shore_offset") | |
90 public BigDecimal getShoreOffset() { | |
91 return shoreOffset; | |
92 } | |
93 | |
94 public void setShoreOffset(BigDecimal shoreOffset) { | |
95 this.shoreOffset = shoreOffset; | |
96 } | |
97 | |
98 @Column(name = "density") | |
99 public BigDecimal getDensity() { | |
100 return density; | |
101 } | |
102 | |
103 public void setDensity(BigDecimal density) { | |
104 this.density = density; | |
105 } | |
106 | |
107 @Column(name = "description") | |
108 public String getDescription() { | |
109 return description; | |
110 } | |
111 | |
112 public void setDescription(String description) { | |
113 this.description = description; | |
114 } | |
115 | |
116 @Column(name = "year") | |
117 public BigDecimal getYear() { | |
118 return year; | |
119 } | |
120 | |
121 public void setYear(BigDecimal year) { | |
122 this.year = year; | |
123 } | |
124 } | |
125 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 : |