changeset 3960:9e4468d50329

fix issue862/1. flys-backend/trunk@5624 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Felix Wolfsteller <felix.wolfsteller@intevation.de>
date Thu, 27 Sep 2012 17:45:49 +0000
parents 6b1ca6ec4e3c
children f5912365619c
files flys-backend/ChangeLog flys-backend/src/main/java/de/intevation/flys/importer/parsers/BedHeightParser.java
diffstat 2 files changed, 9 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/flys-backend/ChangeLog	Thu Sep 27 13:43:31 2012 +0000
+++ b/flys-backend/ChangeLog	Thu Sep 27 17:45:49 2012 +0000
@@ -1,3 +1,11 @@
+2012-09-27  Felix Wolfsteller <felix.wolfsteller@intevation.de>
+
+	For issue862/1, fix parsing of year field of bed height csvs,
+	which sometimes contain non-year character.
+
+	* src/main/java/de/intevation/flys/importer/parsers/BedHeightParser.java:
+	  Extend RE to parse year field of Bed Height data csv.
+
 2012-09-27  Ingo Weinzierl <ingo@intevation.de>
 
 	* src/main/java/de/intevation/flys/model/RiverAxis.java:
--- a/flys-backend/src/main/java/de/intevation/flys/importer/parsers/BedHeightParser.java	Thu Sep 27 13:43:31 2012 +0000
+++ b/flys-backend/src/main/java/de/intevation/flys/importer/parsers/BedHeightParser.java	Thu Sep 27 17:45:49 2012 +0000
@@ -46,7 +46,7 @@
     public static final String SEPERATOR_CHAR  = ";";
 
     public static final Pattern META_YEAR =
-        Pattern.compile("^Jahr: (\\d*).*");
+        Pattern.compile("^Jahr: [^0-9]*(\\d*).*");
 
     public static final Pattern META_TIMEINTERVAL =
         Pattern.compile("^Zeitraum: Epoche (\\d*)-(\\d*).*");

http://dive4elements.wald.intevation.org