users@jaxb.java.net

Re: WSDP 1.2 and xsd:import

From: Thomas Plümpe <thomanski_at_gmx.de>
Date: Fri, 13 Jun 2003 08:26:38 +0200

> > If you want to keep the import just refrain from giving the imported
> > schema (in my case the WSDL schema) to xjc, that worked for me.
>
> I need XJC to compile my included XSD file as well, since I directly
> use the structures in those files.
Yes, I understand. But that is indeed what happens. If you don't
enumerate the imported schemas on the command line, the compilation does
work and the imported schemas do get compiled along with the importing
one.

> As an FYI, I have three XSD files, all with accompanying XJB files.
> Each of the three files also generates objects into three different
> Java packages. One of the three XSDs uses structures in another, and
> hence I have a single xsd:import.
Okay, that's different in my case: I have one binding file for all the
schemas (with each going into its own package), but that works nicely
when I only give the importing ones to xjc.

Or to be more precise, I just found out that the compilation works
nicely, but I am unable to unmarshal a file that makes use of two
schemas with the same targetNamespace. I will further investigate this
and then post a more detailed description.

> This use to work in WSDP 1.1, but now XJC appears to be attempting to
> do multiple compilation passes of the included XSD file, once as a file
> given directly to XJC and once during include.
>
> Anyone else see this? Feels like a bug to me.
Feels like a bug to me, too. I only meant to provide a workaround. ;)

Thomas