users@jaxb.java.net

Re: Java packages with relation to Nested schemas.

From: Ed Mooney <Ed.Mooney_at_Sun.COM>
Date: Tue, 28 Oct 2003 10:46:58 -0500

Hi Adrian,

When you compile mainSchema1.xsd and mainSchema2.xsd, xjc also compiles
common.xsd because of the include statements. If you're able to use
import instead, samples/ubl illustrates the pattern you describe.

Regards,
-- 
Ed Mooney         |Sun Microsystems, Inc.|Time flies like
Java Web Services |UBUR02-201            |an arrow, but
Ed.Mooney_at_Sun.COM |1 Network Drive       |fruit flies like
781-442-0459      |Burlington, MA  01803 |a banana. Groucho
Adrian Brogan wrote:
> Hi
> 
>  
> 
> There may be more than one answer to this question, but here goes:
> 
>  
> 
> Assume I have one schema common.xsd that contains common building blocks 
> that other schema (assume mainSchema1.xsd and mainSchema2.xsd) will use.
> 
> mainSchema1.xsd and mainSchema2.xsd use common.xsd by means of the 
> include statement.
> 
>  
> 
> What I require:
> 
> When I run xjc, I want the generated classes for common.xsd to go to one 
> java package, mainSchema1.xsd classes to another package and 
> mainSchema2.xsd to a third package.
> 
>  
> 
> Note: Ideally I want all schemas to reside in the same namespace.
> 
>  
> 
> I have tried playing around with numerous options on the compiler and 
> the jaxb:package element in the bindings framework but to no avail.
> 
>  
> 
> What solutions are there to this problem?
> 
>  
> 
> Regards
> 
>  
> 
> Adrian
> 
>  
> 
>  
> 
> 
> ------------------------------------------------------------------------
> 
> ---------------------------------------------------------------------
> 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