Hmm, I tried using jaxb:class to rename the classes, but I'm still
getting compile errors in the resulting sources. Recall I have this
schema fragment:
<xsd:element name="TemplateTags">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="TemplateTags">
<xsd:complexType>
<xsd:sequence>
<xsd:element
name="TemplateTag" type="xsd:string" minOccurs="0"
maxOccurs="unbounded"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
I used a customization like this:
<jxb:bindings
node="/xs:schema/xs:element[@name='TemplateTags']">
<jxb:class name="TemplateTagsInfo"/>
</jxb:bindings>
I do end up with a TemplateTagsInfo interface which compiles ok, but it
looks like this:
public interface TemplateTagsInfo
extends javax.xml.bind.Element,
com.seagullsw.appinterface.server.backend.hsc.schema.bind.TemplateTagsTy
pe
and the TemplateTagsType is the one that does not compile. It has this:
public interface TemplateTagsType {
....
public interface TemplateTagsType {
Any more suggestions?
Thanks,
Lee
> -----Original Message-----
> From: Kohsuke Kawaguchi [mailto:Kohsuke.Kawaguchi_at_Sun.COM]
> Sent: Tuesday, August 31, 2004 3:35 PM
> To: users_at_jaxb.dev.java.net
> Subject: Re: Duplicate nested element
>
>
> Interesting. I never knew that the following Java code is illegal:
>
> class Test {
> class Test {}
> }
>
> I think the work around is to use <jaxb:class> customization
> and rename one of those TemplateTags to another class name.
>
> The samples bundled with the RI should show you how to do this.
>
>
> regards,
> --
> Kohsuke Kawaguchi
> Sun Microsystems kohsuke.kawaguchi_at_sun.com
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe_at_jaxb.dev.java.net
> For additional commands, e-mail: users-help_at_jaxb.dev.java.net
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe_at_jaxb.dev.java.net
For additional commands, e-mail: users-help_at_jaxb.dev.java.net