comparison artifacts/src/main/java/org/dive4elements/river/exports/minfo/SedimentLoadLSGenerator.java @ 5867:59ff03ff48f1

River artifacts: Renamed FLYSArtifact(Collection) to D4EArtifact(Collection).
author Sascha L. Teichmann <teichmann@intevation.de>
date Sun, 28 Apr 2013 15:23:01 +0200
parents f2e46a668fe6
children af13ceeba52a
comparison
equal deleted inserted replaced
5866:9a6741ccf6d4 5867:59ff03ff48f1
14 import org.jfree.data.xy.XYSeries; 14 import org.jfree.data.xy.XYSeries;
15 import org.w3c.dom.Document; 15 import org.w3c.dom.Document;
16 16
17 import org.dive4elements.artifactdatabase.state.ArtifactAndFacet; 17 import org.dive4elements.artifactdatabase.state.ArtifactAndFacet;
18 import org.dive4elements.artifactdatabase.state.Facet; 18 import org.dive4elements.artifactdatabase.state.Facet;
19 import org.dive4elements.river.artifacts.FLYSArtifact; 19 import org.dive4elements.river.artifacts.D4EArtifact;
20 import org.dive4elements.river.artifacts.access.RangeAccess; 20 import org.dive4elements.river.artifacts.access.RangeAccess;
21 import org.dive4elements.river.artifacts.access.SedimentLoadAccess; 21 import org.dive4elements.river.artifacts.access.SedimentLoadAccess;
22 import org.dive4elements.river.artifacts.model.FacetTypes; 22 import org.dive4elements.river.artifacts.model.FacetTypes;
23 import org.dive4elements.river.artifacts.model.FlowVelocityData; 23 import org.dive4elements.river.artifacts.model.FlowVelocityData;
24 import org.dive4elements.river.artifacts.model.WKms; 24 import org.dive4elements.river.artifacts.model.WKms;
68 public static final String I18N_YAXIS_LABEL_DEFAULT_1 = "[t/a]"; 68 public static final String I18N_YAXIS_LABEL_DEFAULT_1 = "[t/a]";
69 public static final String I18N_YAXIS_LABEL_DEFAULT_2 = "[m\u00b3/a]"; 69 public static final String I18N_YAXIS_LABEL_DEFAULT_2 = "[m\u00b3/a]";
70 public static final String I18N_YAXIS_D_LABEL_DEFAULT = "delta S [m]"; 70 public static final String I18N_YAXIS_D_LABEL_DEFAULT = "delta S [m]";
71 public static final String I18N_YAXIS_V_LABEL_DEFAULT = "Geschwindigkeit v [m/s]"; 71 public static final String I18N_YAXIS_V_LABEL_DEFAULT = "Geschwindigkeit v [m/s]";
72 72
73 private FLYSArtifact artifact; 73 private D4EArtifact artifact;
74 74
75 @Override 75 @Override
76 protected YAxisWalker getYAxisWalker() { 76 protected YAxisWalker getYAxisWalker() {
77 return new YAxisWalker() { 77 return new YAxisWalker() {
78 78
99 logger.error("No facet name for doOut(). No output generated!"); 99 logger.error("No facet name for doOut(). No output generated!");
100 return; 100 return;
101 } 101 }
102 102
103 Facet facet = bundle.getFacet(); 103 Facet facet = bundle.getFacet();
104 artifact = (FLYSArtifact)bundle.getArtifact(); 104 artifact = (D4EArtifact)bundle.getArtifact();
105 105
106 if (facet == null) { 106 if (facet == null) {
107 return; 107 return;
108 } 108 }
109 if (getXBounds(0) != null && getDomainAxisRange() != null) { 109 if (getXBounds(0) != null && getDomainAxisRange() != null) {
116 else if (getXBounds(0) != null && getDomainAxisRange() == null) { 116 else if (getXBounds(0) != null && getDomainAxisRange() == null) {
117 context.putContextValue("startkm", getXBounds(0).getLower()); 117 context.putContextValue("startkm", getXBounds(0).getLower());
118 context.putContextValue("endkm", getXBounds(0).getUpper()); 118 context.putContextValue("endkm", getXBounds(0).getUpper());
119 } 119 }
120 else if (getXBounds(0) == null && getDomainAxisRange() == null) { 120 else if (getXBounds(0) == null && getDomainAxisRange() == null) {
121 FLYSArtifact artifact = (FLYSArtifact)bundle.getArtifact(); 121 D4EArtifact artifact = (D4EArtifact)bundle.getArtifact();
122 RangeAccess access = new RangeAccess(artifact, context); 122 RangeAccess access = new RangeAccess(artifact, context);
123 context.putContextValue("startkm", access.getFrom()); 123 context.putContextValue("startkm", access.getFrom());
124 context.putContextValue("endkm", access.getTo()); 124 context.putContextValue("endkm", access.getTo());
125 } 125 }
126 else if (getXBounds(0) == null && getDomainAxisRange() != null){ 126 else if (getXBounds(0) == null && getDomainAxisRange() != null){
127 FLYSArtifact artifact = (FLYSArtifact)bundle.getArtifact(); 127 D4EArtifact artifact = (D4EArtifact)bundle.getArtifact();
128 RangeAccess access = new RangeAccess(artifact, context); 128 RangeAccess access = new RangeAccess(artifact, context);
129 Bounds b = new DoubleBounds(access.getFrom(), access.getTo()); 129 Bounds b = new DoubleBounds(access.getFrom(), access.getTo());
130 Bounds bounds = 130 Bounds bounds =
131 calculateZoom(b, getDomainAxisRange()); 131 calculateZoom(b, getDomainAxisRange());
132 context.putContextValue("startkm", bounds.getLower()); 132 context.putContextValue("startkm", bounds.getLower());

http://dive4elements.wald.intevation.org