Mercurial > dive4elements > river
comparison flys-backend/src/main/java/de/intevation/flys/model/HWSLine.java @ 5061:c9ba713a7750 dami
Add HWSLine and HWSPoint to the model
author | Andre Heinecke <aheinecke@intevation.de> |
---|---|
date | Wed, 20 Feb 2013 17:01:42 +0100 |
parents | |
children | fb7c4ad94bd8 |
comparison
equal
deleted
inserted
replaced
5060:c629719b87e7 | 5061:c9ba713a7750 |
---|---|
1 package de.intevation.flys.model; | |
2 | |
3 import java.io.Serializable; | |
4 import java.util.List; | |
5 import java.math.BigDecimal; | |
6 | |
7 import javax.persistence.Column; | |
8 import javax.persistence.Entity; | |
9 import javax.persistence.Id; | |
10 import javax.persistence.JoinColumn; | |
11 import javax.persistence.OneToOne; | |
12 import javax.persistence.Table; | |
13 | |
14 import org.hibernate.Session; | |
15 import org.hibernate.Query; | |
16 | |
17 import de.intevation.flys.backend.SessionHolder; | |
18 | |
19 @Entity | |
20 @Table(name = "hws_lines") | |
21 public class HWSLine implements Serializable { | |
22 | |
23 private Integer id; | |
24 | |
25 private Integer ogr_fid; | |
26 private HWSKind kind; | |
27 private FedState fedState; | |
28 private River river; | |
29 private Integer offical; | |
30 private Integer shore_side; | |
31 private String name; | |
32 private String path; | |
33 private String agency; | |
34 private String range; | |
35 private String source; | |
36 private String status_date; | |
37 private String description; | |
38 private Geometry geom; | |
39 | |
40 @Id | |
41 @Column(name = "id") | |
42 public Integer getId() { | |
43 return id; | |
44 } | |
45 | |
46 public void setId(Integer id) { | |
47 this.id = id; | |
48 } | |
49 | |
50 @Column(name = "geom") | |
51 @Type(type = "org.hibernatespatial.GeometryUserType") | |
52 public Geometry getGeom() { | |
53 return geom; | |
54 } | |
55 | |
56 | |
57 public void setGeom(Geometry geom) { | |
58 this.geom = geom; | |
59 } | |
60 | |
61 /** | |
62 * Get ogr_fid. | |
63 * | |
64 * @return ogr_fid as Integer. | |
65 */ | |
66 @Column(name = "ogr_fid") | |
67 public Integer getOgrFid() | |
68 { | |
69 return ogr_fid; | |
70 } | |
71 | |
72 /** | |
73 * Set ogr_fid. | |
74 * | |
75 * @param ogr_fid the value to set. | |
76 */ | |
77 public void setOgrFid(Integer ogr_fid) | |
78 { | |
79 this.ogr_fid = ogr_fid; | |
80 } | |
81 | |
82 | |
83 /** | |
84 * Get offical. | |
85 * | |
86 * @return offical as Integer. | |
87 */ | |
88 @Column(name = "offical") | |
89 public Integer getOffical() | |
90 { | |
91 return offical; | |
92 } | |
93 | |
94 /** | |
95 * Set offical. | |
96 * | |
97 * @param offical the value to set. | |
98 */ | |
99 public void setOffical(Integer offical) | |
100 { | |
101 this.offical = offical; | |
102 } | |
103 | |
104 /** | |
105 * Get shore_side. | |
106 * | |
107 * @return shore_side as Integer. | |
108 */ | |
109 @Column(name = "shore_side") | |
110 public Integer getShoreSide() | |
111 { | |
112 return shore_side; | |
113 } | |
114 | |
115 /** | |
116 * Set shore_side. | |
117 * | |
118 * @param shore_side the value to set. | |
119 */ | |
120 public void setShoreSide(Integer shore_side) | |
121 { | |
122 this.shore_side = shore_side; | |
123 } | |
124 | |
125 /** | |
126 * Get name. | |
127 * | |
128 * @return name as String. | |
129 */ | |
130 @Column(name = "name") | |
131 public String getName() | |
132 { | |
133 return name; | |
134 } | |
135 | |
136 /** | |
137 * Set name. | |
138 * | |
139 * @param name the value to set. | |
140 */ | |
141 public void setName(String name) | |
142 { | |
143 this.name = name; | |
144 } | |
145 | |
146 /** | |
147 * Get path. | |
148 * | |
149 * @return path as String. | |
150 */ | |
151 @Column(name = "path") | |
152 public String getPath() | |
153 { | |
154 return path; | |
155 } | |
156 | |
157 /** | |
158 * Set path. | |
159 * | |
160 * @param path the value to set. | |
161 */ | |
162 public void setPath(String path) | |
163 { | |
164 this.path = path; | |
165 } | |
166 | |
167 /** | |
168 * Get agency. | |
169 * | |
170 * @return agency as String. | |
171 */ | |
172 @Column(name = "agency") | |
173 public String getAgency() | |
174 { | |
175 return agency; | |
176 } | |
177 | |
178 /** | |
179 * Set agency. | |
180 * | |
181 * @param agency the value to set. | |
182 */ | |
183 public void setAgency(String agency) | |
184 { | |
185 this.agency = agency; | |
186 } | |
187 | |
188 /** | |
189 * Get range. | |
190 * | |
191 * @return range as String. | |
192 */ | |
193 @Column(name = "range") | |
194 public String getRange() | |
195 { | |
196 return range; | |
197 } | |
198 | |
199 /** | |
200 * Set range. | |
201 * | |
202 * @param range the value to set. | |
203 */ | |
204 public void setRange(String range) | |
205 { | |
206 this.range = range; | |
207 } | |
208 | |
209 /** | |
210 * Get source. | |
211 * | |
212 * @return source as String. | |
213 */ | |
214 @Column(name = "source") | |
215 public String getSource() | |
216 { | |
217 return source; | |
218 } | |
219 | |
220 /** | |
221 * Set source. | |
222 * | |
223 * @param source the value to set. | |
224 */ | |
225 public void setSource(String source) | |
226 { | |
227 this.source = source; | |
228 } | |
229 | |
230 /** | |
231 * Get status_date. | |
232 * | |
233 * @return status_date as String. | |
234 */ | |
235 @Column(name = "status_date") | |
236 public String getStatusDate() | |
237 { | |
238 return status_date; | |
239 } | |
240 | |
241 /** | |
242 * Set status_date. | |
243 * | |
244 * @param status_date the value to set. | |
245 */ | |
246 public void setStatusDate(String status_date) | |
247 { | |
248 this.status_date = status_date; | |
249 } | |
250 | |
251 /** | |
252 * Get description. | |
253 * | |
254 * @return description as String. | |
255 */ | |
256 @Column(name = "description") | |
257 public String getDescription() | |
258 { | |
259 return description; | |
260 } | |
261 | |
262 /** | |
263 * Set description. | |
264 * | |
265 * @param description the value to set. | |
266 */ | |
267 public void setDescription(String description) | |
268 { | |
269 this.description = description; | |
270 } | |
271 | |
272 /** | |
273 * Get kind. | |
274 * | |
275 * @return kind as HWSKind. | |
276 */ | |
277 @OneToOne | |
278 @JoinColumn(name = "kind_id") | |
279 public HWSKind getKind() | |
280 { | |
281 return kind; | |
282 } | |
283 | |
284 /** | |
285 * Set kind. | |
286 * | |
287 * @param kind the value to set. | |
288 */ | |
289 public void setKind(HWSKind kind) | |
290 { | |
291 this.kind = kind; | |
292 } | |
293 | |
294 /** | |
295 * Get fedState. | |
296 * | |
297 * @return fedState as FedState. | |
298 */ | |
299 @OneToOne | |
300 @JoinColumn(name = "fed_state_id") | |
301 public FedState getFedState() | |
302 { | |
303 return fedState; | |
304 } | |
305 | |
306 /** | |
307 * Set fedState. | |
308 * | |
309 * @param fedState the value to set. | |
310 */ | |
311 public void setFedState(FedState fedState) | |
312 { | |
313 this.fedState = fedState; | |
314 } | |
315 | |
316 /** | |
317 * Get river. | |
318 * | |
319 * @return river as River. | |
320 */ | |
321 @OneToOne | |
322 @JoinColumn(name = "river_id") | |
323 public River getRiver() | |
324 { | |
325 return river; | |
326 } | |
327 | |
328 /** | |
329 * Set river. | |
330 * | |
331 * @param river the value to set. | |
332 */ | |
333 public void setRiver(River river) | |
334 { | |
335 this.river = river; | |
336 } | |
337 } |