[PATCH 03 of 10] Doc
Wald Commits
scm-commit at wald.intevation.org
Mon Jul 29 09:25:54 CEST 2013
# HG changeset patch
# User Felix Wolfsteller <felix.wolfsteller at intevation.de>
# Date 1375082531 -7200
# Node ID 0a70a320bfcab57dc30c427bd85387d488112b19
# Parent 866c914d59886b925f5b21e6ef06efeecd3380f1
Doc.
diff -r 866c914d5988 -r 0a70a320bfca artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadCalculation.java
--- a/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadCalculation.java Mon Jul 29 09:21:14 2013 +0200
+++ b/artifacts/src/main/java/org/dive4elements/river/artifacts/model/minfo/SedimentLoadCalculation.java Mon Jul 29 09:22:11 2013 +0200
@@ -42,6 +42,7 @@
public SedimentLoadCalculation() {
}
+ /** Returns CalculationResult with array of SedimentLoadResults. */
public CalculationResult calculate(SedimentLoadAccess access) {
logger.info("SedimentLoadCalculation.calculate");
@@ -87,6 +88,7 @@
return new CalculationResult();
}
+ /** Returns CalculationResult with array of SedimentLoadResults. */
private CalculationResult internalCalculate() {
logger.debug("internalCalulate; mode:" + yearEpoch);
if (yearEpoch.equals("year")) {
@@ -259,8 +261,11 @@
return result;
}
- /** Fetch loads for a single year, calculate total and
- * return the result containing both. */
+ /**
+ * Fetch loads for a single year, calculate total and
+ * return the result containing both.
+ * @param y year, e.g. 1980
+ */
private SedimentLoadResult calculateYear(int y) {
SedimentLoad load = SedimentLoadFactory.getLoadWithData(
this.river,
@@ -346,12 +351,15 @@
/**
* Set total values in load.
- * Therefore, run over the kms and find ranges where either all
+ *
+ * Therefore, run over the sorted kms and find ranges where either all
* or all Geschiebe or just the Schwebstoff fractions are set.
* Merge these ranges and add (maybe new) respective fractions to
- * load.
+ * load. In the process, remember any 'unfished' ends from measurements
+ * where the km-ranges did not completely match.
+ *
* @param load SedimentLoad to add total values (and ranges) to.
- * @return input param load.
+ * @return input param load, with total values set.
*/
private SedimentLoad partialTotal(SedimentLoad load) {
SedimentLoad fairLoad = load;
@@ -501,6 +509,11 @@
}
+ /**
+ * Transform values in load.
+ * @param load The load of which values should be transformed.
+ * @return parameter load with transformed values.
+ */
private SedimentLoad calculateUnit(SedimentLoad load, int year) {
SedimentDensity density =
SedimentDensityFactory.getSedimentDensity(river, kmLow, kmUp, year);
More information about the Dive4elements-commits
mailing list