Mercurial > dive4elements > river
changeset 8050:9e79e384aa8b
Sediment load: Added more 'sums' to be calculated.
author | Sascha L. Teichmann <teichmann@intevation.de> |
---|---|
date | Thu, 17 Jul 2014 18:22:16 +0200 |
parents | d49846f05108 |
children | 9dce39cffab3 |
files | artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadData.java artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadDataCalculation.java |
diffstat | 2 files changed, 41 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadData.java Thu Jul 17 16:51:18 2014 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadData.java Thu Jul 17 18:22:16 2014 +0200 @@ -38,7 +38,10 @@ /* GF_SAND */ Station.BED_LOAD, /* GF_SUSP_SAND */ Station.BED_LOAD, /* GF_SUSP_SAND_BED */ Station.BED_LOAD, - /* GF_SUSP_SEDIMENT */ Station.SUSPENDED + /* GF_SUSP_SEDIMENT */ Station.SUSPENDED, + /* GF_TOTAL */ Station.BED_LOAD|Station.SUSPENDED, + /* GF_BED_LOAD */ Station.BED_LOAD, + /* GF_SUSPENDED_LOAD */ Station.BED_LOAD }; public static final int measurementStationType(int grainFraction) { @@ -173,7 +176,7 @@ } public boolean isType(int type) { - return (this.type & type) == type; + return (this.type & type) != 0; } public void setNext(Station next) {
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadDataCalculation.java Thu Jul 17 16:51:18 2014 +0200 +++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadDataCalculation.java Thu Jul 17 18:22:16 2014 +0200 @@ -44,6 +44,42 @@ SedimentLoadData.GF_SUSP_SAND }; + public static final int [] TOTAL_LOAD_BFG = { + SedimentLoadData.GF_TOTAL + }; + + public static final int [] BED_LOAD_BFG = { + SedimentLoadData.GF_BED_LOAD + }; + + public static final int [] SUSPENDED_LOAD_BFG = { + SedimentLoadData.GF_SUSPENDED_LOAD + }; + + public static final int [] COARSE_FLYS = { + SedimentLoadData.GF_COARSE + }; + + public static final int [] FINE_MIDDLE_FLYS = { + SedimentLoadData.GF_FINE_MIDDLE + }; + + public static final int [] SAND_FLYS = { + SedimentLoadData.GF_SAND + }; + + public static final int [] SUSP_SAND_FLYS = { + SedimentLoadData.GF_SUSP_SAND + }; + + public static final int [] SUSP_SAND_BED_FLYS = { + SedimentLoadData.GF_SUSP_SAND_BED + }; + + public static final int [] SUSP_SEDIMENT_FLYS = { + SedimentLoadData.GF_SUSP_SEDIMENT + }; + public static final class Sum implements Value.Visitor { private int n;