Hi,
can you please create a new Jira issue at
http://jira.codehaus.org/browse/CASTOR
and attach at least the XML schema and the binding file. We'll be
looking into this asap. And if that used to work with older versions of
Castor, please don't forget to mention what versions of Castor you are
referring to.
Regards
Werner
Never Anybody wrote:
The specific case that fails for me is when a simpleType with an
enumeration is defined explicitly for an element. The generated types
are not assigned correct packages according to binding. The following
will generate ELEMENTA type without the defined package
"net.elementa.bind" but will put ROOT in the correct package.
Test:
bindking.xml:
<binding xmlns="http://www.castor.org/SourceGenerator/Binding"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
defaultBinding="element">
<package>
<name>net.elementa.bind</name>
<namespace>http://elementa.net/elementa</namespace>
</package>
</binding>
elementa.xsd:
<xs:schema targetNamespace="http://elementa.net/elementa"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="ROOT">
<xs:complexType>
<xs:sequence>
<xs:element ref="ELEMENTA"/>
</xs:sequence>
</xs:complexType>
</xs:element>
<xs:element name="ELEMENTA">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:enumeration value="a"/>
<xs:enumeration value="b"/>
<xs:enumeration value="c"/>
</xs:restriction>
</xs:simpleType>
</xs:element>
</xs:schema>
As always, appologies if this is already listed - I couldn't find it.
It works in earlier versions of castor.
thanks,
k
------------------------------------------------------------------------
Never miss a thing. Make Yahoo your homepage.
<http://us.rd.yahoo.com/evt=51438/*http://www.yahoo.com/r/hs>
---------------------------------------------------------------------
To unsubscribe from this list, please visit:
http://xircles.codehaus.org/manage_email