users@jaxb.java.net

Re: question about modularization

From: Pavel Bucek <Pavel.Bucek_at_Sun.COM>
Date: Mon, 23 Nov 2009 20:00:16 +0100

Felipe Gaścho wrote:
> Now, I have some questions, mainly regarding modularization issues.
> Maybe you could help me on this:
>
> - Let's assume we have module A with a.xsd inside and module B with
> b.xsd. a.xsd defines type t, type u and type v; type u is abstract.
> a.xsd uses the types t and v and extends type u.
>
> The question is now if it's possible to generate the according
> JAXB-Java-classes at build time for every module separately. This would
> mean that we have calsses for the types t, u and v in module A. And
> class that extends type u in module B. This would mean that during build
> time of module B, JAXB has to know that the classes of a.xsd have been
> generated already and as well their names and packages.
> - Is this possible?
>
yes, it is. Look at
http://weblogs.java.net/blog/2006/09/05/separate-compilation-jaxb-ri-21
> - Does this make sense?
>
> Another question is about file resolving.
> - Is there a possibility to provide an alternative file resolver (e.g.
> that looks referenced schema files up in the classpath)?
>
not sure what you mean or what you want to achieve. If you mean this as
a XML input the answer is "no", but please try describe your use case in
more detail..

Pavel