Mercurial > dive4elements > river
comparison artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/BedHeightSingleData.java @ 7829:1aba75321441 minfo-opt
Added morph. active width to bed height difference calculation.
author | Raimund Renkert <rrenkert@intevation.de> |
---|---|
date | Fri, 28 Mar 2014 11:20:49 +0100 |
parents | 8faa8cfd2385 |
children | 42076d94977e |
comparison
equal
deleted
inserted
replaced
7828:8faa8cfd2385 | 7829:1aba75321441 |
---|---|
15 extends BedHeightData | 15 extends BedHeightData |
16 { | 16 { |
17 protected int year; | 17 protected int year; |
18 protected TDoubleArrayList data_gap; | 18 protected TDoubleArrayList data_gap; |
19 protected TDoubleArrayList soundingWidth; | 19 protected TDoubleArrayList soundingWidth; |
20 protected TDoubleArrayList width; | |
20 | 21 |
21 public BedHeightSingleData() { | 22 public BedHeightSingleData() { |
22 super(); | 23 super(); |
23 this.year = -1; | 24 this.year = -1; |
24 data_gap = new TDoubleArrayList(); | 25 data_gap = new TDoubleArrayList(); |
25 soundingWidth = new TDoubleArrayList(); | 26 soundingWidth = new TDoubleArrayList(); |
27 width = new TDoubleArrayList(); | |
26 } | 28 } |
27 | 29 |
28 public BedHeightSingleData(String name) { | 30 public BedHeightSingleData(String name) { |
29 super(name); | 31 super(name); |
30 this.year = -1; | 32 this.year = -1; |
31 data_gap = new TDoubleArrayList(); | 33 data_gap = new TDoubleArrayList(); |
32 soundingWidth = new TDoubleArrayList(); | 34 soundingWidth = new TDoubleArrayList(); |
35 width = new TDoubleArrayList(); | |
33 } | 36 } |
34 | 37 |
35 public void add( | 38 public void add( |
36 double value, | 39 double value, |
37 double station, | 40 double station, |
38 double gap, | 41 double gap, |
42 double sounding, | |
39 double width, | 43 double width, |
40 int year | 44 int year |
41 ) { | 45 ) { |
42 super.add(value, station); | 46 super.add(value, station); |
43 this.year = year; | 47 this.year = year; |
44 this.data_gap.add(gap); | 48 this.data_gap.add(gap); |
45 this.soundingWidth.add(width); | 49 this.soundingWidth.add(sounding); |
50 this.width.add(width); | |
46 } | 51 } |
47 | 52 |
48 public int getYear() { | 53 public int getYear() { |
49 return this.year; | 54 return this.year; |
50 } | 55 } |
68 } | 73 } |
69 | 74 |
70 public double[] getSoundingWidths() { | 75 public double[] getSoundingWidths() { |
71 return this.soundingWidth.toNativeArray(); | 76 return this.soundingWidth.toNativeArray(); |
72 } | 77 } |
78 | |
79 public double getWidth(int ndx) { | |
80 return width.getQuick(ndx); | |
81 } | |
82 | |
83 public double getWidth(double station) { | |
84 int ndx = this.station.indexOf(station); | |
85 return width.get(ndx); | |
86 } | |
73 } | 87 } |