[PATCH] 3 Significant also for Q_1, Q_2

Wald Commits scm-commit at wald.intevation.org
Mon Oct 14 18:07:40 CEST 2019


# HG changeset patch
# User dnt_bjoernsen <d.tironi at bjoernsen.de>
# Date 1571069251 -7200
#      Mon Oct 14 18:07:31 2019 +0200
# Node ID 8da911b5169cda793411722279057ba06cf5385d
# Parent  d1c7ee4a3723490c8d062af8c5512b17182f44a3
3 Significant also for Q_1, Q_2...

diff -r d1c7ee4a3723 -r 8da911b5169c artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/DurationWaterlevel.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/DurationWaterlevel.java	Mon Oct 14 17:34:58 2019 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/DurationWaterlevel.java	Mon Oct 14 18:07:31 2019 +0200
@@ -12,6 +12,9 @@
 import java.io.Serializable;
 import java.text.NumberFormat;
 
+import org.dive4elements.artifacts.CallContext;
+import org.dive4elements.river.artifacts.sinfo.common.SInfoResultType;
+
 /**
  * @author Domenico Nardi Tironi
  *
@@ -56,6 +59,10 @@
         return qFormatter.format(this.q);
     }
 
+    public String getQFormatted3Significant(final CallContext context) {
+        return SInfoResultType.floodDischarge.exportValue(context, this.q);
+    }
+
     public String getWFormatted(final NumberFormat wFormatter) {
         return wFormatter.format(this.w);
     }
diff -r d1c7ee4a3723 -r 8da911b5169c artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationCalculationResult.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationCalculationResult.java	Mon Oct 14 17:34:58 2019 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flood_duration/FloodDurationCalculationResult.java	Mon Oct 14 18:07:31 2019 +0200
@@ -163,11 +163,10 @@
             final DurationWaterlevel item = waterlevelList.get(i);
             lines.add(item.getWFormatted(wFormatter));
             lines.add(item.getFloodDurDaysPerYearFormatted(durFormatter));
-            lines.add(item.getQFormatted(qFormatter));
+            lines.add(item.getQFormatted3Significant(exportContextCSV.getContext()));
             lines.add(item.getBezeichnung());
         }
 
-        final int lineSize = lines.size();
         while (mode == ExportMode.pdf && lines.size() < expectedSizetoGaugelabel)
             lines.add("");
 


More information about the Dive4Elements-commits mailing list