xjc jaxb Two declarations cause a collision in the ObjectFactory class.



During generation of a webservice with eclipse europe (xfire) using
jaxb I got an error message.
After trying the same with netbeans 6.0 I got an error message.
As it seams, the xsd defenition is case sensative the xjc compiler is
not.

Is there a known work around?

Problem can be reproduced with xjc from jdk 1.6.0_03
output from compilation

H:\Mijn Documenten\KLIC\xjcbug> d:\apps\Java\jdk1.6.0_03\bin\xjc
myschema.xsd
parsing a schema...
compiling a schema...
[ERROR] Two declarations cause a collision in the ObjectFactory class.
line 46 of file:/H:/Mijn%20Documenten/KLIC/xjcbug/myschema.xsd

[ERROR] (Related to above error) This is the other declaration.
line 48 of file:/H:/Mijn%20Documenten/KLIC/xjcbug/myschema.xsd

[ERROR] Two declarations cause a collision in the ObjectFactory class.
line 48 of file:/H:/Mijn%20Documenten/KLIC/xjcbug/myschema.xsd

[ERROR] (Related to above error) This is the other declaration.
line 47 of file:/H:/Mijn%20Documenten/KLIC/xjcbug/myschema.xsd

Failed to produce code.

schema myschema.xsd

<?xml version="1.0" encoding="UTF-8"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema";
elementFormDefault="qualified" attributeFormDefault="unqualified">
<!--
Simple type defenities
-->
<xs:simpleType name="straatType">
<xs:restriction base="xs:string">
<xs:maxLength value="32"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="huisNummerType">
<xs:restriction base="xs:int">
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="huisNummerToevoegingType">
<xs:restriction base="xs:string">
<xs:maxLength value="4"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="postCodeType">
<xs:restriction base="xs:string">
<xs:maxLength value="6"/>
<xs:pattern value="([0-9]{4,4}[A-Z]{2,2})"/>
</xs:restriction>
</xs:simpleType>
<xs:simpleType name="woonPlaatsType">
<xs:restriction base="xs:string">
<xs:maxLength value="32"/>
</xs:restriction>
</xs:simpleType>
<!--
Complexe type definities
-->
<xs:complexType name="adresType">
<xs:sequence>
<xs:element name="straat" type="straatType" />
<xs:element name="huisnummer" type="huisNummerType" />
<xs:element name="huisnummertoevoeging"
type="huisNummerToevoegingType" minOccurs="0" />
<xs:element name="postcode" type="postCodeType" />
<xs:element name="woonplaats" type="woonPlaatsType" />
</xs:sequence>
</xs:complexType>
<!--
Element definities
-->
<xs:element name="adres" type="adresType"/>
<xs:element name="_adres" type="adresType"/>
<xs:element name="Adres" type="adresType"/>
</xs:schema>
.



Relevant Pages

  • xjc jaxb Two declarations cause a collision in the ObjectFactory class.
    ... After trying the same with netbeans 6.0 I got an error message. ... the xsd defenition is case sensative the xjc compiler is ... Two declarations cause a collision in the ObjectFactory class. ... Complexe type definities ...
    (comp.lang.java.programmer)
  • xjc jaxb Two declarations cause a collision in the ObjectFactory class.
    ... After trying the same with netbeans 6.0 I got an error message. ... the xsd defenition is case sensative the xjc compiler is ... Two declarations cause a collision in the ObjectFactory class. ... Complexe type definities ...
    (comp.sys.sun.apps)
  • Re: Error a: _mayn.c:12 illegal return type, found int expected void
    ... > a given compiler writer allows or forbids is ... The error message I recieved was in plain english ... >Do you, Jacob, perhaps have a belief that all C programers ... the purpose of lint is to provide error messages. ...
    (comp.compilers.lcc)
  • understanding segmentation faults
    ... Is "segmentation fault" an error message that is issued by the operating ... not a problem that the compiler vendors can easily solve. ... technical terminology an "array section"?). ...
    (comp.lang.fortran)
  • Re: Ommiting void
    ... easily avoid the issue by always declarating "int main". ... I do, however, also drop K&R style declarations, along with implicit ... If you don't want to support them in your compiler, that's fine, ... actually, in my case I seem not to mix well with moderators, as moderators necessarily reject my posts, and English teachers necessarily give me very low grades, even when my grammar and spelling is correct. ...
    (comp.std.c)