Mercurial > dive4elements > river
comparison flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/minfo/SedimentLoadFacet.java @ 5647:ddb2a4e982b8
Doc and cosmetics.
author | Felix Wolfsteller <felix.wolfsteller@intevation.de> |
---|---|
date | Wed, 10 Apr 2013 13:10:55 +0200 |
parents | 696d710470f5 |
children | 4feda81c38bc |
comparison
equal
deleted
inserted
replaced
5646:14009b194871 | 5647:ddb2a4e982b8 |
---|---|
16 import de.intevation.flys.artifacts.states.DefaultState.ComputeType; | 16 import de.intevation.flys.artifacts.states.DefaultState.ComputeType; |
17 | 17 |
18 import de.intevation.flys.utils.FLYSUtils; | 18 import de.intevation.flys.utils.FLYSUtils; |
19 | 19 |
20 | 20 |
21 /** Facet to access various sediment loads. */ | |
21 public class SedimentLoadFacet | 22 public class SedimentLoadFacet |
22 extends DataFacet | 23 extends DataFacet |
23 { | 24 { |
24 /** Very own logger. */ | 25 /** Very own logger. */ |
25 private static Logger logger = Logger.getLogger(SedimentLoadFacet.class); | 26 private static Logger logger = Logger.getLogger(SedimentLoadFacet.class); |
26 | 27 |
28 /** Used as tolerance value when fetching measurement stations. */ | |
27 private static double EPSILON = 1e-5; | 29 private static double EPSILON = 1e-5; |
30 | |
28 | 31 |
29 public SedimentLoadFacet() { | 32 public SedimentLoadFacet() { |
30 } | 33 } |
31 | 34 |
32 public SedimentLoadFacet(int idx, String name, String description, | 35 public SedimentLoadFacet(int idx, String name, String description, |
55 List<MeasurementStation> stations = new ArrayList<MeasurementStation>(); | 58 List<MeasurementStation> stations = new ArrayList<MeasurementStation>(); |
56 for (MeasurementStation station: allStations) { | 59 for (MeasurementStation station: allStations) { |
57 if (station.getRange() == null || station.getMeasurementType() == null) { | 60 if (station.getRange() == null || station.getMeasurementType() == null) { |
58 continue; | 61 continue; |
59 } | 62 } |
60 if (FacetTypes.IS.SEDIMENT_LOAD_NO_FLOAT(this.getName()) && station.getMeasurementType().equals("Geschiebe")) | 63 if (FacetTypes.IS.SEDIMENT_LOAD_NO_FLOAT(this.getName()) |
64 && station.getMeasurementType().equals("Geschiebe")) | |
61 stations.add(station); | 65 stations.add(station); |
62 else if (!FacetTypes.IS.SEDIMENT_LOAD_NO_FLOAT(this.getName()) && station.getMeasurementType().equals("Schwebstoff")) | 66 else if (!FacetTypes.IS.SEDIMENT_LOAD_NO_FLOAT(this.getName()) |
67 && station.getMeasurementType().equals("Schwebstoff")) | |
63 stations.add(station); | 68 stations.add(station); |
64 } | 69 } |
65 | 70 |
66 // Access data according to type. | 71 // Access data according to type. |
67 double[][] sd = null; | 72 double[][] sd = null; |