Mercurial > dive4elements > river
diff artifacts/src/main/java/org/dive4elements/river/artifacts/uinfo/vegetationzones/VegetationZonesCalculation.java @ 9118:431f1c269be5
Veg-Zone Table improved, State change data recovery;
author | gernotbelger |
---|---|
date | Mon, 04 Jun 2018 19:38:59 +0200 |
parents | 41f4bc83aa7a |
children | b570b6fcc052 |
line wrap: on
line diff
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/uinfo/vegetationzones/VegetationZonesCalculation.java Mon Jun 04 17:31:51 2018 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/uinfo/vegetationzones/VegetationZonesCalculation.java Mon Jun 04 19:38:59 2018 +0200 @@ -15,7 +15,6 @@ import org.apache.commons.lang.math.DoubleRange; import org.dive4elements.artifacts.CallContext; -import org.dive4elements.river.artifacts.access.RangeAccess; import org.dive4elements.river.artifacts.common.ResultRow; import org.dive4elements.river.artifacts.model.Calculation; import org.dive4elements.river.artifacts.model.CalculationResult; @@ -44,19 +43,17 @@ final String calcModeLabel = Resources.getMsg(this.context.getMeta(), uinfo.getCalculationMode().name()); final String user = CalculationUtils.findArtifactUser(this.context, uinfo); - // FIXME: remove, check other states as well - final RangeAccess access = new RangeAccess(uinfo); - final River river = access.getRiver(); - final DoubleRange calcRange = access.getRange(); + final VegetationzonesAccess vAccess = new VegetationzonesAccess(uinfo); + final River river = vAccess.getRiver(); + final DoubleRange calcRange = vAccess.getRange(); final RiverInfo riverInfo = new RiverInfo(river); - final VegetationzonesAccess vAccess = new VegetationzonesAccess(uinfo); final String zonesRaw = vAccess.getVegZones(); - final List<VegetationZoneAccessHelper> helpers = VegetationZoneAccessHelper.parse(zonesRaw); + final List<VegetationZone> helpers = VegetationZone.parse(zonesRaw); final VegetationZonesCalculationResults results = new VegetationZonesCalculationResults(calcModeLabel, user, riverInfo, calcRange); final Collection<ResultRow> rows = new ArrayList<>(); - for (final VegetationZoneAccessHelper zone : helpers) { + for (final VegetationZone zone : helpers) { final ResultRow row2 = ResultRow.create().// putValue(UInfoResultType.vegname, zone.getZoneName()).// putValue(UInfoResultType.vegdauervon, zone.getMin_day_overflow()).//