users@jaxb.java.net

follow-up GML conflicting when binding SensorML schema

From: Peizhao Hu <peizhao_at_itee.uq.edu.au>
Date: Thu, 19 Apr 2007 00:18:17 +1000

Hi,

regarding to these errors:
phu_at_phu-mac:~/programming/SensorML_examples/SensorMLV1.0/sweCommon/1.0.0
$ xjc.sh positionTypes.xsd
parsing a schema...
compiling a schema...
[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 1462 of
http://schemas.opengis.net/gml/3.1.1/base/geometryPrimitives.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 1516 of
http://schemas.opengis.net/gml/3.1.1/base/geometryPrimitives.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 201 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 220 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 283 of
http://schemas.opengis.net/gml/3.1.1/base/geometryBasic0d1d.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 13 of
http://schemas.opengis.net/gml/3.1.1/base/geometryPrimitives.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 36 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 51 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 169 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 150 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 293 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 312 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 73 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 92 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 86 of
http://schemas.opengis.net/gml/3.1.1/base/geometryBasic2d.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 1084 of
http://schemas.opengis.net/gml/3.1.1/base/geometryPrimitives.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 95 of http://schemas.opengis.net/gml/3.1.1/base/feature.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 111 of http://schemas.opengis.net/gml/3.1.1/base/feature.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 921 of
http://schemas.opengis.net/gml/3.1.1/base/geometryPrimitives.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 14 of
http://schemas.opengis.net/gml/3.1.1/base/geometryBasic2d.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
 line 252 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

[ERROR] (Related to above error) This is the other declaration.
 line 271 of http://schemas.opengis.net/gml/3.1.1/base/defaultStyle.xsd

Failed to produce code.
phu_at_phu-mac:~/programming/SensorML_examples/SensorMLV1.0/sweCommon/1.0.0
$


I have a few questions and hope someone can ask some of them.
1. what do "Two declarations cause a collision in the ObjectFactory
class" and "(Related to above error) This is the other declaration." mean?
2. do they really mean name collision with XML elements? I suspect these
errors occur whenever there is a substitutionGroup, like
<element name="_Solid" type="gml:AbstractSolidType" abstract="true"
substitutionGroup="gml:_GeometricPrimitive">



Comments about the error from SensorML community:

I believe these are related to JAXB getting confused be declarations of
XML elements whose name differs only by lexical case. XML names are
case-sensitive (this is specifically stated in the *XML* spec from W3C).
You have to configure your data binding environment to respect this.





-- 
regards;
Peizhao