annotate backend/src/main/java/org/dive4elements/river/model/Attribute.java @ 9563:3955ecc1a516

Restrict inundation map to selected river range
author gernotbelger
date Mon, 29 Oct 2018 17:57:30 +0100
parents 1614cb14308f
children
rev   line source
5844
4dd33b86dc61 Added header to river backend.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
1 /* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
4dd33b86dc61 Added header to river backend.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
2 * Software engineering by Intevation GmbH
4dd33b86dc61 Added header to river backend.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
3 *
5992
4c3ccf2b0304 Removed trailing whitespace.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5844
diff changeset
4 * This file is Free Software under the GNU AGPL (>=v3)
5844
4dd33b86dc61 Added header to river backend.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
5 * and comes with ABSOLUTELY NO WARRANTY! Check out the
5992
4c3ccf2b0304 Removed trailing whitespace.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5844
diff changeset
6 * documentation coming with Dive4Elements River for details.
5844
4dd33b86dc61 Added header to river backend.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
7 */
4dd33b86dc61 Added header to river backend.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5838
diff changeset
8
5829
18619c1e7c2a Repaired internal references.
Sascha L. Teichmann <teichmann@intevation.de>
parents: 5828
diff changeset
9 package org.dive4elements.river.model;
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
10
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
11 import java.io.Serializable;
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
12 import java.util.List;
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
13
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
14 import javax.persistence.Column;
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
15 import javax.persistence.Entity;
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
16 import javax.persistence.GeneratedValue;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
17 import javax.persistence.GenerationType;
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
18 import javax.persistence.Id;
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
19 import javax.persistence.SequenceGenerator;
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
20 import javax.persistence.Table;
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
21 import javax.persistence.Transient;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
22
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
23 import org.dive4elements.river.backend.SessionHolder;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
24 import org.hibernate.Query;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
25 import org.hibernate.Session;
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
26
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
27 @Entity
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
28 @Table(name = "attributes")
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
29 public class Attribute
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
30 implements Serializable
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
31 {
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
32
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
33 /***** TYPES *****/
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
34
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
35 /**
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
36 * River attribute (river side or range type)
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
37 *
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
38 */
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
39 public enum AttributeKey {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
40 NONE(""), STRECKE(">>>>>>>>>>>>>>>"), LEFT("links"), RIGHT("rechts"), UNKNOWN("?");
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
41
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
42 private final String name;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
43 private int id;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
44 private boolean ready;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
45
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
46 AttributeKey(final String name) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
47 this.name = name;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
48 this.id = 0;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
49 this.ready = false;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
50 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
51
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
52 /**
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
53 * Type name in the database
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
54 */
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
55 public String getName() {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
56 return this.name;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
57 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
58
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
59 /**
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
60 * Type id in the database
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
61 */
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
62 public int getId() {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
63 initFromDatabase();
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
64 return this.id;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
65 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
66
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
67 /**
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
68 * Set the type id
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
69 */
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
70 public void setId(final int id) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
71 this.id = id;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
72 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
73
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
74 protected boolean getReady() {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
75 return this.ready;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
76 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
77
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
78 protected void setReady(final boolean ready) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
79 this.ready = ready;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
80 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
81
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
82 /**
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
83 * Main value type key for a database name value
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
84 */
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
85 public static AttributeKey forDbName(final String dbname) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
86 initFromDatabase();
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
87 for (final AttributeKey k : AttributeKey.values()) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
88 if (k.getName().equalsIgnoreCase(dbname))
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
89 return k;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
90 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
91 return UNKNOWN;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
92 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
93
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
94 /**
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
95 * Main value type key for a database id value
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
96 */
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
97 public static AttributeKey forDbId(final int dbid) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
98 initFromDatabase();
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
99 for (final AttributeKey k : AttributeKey.values()) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
100 if (k.getId() == dbid)
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
101 return k;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
102 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
103 return UNKNOWN;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
104 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
105
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
106 /**
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
107 * Initially queries the database ids
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
108 */
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
109 private static void initFromDatabase() {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
110 if (STRECKE.getReady())
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
111 return;
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
112 // Avoid recursion
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
113 for (final AttributeKey k : AttributeKey.values())
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
114 k.setReady(true);
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
115 // Select database ids
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
116 final Session session = SessionHolder.HOLDER.get();
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
117 final Query query = session.createQuery("FROM Attribute");
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
118 final List<Attribute> rows = query.list();
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
119 if (!rows.isEmpty()) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
120 for (int i = 0; i <= rows.size() - 1; i++) {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
121 if (forDbName(rows.get(i).getValue()) != UNKNOWN)
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
122 forDbName(rows.get(i).getValue()).setId(rows.get(i).getId());
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
123 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
124 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
125 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
126 }
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
127
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
128 /***** FIELDS *****/
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
129
172
605320b7df94 Added column annotations for simple fields. TODO: foreign keys.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 171
diff changeset
130 private Integer id;
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
131
172
605320b7df94 Added column annotations for simple fields. TODO: foreign keys.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 171
diff changeset
132 private String value;
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
133
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
134 public Attribute() {
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
135 }
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
136
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
137 /***** CONSTRUCTORS *****/
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
138
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
139 public Attribute(final String value) {
187
ecf90018563b Importer: Bound Attributes and Positions to there backend peers.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 172
diff changeset
140 this.value = value;
ecf90018563b Importer: Bound Attributes and Positions to there backend peers.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 172
diff changeset
141 }
ecf90018563b Importer: Bound Attributes and Positions to there backend peers.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 172
diff changeset
142
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
143 /***** METHODS *****/
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
144
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
145 @Id
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
146 @SequenceGenerator(
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
147 name = "SEQUENCE_ATTRIBUTES_ID_SEQ",
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
148 sequenceName = "ATTRIBUTES_ID_SEQ",
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
149 allocationSize = 1)
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
150 @GeneratedValue(
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
151 strategy = GenerationType.SEQUENCE,
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
152 generator = "SEQUENCE_ATTRIBUTES_ID_SEQ")
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
153 @Column(name = "id")
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
154 public Integer getId() {
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
155 return this.id;
171
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
156 }
4a83e14f40f9 Added entity and id annotations.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 168
diff changeset
157
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
158 public void setId(final Integer id) {
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
159 this.id = id;
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
160 }
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
161
172
605320b7df94 Added column annotations for simple fields. TODO: foreign keys.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 171
diff changeset
162 @Column(name = "value")
605320b7df94 Added column annotations for simple fields. TODO: foreign keys.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 171
diff changeset
163 public String getValue() {
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
164 return this.value;
172
605320b7df94 Added column annotations for simple fields. TODO: foreign keys.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 171
diff changeset
165 }
605320b7df94 Added column annotations for simple fields. TODO: foreign keys.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents: 171
diff changeset
166
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
167 public void setValue(final String value) {
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
168 this.value = value;
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
169 }
9176
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
170
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
171 @Transient
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
172 public AttributeKey getKey() {
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
173 return AttributeKey.forDbId(this.getId());
1614cb14308f Work on calculations for S-Info flood duration workflow
mschaefer
parents: 5992
diff changeset
174 }
167
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
175 }
15d515fe15f5 Added POJOs to be mapped to schema.
Sascha L. Teichmann <sascha.teichmann@intevation.de>
parents:
diff changeset
176 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 :

http://dive4elements.wald.intevation.org