Mercurial > dive4elements > river
comparison flys-artifacts/src/main/java/de/intevation/flys/artifacts/AreaArtifact.java @ 2018:3f1a63da2cf4
Prepare ability to paint areas in longitudinal section diagrams, too (next to CrossSection diagrams).
flys-artifacts/trunk@3473 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Tue, 20 Dec 2011 06:37:41 +0000 |
parents | 7f99845e9499 |
children | 3c3693e9c538 |
comparison
equal
deleted
inserted
replaced
2017:e384d78ff78b | 2018:3f1a63da2cf4 |
---|---|
33 public static final String XPATH_IDS = "/art:action/art:ids/@value"; | 33 public static final String XPATH_IDS = "/art:action/art:ids/@value"; |
34 | 34 |
35 /** Name of Artifact. */ | 35 /** Name of Artifact. */ |
36 public static final String AREA_ARTIFACT_NAME = "area_artifact"; | 36 public static final String AREA_ARTIFACT_NAME = "area_artifact"; |
37 | 37 |
38 /** Dataitem: Facet name. Facets with this name will be created (important | |
39 * to not have the area calculated in e.g. a CrossSection to be shown in | |
40 * LongitudinalSection. */ | |
41 protected static final String FACET_NAME = "area.facet"; | |
42 | |
38 /** Name of state. */ | 43 /** Name of state. */ |
39 public static final String STATIC_STATE_NAME = "state.area_artifact"; | 44 public static final String STATIC_STATE_NAME = "state.area_artifact"; |
40 | 45 |
41 /** data item name to access upper curve. */ | 46 /** data item name to access upper curve. */ |
42 public static final String AREA_CURVE_OVER = "area.curve_over"; | 47 protected static final String AREA_CURVE_OVER = "area.curve_over"; |
43 | 48 |
44 /** data item name to access lower curve. */ | 49 /** data item name to access lower curve. */ |
45 public static final String AREA_CURVE_UNDER = "area.curve_under"; | 50 protected static final String AREA_CURVE_UNDER = "area.curve_under"; |
46 | 51 |
47 /** Name of state. */ | 52 /** Name of state. */ |
48 public static final String AREA_NAME = "area.name"; | 53 protected static final String AREA_NAME = "area.name"; |
49 | 54 |
50 /** Own logger. */ | 55 /** Own logger. */ |
51 private static final Logger logger = | 56 private static final Logger logger = |
52 Logger.getLogger(AreaArtifact.class); | 57 Logger.getLogger(AreaArtifact.class); |
53 | 58 |
74 | 79 |
75 // TODO yet unused. | 80 // TODO yet unused. |
76 String ids = XMLUtils.xpathString( | 81 String ids = XMLUtils.xpathString( |
77 data, XPATH_IDS, ArtifactNamespaceContext.INSTANCE); | 82 data, XPATH_IDS, ArtifactNamespaceContext.INSTANCE); |
78 | 83 |
84 // TODO this facet will be remodeled during next feed. | |
79 List<Facet> fs = new ArrayList<Facet>(); | 85 List<Facet> fs = new ArrayList<Facet>(); |
80 fs.add(new AreaFacet(0, "TODO: I am an AreaFacet")); | 86 fs.add(new AreaFacet(0, "", "TODO: I am an AreaFacet")); |
81 | 87 |
82 AreaCreationState state = (AreaCreationState) getCurrentState(context); | 88 AreaCreationState state = (AreaCreationState) getCurrentState(context); |
83 | 89 |
84 if (!fs.isEmpty()) { | 90 if (!fs.isEmpty()) { |
85 facets.put(getCurrentStateId(), fs); | 91 facets.put(getCurrentStateId(), fs); |
96 CallMeta callMeta) | 102 CallMeta callMeta) |
97 { | 103 { |
98 // do nothing | 104 // do nothing |
99 } | 105 } |
100 | 106 |
107 /** | |
108 * Get name of facets to create. | |
109 */ | |
110 public String getFacetName() { | |
111 return getDataAsString(FACET_NAME); | |
112 } | |
101 | 113 |
102 /** | 114 /** |
103 * Get dataprovider key for the 'lower' curve (we got that information fed | 115 * Get dataprovider key for the 'lower' curve (we got that information fed |
104 * from the client and store it as data). | 116 * from the client and store it as data). |
105 */ | 117 */ |