# HG changeset patch
# User gernotbelger
# Date 1525433761 -7200
# Node ID 95643dffd006411eef111c0a2b9321ed3dd1c708
# Parent ad2ae847e10e5d3fa3ec178a88888c9cd9afa943
rename grounding->collision; inundation_duration->flood_duration
diff -r ad2ae847e10e -r 95643dffd006 artifacts/doc/conf/artifacts/sinfo.xml
--- a/artifacts/doc/conf/artifacts/sinfo.xml Fri May 04 13:17:57 2018 +0200
+++ b/artifacts/doc/conf/artifacts/sinfo.xml Fri May 04 13:36:01 2018 +0200
@@ -221,16 +221,16 @@
-
+
-
+
-
+
@@ -238,13 +238,13 @@
-
-
+
+
-
+
-
+
@@ -282,27 +282,27 @@
-
+
-
+
-
+
-
+
-
+
@@ -314,21 +314,21 @@
-
+
-
-
+
+
-
+
-
+
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/SinfoCalcMode.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/SinfoCalcMode.java Fri May 04 13:17:57 2018 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/SinfoCalcMode.java Fri May 04 13:36:01 2018 +0200
@@ -14,7 +14,7 @@
sinfo_calc_flow_depth,
sinfo_calc_flow_depth_development,
sinfo_calc_flow_depth_minmax,
- sinfo_calc_grounding,
+ sinfo_calc_collision,
sinfo_calc_transport_bodies_heights,
- sinfo_calc_infrastructures_inundation_duration
+ sinfo_calc_flood_duration
}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/collision/CollisionState.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/collision/CollisionState.java Fri May 04 13:36:01 2018 +0200
@@ -0,0 +1,114 @@
+/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU AGPL (>=v3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out the
+ * documentation coming with Dive4Elements River for details.
+ */
+
+package org.dive4elements.river.artifacts.sinfo.collision;
+
+import java.util.List;
+
+import org.dive4elements.artifactdatabase.state.Facet;
+import org.dive4elements.artifacts.CallContext;
+import org.dive4elements.river.artifacts.ChartArtifact;
+import org.dive4elements.river.artifacts.D4EArtifact;
+import org.dive4elements.river.artifacts.model.CalculationResult;
+import org.dive4elements.river.artifacts.model.EmptyFacet;
+import org.dive4elements.river.artifacts.sinfo.SINFOArtifact;
+import org.dive4elements.river.artifacts.states.DefaultState;
+
+/** State in which a waterlevel has been calculated. */
+public class CollisionState extends DefaultState {
+
+ /// ** The log that is used in this state. */
+ // private static Logger log = Logger.getLogger(FlowDepthState.class);
+
+ private static final long serialVersionUID = 1L;
+
+ /**
+ * From this state can only be continued trivially.
+ */
+ @Override
+ protected String getUIProvider() {
+ return "continue";
+ }
+
+ @Override
+ public Object computeFeed(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
+ if (artifact instanceof ChartArtifact) {
+ facets.add(new EmptyFacet());
+ return null;
+ }
+
+ return compute((SINFOArtifact) artifact, context, hash, facets, old);
+ }
+
+ @Override
+ public Object computeAdvance(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
+ if (artifact instanceof ChartArtifact) {
+ facets.add(new EmptyFacet());
+ return null;
+ }
+ return compute((SINFOArtifact) artifact, context, hash, facets, old);
+ }
+
+ /**
+ * Compute result or returned object from cache, create facets.
+ *
+ * @param old
+ * Object that was cached.
+ */
+ private Object compute(final SINFOArtifact sinfo, final CallContext context, final String hash, final List facets, final Object old) {
+
+ final CalculationResult res = doCompute(sinfo, context, old);
+
+ if (facets == null)
+ return res;
+ //
+ // final FlowDepthCalculationResults results = (FlowDepthCalculationResults) res.getData();
+ //
+ // /* add themes for chart, for each result */
+ // final List resultList = results.getResults();
+ // for (int index = 0; index < resultList.size(); index++) {
+ //
+ // final FlowDepthCalculationResult result = resultList.get(index);
+ //
+ // /* filtered (zoom dependent mean) flow depth */
+ // facets.add(FlowDepthProcessor.createFlowDepthFilteredFacet(context, hash, this.id, result, index));
+ // facets.add(FlowDepthProcessor.createFlowDepthRawFacet(context, hash, this.id, result, index));
+ //
+ // if (results.isUseTkh()) {
+ // /* filtered (zoom dependent mean) flow depth including tkh */
+ // facets.add(FlowDepthProcessor.createFlowDepthTkhFilteredFacet(context, hash, this.id, result, index));
+ // facets.add(FlowDepthProcessor.createFlowDepthTkhRawFacet(context, hash, this.id, result, index));
+ //
+ // facets.add(TkhProcessor.createTkhFacet(context, hash, this.id, result, index));
+ // }
+ // }
+
+ // if (!resultList.isEmpty()) {
+ // final Facet csv = new DataFacet(FacetTypes.CSV, "CSV data", ComputeType.ADVANCE, hash, this.id);
+ // final Facet pdf = new DataFacet(FacetTypes.PDF, "PDF data", ComputeType.ADVANCE, hash, this.id);
+ //
+ // facets.add(csv);
+ // facets.add(pdf);
+ // }
+ //
+ // final Calculation report = res.getReport();
+ //
+ // if (report.hasProblems()) {
+ // facets.add(new ReportFacet(ComputeType.ADVANCE, hash, this.id));
+ // }
+
+ return res;
+ }
+
+ private CalculationResult doCompute(final SINFOArtifact sinfo, final CallContext context, final Object old) {
+ if (old instanceof CalculationResult)
+ return (CalculationResult) old;
+
+ return null; // new FlowDepthCalculation(context).calculate(sinfo);
+ }
+}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/collision/YearChoice.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/collision/YearChoice.java Fri May 04 13:36:01 2018 +0200
@@ -0,0 +1,23 @@
+/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU AGPL (>=v3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out the
+ * documentation coming with Dive4Elements River for details.
+ */
+
+package org.dive4elements.river.artifacts.sinfo.collision;
+
+import org.dive4elements.river.artifacts.states.BooleanChoiceState;
+
+/**
+ * @author Ingo Weinzierl
+ */
+public class YearChoice extends BooleanChoiceState {
+
+ private static final long serialVersionUID = 1L;
+
+ public YearChoice() {
+ super("option", "active", "inactive"); // TODO: RADIO-Btn-Impl
+ }
+}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationState.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationState.java Fri May 04 13:36:01 2018 +0200
@@ -0,0 +1,114 @@
+/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU AGPL (>=v3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out the
+ * documentation coming with Dive4Elements River for details.
+ */
+
+package org.dive4elements.river.artifacts.sinfo.flood_duration;
+
+import java.util.List;
+
+import org.dive4elements.artifactdatabase.state.Facet;
+import org.dive4elements.artifacts.CallContext;
+import org.dive4elements.river.artifacts.ChartArtifact;
+import org.dive4elements.river.artifacts.D4EArtifact;
+import org.dive4elements.river.artifacts.model.CalculationResult;
+import org.dive4elements.river.artifacts.model.EmptyFacet;
+import org.dive4elements.river.artifacts.sinfo.SINFOArtifact;
+import org.dive4elements.river.artifacts.states.DefaultState;
+
+/** State in which a waterlevel has been calculated. */
+public class FloodDurationState extends DefaultState {
+
+ /// ** The log that is used in this state. */
+ // private static Logger log = Logger.getLogger(FlowDepthState.class);
+
+ private static final long serialVersionUID = 1L;
+
+ /**
+ * From this state can only be continued trivially.
+ */
+ @Override
+ protected String getUIProvider() {
+ return "continue";
+ }
+
+ @Override
+ public Object computeFeed(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
+ if (artifact instanceof ChartArtifact) {
+ facets.add(new EmptyFacet());
+ return null;
+ }
+
+ return compute((SINFOArtifact) artifact, context, hash, facets, old);
+ }
+
+ @Override
+ public Object computeAdvance(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
+ if (artifact instanceof ChartArtifact) {
+ facets.add(new EmptyFacet());
+ return null;
+ }
+ return compute((SINFOArtifact) artifact, context, hash, facets, old);
+ }
+
+ /**
+ * Compute result or returned object from cache, create facets.
+ *
+ * @param old
+ * Object that was cached.
+ */
+ private Object compute(final SINFOArtifact sinfo, final CallContext context, final String hash, final List facets, final Object old) {
+
+ final CalculationResult res = doCompute(sinfo, context, old);
+
+ if (facets == null)
+ return res;
+ //
+ // final FlowDepthCalculationResults results = (FlowDepthCalculationResults) res.getData();
+ //
+ // /* add themes for chart, for each result */
+ // final List resultList = results.getResults();
+ // for (int index = 0; index < resultList.size(); index++) {
+ //
+ // final FlowDepthCalculationResult result = resultList.get(index);
+ //
+ // /* filtered (zoom dependent mean) flow depth */
+ // facets.add(FlowDepthProcessor.createFlowDepthFilteredFacet(context, hash, this.id, result, index));
+ // facets.add(FlowDepthProcessor.createFlowDepthRawFacet(context, hash, this.id, result, index));
+ //
+ // if (results.isUseTkh()) {
+ // /* filtered (zoom dependent mean) flow depth including tkh */
+ // facets.add(FlowDepthProcessor.createFlowDepthTkhFilteredFacet(context, hash, this.id, result, index));
+ // facets.add(FlowDepthProcessor.createFlowDepthTkhRawFacet(context, hash, this.id, result, index));
+ //
+ // facets.add(TkhProcessor.createTkhFacet(context, hash, this.id, result, index));
+ // }
+ // }
+
+ // if (!resultList.isEmpty()) {
+ // final Facet csv = new DataFacet(FacetTypes.CSV, "CSV data", ComputeType.ADVANCE, hash, this.id);
+ // final Facet pdf = new DataFacet(FacetTypes.PDF, "PDF data", ComputeType.ADVANCE, hash, this.id);
+ //
+ // facets.add(csv);
+ // facets.add(pdf);
+ // }
+ //
+ // final Calculation report = res.getReport();
+ //
+ // if (report.hasProblems()) {
+ // facets.add(new ReportFacet(ComputeType.ADVANCE, hash, this.id));
+ // }
+
+ return res;
+ }
+
+ private CalculationResult doCompute(final SINFOArtifact sinfo, final CallContext context, final Object old) {
+ if (old instanceof CalculationResult)
+ return (CalculationResult) old;
+
+ return null; // new FlowDepthCalculation(context).calculate(sinfo);
+ }
+}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/RiversideRadioChoice.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/RiversideRadioChoice.java Fri May 04 13:36:01 2018 +0200
@@ -0,0 +1,36 @@
+/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU AGPL (>=v3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out the
+ * documentation coming with Dive4Elements River for details.
+ */
+
+package org.dive4elements.river.artifacts.sinfo.flood_duration;
+
+import java.util.ArrayList;
+import java.util.List;
+
+import org.dive4elements.river.artifacts.states.RadioSelect;
+
+/**
+ * @author Ingo Weinzierl
+ */
+public class RiversideRadioChoice extends RadioSelect {
+ private static final long serialVersionUID = 1L;
+
+ public RiversideRadioChoice() {
+ super();
+ }
+
+ @Override
+ protected List makeEntries() {
+ final List entries = new ArrayList<>();
+ entries.add("state.sinfo.riverside.left");
+ entries.add("state.sinfo.riverside.right");
+ entries.add("state.sinfo.riverside.both");
+ return entries;
+
+ }
+
+}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/WqinputChoice.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/WqinputChoice.java Fri May 04 13:36:01 2018 +0200
@@ -0,0 +1,23 @@
+/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU AGPL (>=v3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out the
+ * documentation coming with Dive4Elements River for details.
+ */
+
+package org.dive4elements.river.artifacts.sinfo.flood_duration;
+
+import org.dive4elements.river.artifacts.states.BooleanChoiceState;
+
+/**
+ * @author Ingo Weinzierl
+ */
+public class WqinputChoice extends BooleanChoiceState {
+
+ private static final long serialVersionUID = 1L;
+
+ public WqinputChoice() {
+ super("state.sinfo.wqinput.option", "wspl.active", "wspl.inactive");
+ }
+}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/WsplChoice.java
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/WsplChoice.java Fri May 04 13:36:01 2018 +0200
@@ -0,0 +1,23 @@
+/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
+ * Software engineering by Intevation GmbH
+ *
+ * This file is Free Software under the GNU AGPL (>=v3)
+ * and comes with ABSOLUTELY NO WARRANTY! Check out the
+ * documentation coming with Dive4Elements River for details.
+ */
+
+package org.dive4elements.river.artifacts.sinfo.flood_duration;
+
+import org.dive4elements.river.artifacts.states.BooleanChoiceState;
+
+/**
+ * @author Ingo Weinzierl
+ */
+public class WsplChoice extends BooleanChoiceState {
+
+ private static final long serialVersionUID = 1L;
+
+ public WsplChoice() {
+ super("state.sinfo.wspl.option", "state.sinfo.wspl.active", "state.sinfo.wspl.inactive");
+ }
+}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/grounding/GroundingState.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/grounding/GroundingState.java Fri May 04 13:17:57 2018 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,114 +0,0 @@
-/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
- * Software engineering by Intevation GmbH
- *
- * This file is Free Software under the GNU AGPL (>=v3)
- * and comes with ABSOLUTELY NO WARRANTY! Check out the
- * documentation coming with Dive4Elements River for details.
- */
-
-package org.dive4elements.river.artifacts.sinfo.grounding;
-
-import java.util.List;
-
-import org.dive4elements.artifactdatabase.state.Facet;
-import org.dive4elements.artifacts.CallContext;
-import org.dive4elements.river.artifacts.ChartArtifact;
-import org.dive4elements.river.artifacts.D4EArtifact;
-import org.dive4elements.river.artifacts.model.CalculationResult;
-import org.dive4elements.river.artifacts.model.EmptyFacet;
-import org.dive4elements.river.artifacts.sinfo.SINFOArtifact;
-import org.dive4elements.river.artifacts.states.DefaultState;
-
-/** State in which a waterlevel has been calculated. */
-public class GroundingState extends DefaultState {
-
- /// ** The log that is used in this state. */
- // private static Logger log = Logger.getLogger(FlowDepthState.class);
-
- private static final long serialVersionUID = 1L;
-
- /**
- * From this state can only be continued trivially.
- */
- @Override
- protected String getUIProvider() {
- return "continue";
- }
-
- @Override
- public Object computeFeed(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
- if (artifact instanceof ChartArtifact) {
- facets.add(new EmptyFacet());
- return null;
- }
-
- return compute((SINFOArtifact) artifact, context, hash, facets, old);
- }
-
- @Override
- public Object computeAdvance(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
- if (artifact instanceof ChartArtifact) {
- facets.add(new EmptyFacet());
- return null;
- }
- return compute((SINFOArtifact) artifact, context, hash, facets, old);
- }
-
- /**
- * Compute result or returned object from cache, create facets.
- *
- * @param old
- * Object that was cached.
- */
- private Object compute(final SINFOArtifact sinfo, final CallContext context, final String hash, final List facets, final Object old) {
-
- final CalculationResult res = doCompute(sinfo, context, old);
-
- if (facets == null)
- return res;
- //
- // final FlowDepthCalculationResults results = (FlowDepthCalculationResults) res.getData();
- //
- // /* add themes for chart, for each result */
- // final List resultList = results.getResults();
- // for (int index = 0; index < resultList.size(); index++) {
- //
- // final FlowDepthCalculationResult result = resultList.get(index);
- //
- // /* filtered (zoom dependent mean) flow depth */
- // facets.add(FlowDepthProcessor.createFlowDepthFilteredFacet(context, hash, this.id, result, index));
- // facets.add(FlowDepthProcessor.createFlowDepthRawFacet(context, hash, this.id, result, index));
- //
- // if (results.isUseTkh()) {
- // /* filtered (zoom dependent mean) flow depth including tkh */
- // facets.add(FlowDepthProcessor.createFlowDepthTkhFilteredFacet(context, hash, this.id, result, index));
- // facets.add(FlowDepthProcessor.createFlowDepthTkhRawFacet(context, hash, this.id, result, index));
- //
- // facets.add(TkhProcessor.createTkhFacet(context, hash, this.id, result, index));
- // }
- // }
-
- // if (!resultList.isEmpty()) {
- // final Facet csv = new DataFacet(FacetTypes.CSV, "CSV data", ComputeType.ADVANCE, hash, this.id);
- // final Facet pdf = new DataFacet(FacetTypes.PDF, "PDF data", ComputeType.ADVANCE, hash, this.id);
- //
- // facets.add(csv);
- // facets.add(pdf);
- // }
- //
- // final Calculation report = res.getReport();
- //
- // if (report.hasProblems()) {
- // facets.add(new ReportFacet(ComputeType.ADVANCE, hash, this.id));
- // }
-
- return res;
- }
-
- private CalculationResult doCompute(final SINFOArtifact sinfo, final CallContext context, final Object old) {
- if (old instanceof CalculationResult)
- return (CalculationResult) old;
-
- return null; // new FlowDepthCalculation(context).calculate(sinfo);
- }
-}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/grounding/YearChoice.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/grounding/YearChoice.java Fri May 04 13:17:57 2018 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
- * Software engineering by Intevation GmbH
- *
- * This file is Free Software under the GNU AGPL (>=v3)
- * and comes with ABSOLUTELY NO WARRANTY! Check out the
- * documentation coming with Dive4Elements River for details.
- */
-
-package org.dive4elements.river.artifacts.sinfo.grounding;
-
-import org.dive4elements.river.artifacts.states.BooleanChoiceState;
-
-/**
- * @author Ingo Weinzierl
- */
-public class YearChoice extends BooleanChoiceState {
-
- private static final long serialVersionUID = 1L;
-
- public YearChoice() {
- super("option", "active", "inactive"); // TODO: RADIO-Btn-Impl
- }
-}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/InundationState.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/InundationState.java Fri May 04 13:17:57 2018 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,114 +0,0 @@
-/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
- * Software engineering by Intevation GmbH
- *
- * This file is Free Software under the GNU AGPL (>=v3)
- * and comes with ABSOLUTELY NO WARRANTY! Check out the
- * documentation coming with Dive4Elements River for details.
- */
-
-package org.dive4elements.river.artifacts.sinfo.inundation;
-
-import java.util.List;
-
-import org.dive4elements.artifactdatabase.state.Facet;
-import org.dive4elements.artifacts.CallContext;
-import org.dive4elements.river.artifacts.ChartArtifact;
-import org.dive4elements.river.artifacts.D4EArtifact;
-import org.dive4elements.river.artifacts.model.CalculationResult;
-import org.dive4elements.river.artifacts.model.EmptyFacet;
-import org.dive4elements.river.artifacts.sinfo.SINFOArtifact;
-import org.dive4elements.river.artifacts.states.DefaultState;
-
-/** State in which a waterlevel has been calculated. */
-public class InundationState extends DefaultState {
-
- /// ** The log that is used in this state. */
- // private static Logger log = Logger.getLogger(FlowDepthState.class);
-
- private static final long serialVersionUID = 1L;
-
- /**
- * From this state can only be continued trivially.
- */
- @Override
- protected String getUIProvider() {
- return "continue";
- }
-
- @Override
- public Object computeFeed(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
- if (artifact instanceof ChartArtifact) {
- facets.add(new EmptyFacet());
- return null;
- }
-
- return compute((SINFOArtifact) artifact, context, hash, facets, old);
- }
-
- @Override
- public Object computeAdvance(final D4EArtifact artifact, final String hash, final CallContext context, final List facets, final Object old) {
- if (artifact instanceof ChartArtifact) {
- facets.add(new EmptyFacet());
- return null;
- }
- return compute((SINFOArtifact) artifact, context, hash, facets, old);
- }
-
- /**
- * Compute result or returned object from cache, create facets.
- *
- * @param old
- * Object that was cached.
- */
- private Object compute(final SINFOArtifact sinfo, final CallContext context, final String hash, final List facets, final Object old) {
-
- final CalculationResult res = doCompute(sinfo, context, old);
-
- if (facets == null)
- return res;
- //
- // final FlowDepthCalculationResults results = (FlowDepthCalculationResults) res.getData();
- //
- // /* add themes for chart, for each result */
- // final List resultList = results.getResults();
- // for (int index = 0; index < resultList.size(); index++) {
- //
- // final FlowDepthCalculationResult result = resultList.get(index);
- //
- // /* filtered (zoom dependent mean) flow depth */
- // facets.add(FlowDepthProcessor.createFlowDepthFilteredFacet(context, hash, this.id, result, index));
- // facets.add(FlowDepthProcessor.createFlowDepthRawFacet(context, hash, this.id, result, index));
- //
- // if (results.isUseTkh()) {
- // /* filtered (zoom dependent mean) flow depth including tkh */
- // facets.add(FlowDepthProcessor.createFlowDepthTkhFilteredFacet(context, hash, this.id, result, index));
- // facets.add(FlowDepthProcessor.createFlowDepthTkhRawFacet(context, hash, this.id, result, index));
- //
- // facets.add(TkhProcessor.createTkhFacet(context, hash, this.id, result, index));
- // }
- // }
-
- // if (!resultList.isEmpty()) {
- // final Facet csv = new DataFacet(FacetTypes.CSV, "CSV data", ComputeType.ADVANCE, hash, this.id);
- // final Facet pdf = new DataFacet(FacetTypes.PDF, "PDF data", ComputeType.ADVANCE, hash, this.id);
- //
- // facets.add(csv);
- // facets.add(pdf);
- // }
- //
- // final Calculation report = res.getReport();
- //
- // if (report.hasProblems()) {
- // facets.add(new ReportFacet(ComputeType.ADVANCE, hash, this.id));
- // }
-
- return res;
- }
-
- private CalculationResult doCompute(final SINFOArtifact sinfo, final CallContext context, final Object old) {
- if (old instanceof CalculationResult)
- return (CalculationResult) old;
-
- return null; // new FlowDepthCalculation(context).calculate(sinfo);
- }
-}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/RiversideRadioChoice.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/RiversideRadioChoice.java Fri May 04 13:17:57 2018 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,36 +0,0 @@
-/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
- * Software engineering by Intevation GmbH
- *
- * This file is Free Software under the GNU AGPL (>=v3)
- * and comes with ABSOLUTELY NO WARRANTY! Check out the
- * documentation coming with Dive4Elements River for details.
- */
-
-package org.dive4elements.river.artifacts.sinfo.inundation;
-
-import java.util.ArrayList;
-import java.util.List;
-
-import org.dive4elements.river.artifacts.states.RadioSelect;
-
-/**
- * @author Ingo Weinzierl
- */
-public class RiversideRadioChoice extends RadioSelect {
- private static final long serialVersionUID = 1L;
-
- public RiversideRadioChoice() {
- super();
- }
-
- @Override
- protected List makeEntries() {
- final List entries = new ArrayList<>();
- entries.add("state.sinfo.riverside.left");
- entries.add("state.sinfo.riverside.right");
- entries.add("state.sinfo.riverside.both");
- return entries;
-
- }
-
-}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/WqinputChoice.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/WqinputChoice.java Fri May 04 13:17:57 2018 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
- * Software engineering by Intevation GmbH
- *
- * This file is Free Software under the GNU AGPL (>=v3)
- * and comes with ABSOLUTELY NO WARRANTY! Check out the
- * documentation coming with Dive4Elements River for details.
- */
-
-package org.dive4elements.river.artifacts.sinfo.inundation;
-
-import org.dive4elements.river.artifacts.states.BooleanChoiceState;
-
-/**
- * @author Ingo Weinzierl
- */
-public class WqinputChoice extends BooleanChoiceState {
-
- private static final long serialVersionUID = 1L;
-
- public WqinputChoice() {
- super("state.sinfo.wqinput.option", "wspl.active", "wspl.inactive");
- }
-}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/WsplChoice.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/inundation/WsplChoice.java Fri May 04 13:17:57 2018 +0200
+++ /dev/null Thu Jan 01 00:00:00 1970 +0000
@@ -1,23 +0,0 @@
-/* Copyright (C) 2011, 2012, 2013 by Bundesanstalt für Gewässerkunde
- * Software engineering by Intevation GmbH
- *
- * This file is Free Software under the GNU AGPL (>=v3)
- * and comes with ABSOLUTELY NO WARRANTY! Check out the
- * documentation coming with Dive4Elements River for details.
- */
-
-package org.dive4elements.river.artifacts.sinfo.inundation;
-
-import org.dive4elements.river.artifacts.states.BooleanChoiceState;
-
-/**
- * @author Ingo Weinzierl
- */
-public class WsplChoice extends BooleanChoiceState {
-
- private static final long serialVersionUID = 1L;
-
- public WsplChoice() {
- super("state.sinfo.wspl.option", "state.sinfo.wspl.active", "state.sinfo.wspl.inactive");
- }
-}
\ No newline at end of file
diff -r ad2ae847e10e -r 95643dffd006 gwt-client/src/test/java/test/TestMain.java
--- a/gwt-client/src/test/java/test/TestMain.java Fri May 04 13:17:57 2018 +0200
+++ b/gwt-client/src/test/java/test/TestMain.java Fri May 04 13:36:01 2018 +0200
@@ -27,9 +27,9 @@
* sinfo_calc_flow_depth
* sinfo_calc_flow_depth_development
* sinfo_calc_flow_depth_minmax
- * sinfo_calc_grounding
+ * sinfo_calc_collision
* Transportkörperhöhen
- * sinfo_calc_infrastructures_inundation_duration
+ * sinfo_calc_flood_duration
*/
final SinfoTest proof = new SinfoTest("belger", "belger", "sinfo", "sinfo_calc_flow_depth_minmax");