comparison gnv-artifacts/src/main/java/de/intevation/gnv/state/DefaultInputValue.java @ 335:e964a3d8f7bc

Some Refactoring work done. Moved Transition to State gnv-artifacts/trunk@401 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Tim Englich <tim.englich@intevation.de>
date Tue, 08 Dec 2009 08:39:03 +0000
parents
children 9a828e5a2390
comparison
equal deleted inserted replaced
334:e37930705daa 335:e964a3d8f7bc
1 /**
2 *
3 */
4 package de.intevation.gnv.state;
5
6 /**
7 * @author Tim Englich <tim.englich@intevation.de>
8 *
9 */
10 public class DefaultInputValue implements InputValue {
11
12 /**
13 * The UID of this Class.
14 */
15 private static final long serialVersionUID = -8518824299166180986L;
16 private String name = null;
17 private String type = null;
18 private boolean multiselect = false;
19 private int usedInQueries = 1;
20 private String defaultValue = "N/N";
21
22 public DefaultInputValue(String name, String type, String defaultValue,
23 boolean multiselect) {
24 this(name, type, multiselect, 1);
25 this.defaultValue = defaultValue;
26
27 }
28
29 /**
30 * Constructor
31 */
32 public DefaultInputValue(String name, String type, boolean multiselect,
33 int usedInQueries) {
34 this.name = name;
35 this.type = type;
36 this.multiselect = multiselect;
37 this.usedInQueries = usedInQueries;
38 }
39
40 /**
41 * @see de.intevation.gnv.state.InputValue#getName()
42 */
43 public String getName() {
44 return this.name;
45 }
46
47 /**
48 * @see de.intevation.gnv.state.InputValue#getType()
49 */
50 public String getType() {
51 return this.type;
52 }
53
54 /**
55 * @see java.lang.Object#toString()
56 */
57 @Override
58 public String toString() {
59 return "InputValue " + this.name + " ==> " + this.type
60 + "==> multiselect: " + this.multiselect;
61 }
62
63 /**
64 * @see de.intevation.gnv.state.InputValue#isMultiselect()
65 */
66 public boolean isMultiselect() {
67 return this.multiselect;
68 }
69
70 public int usedInQueries() {
71 return this.usedInQueries;
72 }
73
74 public String getDefaultValue() {
75 return this.defaultValue;
76 }
77
78 }

http://dive4elements.wald.intevation.org