Mercurial > dive4elements > river
view flys-artifacts/src/main/java/de/intevation/flys/artifacts/model/minfo/BedDiffYearResult.java @ 4171:1d8faeedda0c
Sort calculation results of a historical discharge calculation based on their start date.
Therefore, there are two new inner classes TimerangeItem and HistoricalTimerangeItem that wrap
a W, Q, Timerange (and delta Q). WQTimerange and HistoricalWQTimerange now implement a sort()
that return the results (TimerangeItem or HistoricalWQTimerangeItem) sorted by their start date.
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Thu, 18 Oct 2012 09:28:51 +0200 |
parents | da48e33f4241 |
children | 2904ecca4663 |
line wrap: on
line source
package de.intevation.flys.artifacts.model.minfo; import gnu.trove.TDoubleArrayList; public class BedDiffYearResult extends BedDifferencesResult { protected TDoubleArrayList bedHeights; protected TDoubleArrayList dataGap; protected TDoubleArrayList morphWidth; protected int start; protected int end; public BedDiffYearResult () { super(); this.bedHeights = new TDoubleArrayList(); this.dataGap = new TDoubleArrayList(); this.morphWidth = new TDoubleArrayList(); this.start = -1; this.end = -1; } public BedDiffYearResult( TDoubleArrayList kms, TDoubleArrayList differences, TDoubleArrayList heights1, TDoubleArrayList heights2, TDoubleArrayList morphWidth, TDoubleArrayList bedHeights, TDoubleArrayList dataGap, int start, int end ) { super(kms, differences, heights1, heights2); this.bedHeights = bedHeights; this.dataGap = dataGap; this.morphWidth = morphWidth; this.start = start; this.end = end; } public TDoubleArrayList getBedHeights() { return this.bedHeights; } public TDoubleArrayList getDataGap() { return this.dataGap; } public TDoubleArrayList getMorphWidth() { return this.morphWidth; } public int getStart() { return this.start; } public int getEnd() { return this.end; } public double[][] getMorphWidthData() { return new double[][] { kms.toNativeArray(), morphWidth.toNativeArray() }; } public double[][] getHeightPerYearData() { return new double[][] { kms.toNativeArray(), bedHeights.toNativeArray() }; } }