users@jaxb.java.net

Re: How to resolve class/interface conflict

From: Hristo Stoyanov <hr_stoyanov_at_yahoo.com>
Date: Fri, 21 Jan 2005 11:24:18 -0800 (PST)

Thanks Ryan-,

I looked at the binding file, but I need to read the JAXB docs more. One thing that I noticed in the example binding file you pointed me to, was that I have to specify the schema location for which the rules apply:

...

<jxb:bindings schemaLocation="example.xsd" node="/xs:schema">

...

I have a few hundreds of such schema files :-(

Take care,

Hristo

 

 

> Hi all-,
> I am getting the below conflicts, trying to compile these schemas
> (http://www.irs.gov/efile/article/0,,id=128360,00.html). Since there are
> way to many conflicts, it is not feasible to write customization file
> and enumerate all of them. Is there any xjc compile option, so it can
> ignore all duplicate classes? I tried that with XmlBeans and it workds
> just fine.

No, there is no option to ignore duplicate classes, but there are
customizations that will help you resolve most of them automatically.
Please take a look at the "fix-collides"[1] sample app in your JAXB
distribution. I'm guessing that you have conflicts between global
elements and complexTypes in your schema. In that case, you'll want
to use the jxb:nameXmlTransform customization. If there are other
naming conflicts between the schema and Java reserved words, then
you'll have to use the jxb:class customization (which is also shown
in the sample app).

Thanks,

--Ryan



                
---------------------------------
Do you Yahoo!?
 Yahoo! Search presents - Jib Jab's 'Second Term'