Strabon
changeset 924:a4e8a499ecfb
commented handling of MultiGeometry case that I assume was using when we were stylying the KML output and now was causing an OutOfBound exception for empty geometries (i.e., MULTIGEOMETRY EMPTY)
author | Babis Nikolaou <charnik@di.uoa.gr> |
---|---|
date | Mon Mar 25 01:47:02 2013 +0200 (2013-03-25) |
parents | 0189a451757d |
children | 39d271902813 |
files | resultio-spatial/sparqlkml/src/main/java/org/openrdf/query/resultio/sparqlkml/stSPARQLResultsKMLWriter.java |
line diff
1.1 --- a/resultio-spatial/sparqlkml/src/main/java/org/openrdf/query/resultio/sparqlkml/stSPARQLResultsKMLWriter.java Mon Mar 25 01:43:35 2013 +0200 1.2 +++ b/resultio-spatial/sparqlkml/src/main/java/org/openrdf/query/resultio/sparqlkml/stSPARQLResultsKMLWriter.java Mon Mar 25 01:47:02 2013 +0200 1.3 @@ -367,11 +367,10 @@ 1.4 encoder.encode(geom, geometryType, baos); 1.5 geometry = baos.toString().substring(38).replaceAll(" xmlns:kml=\"http://earth.google.com/kml/2.1\"", "").replaceAll("kml:", ""); 1.6 1.7 + /* 1.8 if (geometryType == KML.MultiGeometry) { 1.9 geometry = geometry.substring(geometry.indexOf("<MultiGeometry>") + 15, geometry.indexOf("</MultiGeometry>")); 1.10 } 1.11 - 1.12 - /* 1.13 * if(geom instanceof Point) { geometry = 1.14 * geometry.substring(geometry.indexOf("<Point>"), 1.15 * geometry.indexOf("</Point>") + 8); } else if(geom instanceof