# HG changeset patch # User Felix Wolfsteller # Date 1375261973 -7200 # Node ID 796750499cd23e529aad92f6fa5fc879e5017381 # Parent 078d56dffc8c90cca4e4729db9eb2c1ab7c815fa issue1393/SedimentYieldParser: set kind of SedimentYields epending on import location. diff -r 078d56dffc8c -r 796750499cd2 backend/src/main/java/org/dive4elements/river/importer/parsers/SedimentYieldParser.java --- a/backend/src/main/java/org/dive4elements/river/importer/parsers/SedimentYieldParser.java Wed Jul 31 11:12:08 2013 +0200 +++ b/backend/src/main/java/org/dive4elements/river/importer/parsers/SedimentYieldParser.java Wed Jul 31 11:12:53 2013 +0200 @@ -248,11 +248,23 @@ // skip first column (Fluss-km) and last column (Hinweise) current = new ImportSedimentYield[columnNames.length-2]; + Integer kind; + + if (inputFile.getAbsolutePath().contains("amtliche Epochen")) { + log.warn("is amtlichbamtlich"); + kind = new Integer(1); + } + else { + log.warn("is unamtlichbamtlich"); + kind = new Integer(0); + } + for (int i = 0, n = columnNames.length; i < n-2; i++) { current[i] = new ImportSedimentYield(this.description); current[i].setTimeInterval(getTimeInterval(columnNames[i+1])); current[i].setUnit(unit); current[i].setGrainFraction(grainFraction); + current[i].setKind(kind); } }