comparison artifacts/src/main/java/org/dive4elements/river/artifacts/CrossSectionArtifact.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 4897a58c8746
children af13ceeba52a
comparison
equal deleted inserted replaced
5866:9a6741ccf6d4 5867:59ff03ff48f1
40 40
41 41
42 /** 42 /**
43 * Artifact describing a cross-section. 43 * Artifact describing a cross-section.
44 */ 44 */
45 public class CrossSectionArtifact extends StaticFLYSArtifact { 45 public class CrossSectionArtifact extends StaticD4EArtifact {
46 46
47 /** Name of Artifact. */ 47 /** Name of Artifact. */
48 public static final String CS_ARTIFACT_NAME = "cross_section"; 48 public static final String CS_ARTIFACT_NAME = "cross_section";
49 49
50 /** Name of state. */ 50 /** Name of state. */
81 public Boolean isInitialActive( 81 public Boolean isInitialActive(
82 Artifact artifact, 82 Artifact artifact,
83 Facet facet, 83 Facet facet,
84 String outputName 84 String outputName
85 ) { 85 ) {
86 if (artifact instanceof FLYSArtifact) { 86 if (artifact instanceof D4EArtifact) {
87 FLYSArtifact flys = (FLYSArtifact)artifact; 87 D4EArtifact flys = (D4EArtifact)artifact;
88 String data = flys.getDataAsString(DATA_IS_NEWEST); 88 String data = flys.getDataAsString(DATA_IS_NEWEST);
89 return data != null && data.equals("1"); 89 return data != null && data.equals("1");
90 } 90 }
91 return null; 91 return null;
92 } 92 }
158 protected void initialize( 158 protected void initialize(
159 Artifact artifact, 159 Artifact artifact,
160 Object context, 160 Object context,
161 CallMeta callMeta) 161 CallMeta callMeta)
162 { 162 {
163 FLYSArtifact flys = (FLYSArtifact) artifact; 163 D4EArtifact flys = (D4EArtifact) artifact;
164 164
165 RangeAccess rangeAccess = new RangeAccess(flys, null); 165 RangeAccess rangeAccess = new RangeAccess(flys, null);
166 double[] range = rangeAccess.getKmRange(); 166 double[] range = rangeAccess.getKmRange();
167 double min = 0.0f; 167 double min = 0.0f;
168 if (range != null && range.length > 0) { 168 if (range != null && range.length > 0) {

http://dive4elements.wald.intevation.org