planetfederal / wps-gui

Graphical User Interface (Model Builder) for OGC:WPS (Web Processing Services)
http://boundlessgeo.com
Apache License 2.0
27 stars 15 forks source link

use GML input #112

Closed bartvde closed 10 years ago

bartvde commented 10 years ago

follow-up to #111 which was for WKT

bartvde commented 10 years ago

Something like:

<gml:Polygon xmlns:gml="http://www.opengis.net/gml" srsName="EPSG:4326">
<gml:exterior>
<gml:LinearRing>
    <gml:posList>-84.375 31.640625 -60.46875 35.859375 -52.03125 0.703125 -81.5625 -1.40625 -84.375 31.640625</gml:posList>
</gml:LinearRing>
</gml:exterior>
</gml:Polygon>

but is going to be tricky with JSONIX probably, because this cannot be serialised as string:

<p0:Execute xmlns:p0="http://www.opengis.net/wps/1.0.0" service="WPS" version="1.0.0"><p1:Identifier xmlns:p1="http://www.opengis.net/ows/1.1">geo:buffer</p1:Identifier><p0:DataInputs><p0:Input><p1:Identifier xmlns:p1="http://www.opengis.net/ows/1.1">geom</p1:Identifier><p0:Data><p0:ComplexData mimeType="application/wkt">&lt;gml:Polygon xmlns:gml="http://www.opengis.net/gml" srsName="EPSG:900913"&gt; &lt;gml:exterior&gt; &lt;gml:LinearRing&gt;     &lt;gml:posList&gt;-10723197.824070806 4931105.56873329 -7514065.628545965 5713820.738373495 -7592337.145509986 1095801.2374962866 -10723197.824070806 4931105.56873329&lt;/gml:posList&gt; &lt;/gml:LinearRing&gt; &lt;/gml:exterior&gt; &lt;/gml:Polygon&gt;</p0:ComplexData></p0:Data></p0:Input><p0:Input><p1:Identifier xmlns:p1="http://www.opengis.net/ows/1.1">distance</p1:Identifier><p0:Data><p0:LiteralData>444444</p0:LiteralData></p0:Data></p0:Input></p0:DataInputs><p0:ResponseForm><p0:RawDataOutput mimeType="application/wkt"><p1:Identifier xmlns:p1="http://www.opengis.net/ows/1.1">result</p1:Identifier></p0:RawDataOutput></p0:ResponseForm></p0:Execute>

If we did not commit to this, we should leave it out.

bartvde commented 10 years ago

I need to check with JSONIX if this can be done

bartvde commented 10 years ago

have you tries setting the content property ( I guess it is this one: https://github.com/highsource/ogc-schemas/blob/master/scripts/lib/WPS_1_0_0.js#L507-L512) as DOM? I mean, create GML in DOM and set it there? The property is "anyElement", it should accept DOM. How do you set the GML now?

I was also thinking about something like "adapters" so that you could for instance sen the OL Geomtries or GeoJSON and get it marshalled as GML. Marshalling should not actually be a problem, but unmarshalling GML with all the deprecated cases is cumbersome.