Mercurial > dive4elements > river
diff flys-backend/src/main/java/de/intevation/flys/importer/Importer.java @ 2804:68d1661a57cf
Added a new config option to specify a INFO.gew file by system property.
flys-backend/trunk@4182 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Ingo Weinzierl <ingo.weinzierl@intevation.de> |
---|---|
date | Thu, 29 Mar 2012 07:24:15 +0000 |
parents | 268f8da412e3 |
children | 33f40b23edd8 |
line wrap: on
line diff
--- a/flys-backend/src/main/java/de/intevation/flys/importer/Importer.java Mon Mar 19 06:11:38 2012 +0000 +++ b/flys-backend/src/main/java/de/intevation/flys/importer/Importer.java Thu Mar 29 07:24:15 2012 +0000 @@ -125,6 +125,17 @@ } } + String gew = Config.INSTANCE.getInfoGewFile(); + if (gew != null && gew.length() > 0) { + log.info("parsing info gew file: " + gew); + try { + infoGewParser.parse(new File(gew)); + } + catch (IOException ioe) { + log.error("cannot parse file: " + gew); + } + } + if (!Config.INSTANCE.dryRun()) { new Importer(infoGewParser.getRivers()).writeToDatabase(); }