[geotk] SE/SLD FeatureTypeName Bug
Cullen Rombach
cullenr at imagemattersllc.com
Wed Jul 5 13:02:09 PDT 2017
Hello,
I am working with the Geotoolkit SE/SLD API and I have run into what seems
to be a bug with XML serialization to SE 1.1.0.
When Geotoolkit reads a FeatureTypeName (an element of FeaturetypeStyle)
from an XML file, it uses org.geotoolkit.feature.type.NamesExt to create a
GenericName with a null NameSpace as its scope. this causes some pretty
strange behavior when serializing generated FeatureTypeStyle objects back
to XML.
This is an example FeatureTypeName element that I'm reading using
Geotoolkit:
<se:FeatureTypeName xmlns:tds="
http://metadata.dod.mil/mdr/ns/GSIP/4.0/tds/4.0
">tds:MissileSiteGeosurface</se:FeatureTypeName>
However, when using StyleXmlIO to write the generated FeatureTypeStyle
object back to SE XML version 1.1.0, the FeatureTypeName element comes out
like this:
<se:FeatureTypeName xmlns:ns9="null:">ns9:
http://metadata.dod.mil/mdr/ns/GSIP/4.0/tds/4.0:MissileSiteGeosurface
</se:FeatureTypeName>
This is messy and, more importantly, incorrect. I would expect to see
something more like the input XML. Note that when I serialize using the
SLD 1.0.0 standard instead, the output looks like the following, which
seems fine to me:
<sld:FeatureTypeName>
http://metadata.dod.mil/mdr/ns/GSIP/4.0/tds/4.0:MissileSiteGeosurface
</sld:FeatureTypeName>
Any help with how to remedy this issue would be much appreciated.
Regards,
Cullen Rombach
Image Matters LLC
www.imagemattersllc.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/geotoolkit/attachments/20170705/66fc0ca0/attachment.html>
More information about the Geotoolkit
mailing list