Martin,
I have made some small modifications to your sample SGF (Simple GML
Format?) file.
My changes were as follows:
- I added a "name" attribute to the start tag of the featureCollection
element. This would allow an SGF file to contain multiple
featureCollection elements. OpenJUMP or the parsing program could then
create a layer for each FeatureCollection in the file. For example,
OpenJUMP would create a layer named "Cities" to contain the city
Features.
- I added FID and GID attributes.
- I added a "type" attribute to the feature element. This would allow
OpenJUMP or the parsing program to validate the content of the feature
using an external schema or other external data. (This wouldn't be
required, but at least if we identify the type of feature with an
attribute it would be an option.)
What do you think?
The Sunburned Surveyor
P.S. - Do you think it would be possible to steal code from the
existing GML parser in OpenJUMP/JUMP that creates JTS geometry objects
from <gml:Geometry> elements?
<?xml version='1.0' encoding='UTF-8'?>
<cities xmlns:gml="http://www.opengis.net/gml"
xmlns:xsi="http://www.w3.org/2000/10/XMLSchema-instance" >
<featureCollection name="Cities">
<feature fid="200354" type="City">
<geometry gid="102216">
<gml:Point>
<gml:coordinates>1008983.125,455516.906,0.0 </gml:coordinates>
</gml:Point>
</geometry>
<fcode type="string">AR08750000</fcode>
<name type="string">Tofino</name>
<pop2000 type="int">1540</pop2000>
</feature>
<feature fid="200355" type="City">
<geometry gid="102217">
<gml:Point>
<gml:coordinates>1024338.125,1028831.0,0.0 </gml:coordinates>
</gml:Point>
</geometry>
<fcode>AR08750000</fcode>
<name>Victoria</name>
<pop2000>350000</pop2000>
</feature>
<feature fid="200356" type="City">
<geometry gid="102218">
<gml:Point>
<gml:coordinates>1281937.875,642687.563,0.0 </gml:coordinates>
</gml:Point>
</geometry>
<fcode>AR08750000</fcode>
<name>Vancouver</name>
<pop2000>2000000</pop2000>
</feature>
</featureCollection>
</cities>
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel