Mercurial > dive4elements > river
annotate artifacts/src/main/java/org/dive4elements/river/artifacts/sinfo/flowdepthminmax/FlowDepthMinMaxCalculationResult.java @ 8950:b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
author | gernotbelger |
---|---|
date | Thu, 15 Mar 2018 17:22:28 +0100 |
parents | a4f1ac81f26d |
children | 0adc6d04de95 |
rev | line source |
---|---|
8946 | 1 /* Copyright (C) 2017 by Bundesanstalt für Gewässerkunde |
2 * Software engineering by | |
3 * Björnsen Beratende Ingenieure GmbH | |
4 * Dr. Schumacher Ingenieurbüro für Wasser und Umwelt | |
5 * | |
6 * This file is Free Software under the GNU AGPL (>=v3) | |
7 * and comes with ABSOLUTELY NO WARRANTY! Check out the | |
8 * documentation coming with Dive4Elements River for details. | |
9 */ | |
10 package org.dive4elements.river.artifacts.sinfo.flowdepthminmax; | |
11 | |
12 import java.util.Collection; | |
13 | |
14 import org.dive4elements.river.artifacts.sinfo.common.AbstractSInfoCalculationResult; | |
8948 | 15 import org.dive4elements.river.artifacts.sinfo.common.SInfoResultRow; |
8946 | 16 import org.dive4elements.river.artifacts.sinfo.util.BedHeightInfo; |
17 import org.dive4elements.river.artifacts.sinfo.util.WstInfo; | |
18 | |
19 /** | |
20 * Contains the results of a {@link FlowDepthCalculation}. | |
21 * | |
22 * @author Gernot Belger | |
23 */ | |
8948 | 24 final class FlowDepthMinMaxCalculationResult extends AbstractSInfoCalculationResult { |
8946 | 25 |
26 private static final long serialVersionUID = 1L; | |
27 | |
28 private final BedHeightInfo minSounding; | |
29 | |
30 private final BedHeightInfo maxSounding; | |
31 | |
32 public FlowDepthMinMaxCalculationResult(final String label, final WstInfo wst, final BedHeightInfo minSounding, final BedHeightInfo maxSounding, | |
8948 | 33 final Collection<SInfoResultRow> rows) { |
8946 | 34 super(label, wst, rows); |
35 | |
36 this.minSounding = minSounding; | |
37 this.maxSounding = maxSounding; | |
38 } | |
39 | |
40 public BedHeightInfo getMinSounding() { | |
41 return this.minSounding; | |
42 } | |
43 | |
44 public BedHeightInfo getMaxSounding() { | |
45 return this.maxSounding; | |
46 } | |
47 | |
48 public BedHeightInfo getAnySounding() { | |
49 if (this.minSounding != null) | |
50 return this.minSounding; | |
51 | |
52 return this.maxSounding; | |
53 } | |
8950
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
54 |
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
55 public boolean hasMin() { |
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
56 return this.minSounding != null; |
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
57 } |
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
58 |
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
59 public boolean hasMax() { |
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
60 return this.maxSounding != null; |
b0aeed4c97c1
Implemented chart output for sinfo flow depth min/max calculation
gernotbelger
parents:
8948
diff
changeset
|
61 } |
8946 | 62 } |