annotate gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultInputData.java @ 605:e8ebdbc7f1e3

First step of removing the cache blob. The static part of the describe document will be created by using the input data stored at each state. Some TODOs left (see ChangeLog). gnv-artifacts/trunk@671 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Tue, 09 Feb 2010 14:27:55 +0000
parents 9681ac6b6527
children 292fbcd5e9ac
rev   line source
335
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
1 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
2 *
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
3 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
4 package de.intevation.gnv.state;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
5
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
6 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
7 * @author Tim Englich <tim.englich@intevation.de>
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
8 *
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
9 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
10 public class DefaultInputData implements InputData {
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
11
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
12 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
13 *
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
14 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
15 private static final long serialVersionUID = 4308041648698108066L;
598
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
16
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
17 private final static String VALUE_SEPARATOR = " , ";
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
18
335
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
19 private String name = null;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
20 private String value = null;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
21
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
22 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
23 * Constructor
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
24 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
25 public DefaultInputData(String name, String value) {
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
26 this.name = name;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
27 this.value = value;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
28 }
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
29
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
30 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
31 * @see de.intevation.gnv.state.InputData#getName()
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
32 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
33 public String getName() {
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
34 return this.name;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
35 }
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
36
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
37 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
38 * @see de.intevation.gnv.state.InputData#getValue()
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
39 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
40 public String getValue() {
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
41 return this.value;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
42 }
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
43
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
44 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
45 * @see java.lang.Object#toString()
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
46 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
47 @Override
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
48 public String toString() {
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
49 return this.name + "==> " + this.value;
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
50 }
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
51
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
52 /**
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
53 * @see de.intevation.gnv.state.InputData#concartValue(java.lang.String)
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
54 */
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
55 public void concartValue(String value) {
598
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
56 this.value = this.value + VALUE_SEPARATOR + value;
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
57 }
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
58
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
59 /**
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
60 * @see de.intevation.gnv.state.InputData#splitValue()
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
61 */
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
62 public String[] splitValue() {
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
63 if (this.value != null){
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
64 return this.value.split(VALUE_SEPARATOR);
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
65 }
9681ac6b6527 Added the possibility to use the data which are send using the MapServer-Interface during the Workflow of the GNV-Artifacts.
Tim Englich <tim.englich@intevation.de>
parents: 335
diff changeset
66 return null;
335
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
67 }
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
68
e964a3d8f7bc Some Refactoring work done.
Tim Englich <tim.englich@intevation.de>
parents:
diff changeset
69 }

http://dive4elements.wald.intevation.org