Hi,
Perhaps I have not found the complete solution yet, because I just
noticed that a href attribute is used where I would expect a xlink:href
attribute. Also the xlink namespace definition is missing. Am I still
doing something wrong?
Thanks for your reaction.
Regards,
Rob van Swol
On 21-4-2010 8:58, Rob van Swol wrote:
Hi,
To answer my own question:
1) changing SurfacePropertyType into GeometryPropertyType in the
schema and creating an empty Geometry does the trick!
2) looking at the code I discovered that the check on existing id's is
done based on the id of the feature NOT on the id of the geometry! I am
able to produce different gml:Polygon elements with the same gml:id.
[ Since I am using a DefaultFeatureCollection I cannot test if
duplicate id's are handled correctly, because the FeatureCollection
does not accept duplicate id's.
3) Remains one issue: the gml:boundedBy element of the featuremember
refering to the geometry of the first is NULL; is there a way to repair
this? (Or to leave this element out?)
Regards,
Rob van Swol
Here is the new result:
<?xml version="1.0" encoding="UTF-8"?>
<gml:FeatureCollection
xsi:schemaLocation="http://geomatics.nlr.nl/IMDTool
IMDTool.xsd
http://www.opengis.net/gml
http://schemas.opengis.net/gml/3.1.1/base/gml.xsd"
xmlns:imdt="http://geomatics.nlr.nl/IMDTool"
xmlns:gml="http://www.opengis.net/gml"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<gml:featureMembers>
<imdt:Effect gml:id="E1">
<gml:boundedBy>
<gml:Envelope
srsName="http://www.opengis.net/gml/srs/epsg.xml#28992">
<gml:lowerCorner>127200.0
493100.0</gml:lowerCorner>
<gml:upperCorner>130000.0
495100.0</gml:upperCorner>
</gml:Envelope>
</gml:boundedBy>
<imdt:id>E1</imdt:id>
<imdt:title>effect1</imdt:title>
<imdt:xeffecten></imdt:xeffecten>
<imdt:xmaatregelen>M1</imdt:xmaatregelen>
<imdt:geometrie>
<!--#piet-->
<gml:Polygon gml:id="piet">
<gml:name>piet</gml:name>
<gml:exterior>
<gml:LinearRing>
<gml:posList>127200.0 493100.0
127200.0 495100.0 130000.0 495100.0 130000.0 493100.0 127200.0
493100.0</gml:posList>
</gml:LinearRing>
</gml:exterior>
</gml:Polygon>
</imdt:geometrie>
</imdt:Effect>
<imdt:Effect gml:id="E2">
<gml:boundedBy>
<gml:Null>unknown</gml:Null>
</gml:boundedBy>
<imdt:id>E2</imdt:id>
<imdt:title>Eerste effect</imdt:title>
<imdt:xeffecten></imdt:xeffecten>
<imdt:xmaatregelen>M1</imdt:xmaatregelen>
<imdt:geometrie href=""/>
</imdt:Effect>
</gml:featureMembers>
</gml:FeatureCollection>
On 21-4-2010 3:51, Ben Caradoc-Davies wrote:
Andrea,
is XSIdRegistry turned off for simple features, for performance and
memory reasons? I recall a discussion ...
Kind regards,
Ben.
On 20/04/10 20:46, Rob van Swol wrote:
Hi,
I have a simple GML3 Application schema which I use to encode a featurecollection to a gml document. However I do not succeed in getting duplicate gml:id's in geometry elements to be replaced by xlink:href attributes. Even worse: duplicate id's are accepted while I thought that the XSDIdRegistry would take care of that.
I am using geotools 2.6.3
Any suggestions?
Regards,
--
National Aerospace Laboratory - NLR
Dr. R.W. (Rob) van Swol
Senior Scientist
Space Department
Phone |
+31(0)527 24 8252
|
E-mail |
|
|
|
|
|
The NLR
disclaimer is valid for NLR e-mail messages.
--
National Aerospace Laboratory - NLR
Dr. R.W. (Rob) van Swol
Senior Scientist
Space Department
Phone |
+31(0)527 24 8252
|
E-mail |
|
|
|
|
|
The NLR
disclaimer is valid for NLR e-mail messages.
|
------------------------------------------------------------------------------
_______________________________________________
Geotools-devel mailing list
Geotools-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geotools-devel