comparison artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/collision/CollisionCalcOverviewResult.java @ 9205:3dae6b78e1da

inundationDuration/floodDuration multiple columns+chartLines refactoring
author gernotbelger
date Mon, 02 Jul 2018 19:01:09 +0200
parents 4f411c6ee3ae
children e5367900dd6d
comparison
equal deleted inserted replaced
9204:4f411c6ee3ae 9205:3dae6b78e1da
44 44
45 public int[] getSingleYears() { 45 public int[] getSingleYears() {
46 return this.singleYears; 46 return this.singleYears;
47 } 47 }
48 48
49 @Override 49 public double[][] getStationPointsByYear(final IResultType type, final int year) {
50 public double[][] getStationPoints(final IResultType type, final int index) {
51 50
52 final TDoubleArrayList xPoints = new TDoubleArrayList(this.rows.size()); 51 final TDoubleArrayList xPoints = new TDoubleArrayList(this.rows.size());
53 final TDoubleArrayList yPoints = new TDoubleArrayList(this.rows.size()); 52 final TDoubleArrayList yPoints = new TDoubleArrayList(this.rows.size());
54 53
55 for (final ResultRow row : this.rows) { 54 for (final ResultRow row : this.rows) {
56 55
57 if ((this.singleYears == null) || (Integer.valueOf(row.getValue(SInfoResultType.years).toString()) == this.singleYears[index])) { 56 if ((this.singleYears == null) || (Integer.valueOf(row.getValue(SInfoResultType.years).toString()) == year)) {
58 57
59 final double station = row.getDoubleValue(GeneralResultType.station); 58 final double station = row.getDoubleValue(GeneralResultType.station);
60 final double value = row.getDoubleValue(type); 59 final double value = row.getDoubleValue(type);
61 60
62 xPoints.add(station); 61 xPoints.add(station);

http://dive4elements.wald.intevation.org