[Dive4elements-commits] [PATCH 1 of 3] towards issue1061: Store names of original BedHeights in the BedDiffYearResult

Wald Commits scm-commit at wald.intevation.org
Fri May 24 13:50:02 CEST 2013


# HG changeset patch
# User Felix Wolfsteller <felix.wolfsteller at intevation.de>
# Date 1369388375 -7200
# Node ID 0c3301fe23bd1ad226ea8515aaf1fe5170150336
# Parent  127cc609c12b96b9c19b77fab4615c35ee56f57f
towards issue1061: Store names of original BedHeights in the BedDiffYearResult.

diff -r 127cc609c12b -r 0c3301fe23bd artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/BedDiffCalculation.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/BedDiffCalculation.java	Fri May 24 12:22:05 2013 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/BedDiffCalculation.java	Fri May 24 11:39:35 2013 +0200
@@ -190,6 +190,8 @@
             absolute,
             gap,
             s1.getYear(),
-            s2.getYear());
+            s2.getYear(),
+            s1.getName(),
+            s2.getName());
     }
 }
diff -r 127cc609c12b -r 0c3301fe23bd artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/BedDiffYearResult.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/BedDiffYearResult.java	Fri May 24 12:22:05 2013 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/BedDiffYearResult.java	Fri May 24 11:39:35 2013 +0200
@@ -20,6 +20,8 @@
     protected TDoubleArrayList morphWidth;
     protected int start;
     protected int end;
+    protected String nameFirst;
+    protected String nameSecond;
 
     public BedDiffYearResult () {
         super();
@@ -39,7 +41,9 @@
         TDoubleArrayList bedHeights,
         TDoubleArrayList dataGap,
         int start,
-        int end
+        int end,
+        String nameFirst,
+        String nameSecond
     ) {
         super(kms, differences, heights1, heights2);
         this.bedHeights = bedHeights;
@@ -47,6 +51,8 @@
         this.morphWidth = morphWidth;
         this.start = start;
         this.end = end;
+        this.nameFirst = nameFirst;
+        this.nameSecond = nameSecond;
     }
 
     public TDoubleArrayList getBedHeights() {
@@ -77,6 +83,16 @@
         return this.end;
     }
 
+    /** Get name of the first BedHeight (minuend). */
+    public String getNameFirst() {
+        return this.nameFirst;
+    }
+
+    /** Get name of the second BedHeight (subtrahend). */
+    public String getNameSecond() {
+        return this.nameFirst;
+    }
+
     public void addMorphWidth(double value) {
         this.morphWidth.add(value);
     }


More information about the Dive4elements-commits mailing list