changeset 1124:28a595b32980

Set the 'typ' attribute of lines and polygons in barrier shapefiles while shapefile creation. flys-artifacts/trunk@2633 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Ingo Weinzierl <ingo.weinzierl@intevation.de>
date Thu, 01 Sep 2011 12:47:01 +0000
parents be9bb260b835
children 65d8b3340397
files flys-artifacts/ChangeLog flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java
diffstat 2 files changed, 11 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/flys-artifacts/ChangeLog	Thu Sep 01 12:23:23 2011 +0000
+++ b/flys-artifacts/ChangeLog	Thu Sep 01 12:47:01 2011 +0000
@@ -1,3 +1,8 @@
+2011-09-01  Ingo Weinzierl <ingo@intevation.de>
+
+	* src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java:
+	  Set the "typ" attribute of lines and polygons in barrier shapefiles.
+
 2011-09-01  Ingo Weinzierl <ingo@intevation.de>
 
 	* src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java:
--- a/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java	Thu Sep 01 12:23:23 2011 +0000
+++ b/flys-artifacts/src/main/java/de/intevation/flys/artifacts/states/FloodMapState.java	Thu Sep 01 12:47:01 2011 +0000
@@ -304,9 +304,13 @@
         File shapeLines = new File(dir, WSPLGEN_BARRIERS_LINES);
         File shapePolys = new File(dir, WSPLGEN_BARRIERS_POLY);
 
+        Object[][] obj = new Object[][] {
+            new Object[] { "typ", String.class }
+        };
+
         boolean l = GeometryUtils.writeShapefile(
             shapeLines,
-            GeometryUtils.buildFeatureType("lines", srs, LineString.class),
+            GeometryUtils.buildFeatureType("lines", srs, LineString.class, obj),
             fcs[0]);
 
         if (l) {
@@ -318,7 +322,7 @@
 
         boolean p = GeometryUtils.writeShapefile(
             shapePolys,
-            GeometryUtils.buildFeatureType("polygons", srs, Polygon.class),
+            GeometryUtils.buildFeatureType("polygons", srs, Polygon.class, obj),
             fcs[1]);
 
         if (p) {

http://dive4elements.wald.intevation.org