Mercurial > dive4elements > river
comparison flys-client/src/main/java/de/intevation/flys/client/shared/model/DefaultDataItem.java @ 12:fa0aad20af53
Adjusted interfaces used for the ArtifactDescription and added default implementations.
flys-client/trunk@1321 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Thu, 17 Feb 2011 08:31:33 +0000 |
parents | |
children | 2c48d75c4ab7 |
comparison
equal
deleted
inserted
replaced
11:6aeb4072eeb4 | 12:fa0aad20af53 |
---|---|
1 package de.intevation.flys.client.shared.model; | |
2 | |
3 | |
4 /** | |
5 * The default implementation of a {@link DataItem}. This class just implements | |
6 * constructors to create instances and the necessary methods of the interface. | |
7 * | |
8 * @author <a href="mailto:ingo.weinzierl@intevation.de">Ingo Weinzierl</a> | |
9 */ | |
10 public class DefaultDataItem implements DataItem { | |
11 | |
12 /** The label.*/ | |
13 protected String label; | |
14 | |
15 /** The description.*/ | |
16 protected String description; | |
17 | |
18 /** The value.*/ | |
19 protected String value; | |
20 | |
21 | |
22 public DefaultDataItem() { | |
23 } | |
24 | |
25 | |
26 /** | |
27 * The default constructor to create new instances. | |
28 * | |
29 * @param label The label. | |
30 * @param description The description. | |
31 * @param value The value. | |
32 */ | |
33 public DefaultDataItem(String label, String description, String value) { | |
34 this.label = label; | |
35 this.description = description; | |
36 this.value = value; | |
37 } | |
38 | |
39 | |
40 public String getLabel() { | |
41 return label; | |
42 } | |
43 | |
44 | |
45 public String getDescription() { | |
46 return description; | |
47 } | |
48 | |
49 | |
50 public String getStringValue() { | |
51 return value; | |
52 } | |
53 } | |
54 // vim:set ts=4 sw=4 si et sta sts=4 fenc=utf8 : |