How can I read with 'deegree' a GML3.2 with an arc?
The simplified data contains an arc:
<gml:Polygon>
<gml:exterior>
<gml:Ring>
<gml:curveMember>
<gml:Curve>
<gml:segments>
<gml:LineStringSegment>
<gml:posList>44.605 773.516 40.806 775.320</gml:posList>
</gml:LineStringSegment>
<gml:LineStringSegment>
<gml:posList>40.806 775.320 38.522 759.491</gml:posList>
</gml:LineStringSegment>
<gml:LineStringSegment>
<gml:posList>38.522 759.491 45.178 773.702</gml:posList>
</gml:LineStringSegment>
<gml:Arc>
<gml:posList>45.178 773.702 44.930 773.491 44.605 773.516</gml:posList>
</gml:Arc>
</gml:segments>
</gml:Curve>
</gml:curveMember>
</gml:Ring>
</gml:exterior>
</gml:Polygon>
When performing this method
GMLObject gmlObject = null;
XMLStreamReader r = XMLInputFactory.newInstance().createXMLStreamReader(new StringReader(gml));
GMLStreamReader gmlStreamReader = GMLInputFactory.createGMLStreamReader(gmlVersion, r);
gmlObject = gmlStreamReader.read(); // --> error 1
gmlObject.toString(); // --> error 2
I get these errors:
- Method threw 'java.lang.IllegalArgumentException' exception. Cannot evaluate org.deegree.geometry.standard.primitive.DefaultPolygon.toString()
- java.lang.IllegalArgumentException: Cannot determine control points for ring, contains non-linear segments.
How to cope with this issue?
CURVEPOLYGON (COMPOUNDCURVE ((44.605 773.516,40.806 775.32),(40.806 775.32,38.522 759.491),(38.522 759.491,45.178 773.702),CIRCULARSTRING (45.178 773.702,44.93 773.491,44.605 773.516)))
. Write mail to deegree users mailing list and ask sourceforge.net/p/deegree/mailman/deegree-users.