users@jaxb.java.net

Re: jaxb1.0 -> 1.0.1 Cannot compile several schemas with same simpleType

From: Kohsuke Kawaguchi <Kohsuke.Kawaguchi_at_Sun.COM>
Date: Fri, 20 Jun 2003 07:47:25 -0700

No, this is not a name collision error. This is simply an error where he
defined the same type more than once. No customization will resolve this
problem.

> xjc 1.0 compiles everything successfully, creating a single copy of the
> generated class RthXmlVDouble.java

I'm having hard time understanding why it generated the RthXmlVDouble
class. It shouldn't have.

> Is there any workaround (like undocumented command option) ? Why does

No.

> it prevent me to generate java files if the simpleType structure is the
> same in all schema files

The fact that you've defined it twice is causing XJC to choke.


> I cannot change schema files (like to take out the same type into the
> separate schema) because other product generates them.

Just in case you are a schema guru, technically, the schema spec seems
to allow multiple definitions to be given so long as they are "identical"
(but without defining what it means to be "identical".)

So we might attempt to do something about it, but I seriously recommend
you to remove duplicate definitions. In almost all computer languages,
such thing is not allowed.

--
Kohsuke Kawaguchi <kohsuke.kawaguchi_at_sun.com>