Hi

Using Castor v0.95

We have 27 .xsd files that is generated into .java code using Castor.
Damm there are some naming conflicts and we have solved most of them by
renaming the element names in the .xsd files.

Lately I wanted to check out the Castor bindings file but it fails.

Basically I have to complex types with the same name but with different
content. Therefore Castor generates two .java files with the same name
and thus overwrites the previously generated. Sadly you don't get any
warning from the source code generator that a file already exists!!!

I have this compex element (Listing_List) I want to be renamed, so 
I don't have a java class naming conflict:

<Message_Data>
  <Message_Body>
    <CompletePaidList>
       <Listing_List>
  ...

Yes all the elements above are complexTypes.


So my bindings file is:

    <cbf:elementBinding name="complexType:Listing_List">
        <cbf:java-class name="My_Listing_List"/>
    </cbf:elementBinding>


But it fails all the time.


I have tried a lot of combinations. Do you have to input the fully
qualified path in the name? Or can it just be some kind of relative
path?

    <cbf:complexTypeBinding name="complexType:Listing_List">
        <cbf:java-class name="Damm"/>
    </cbf:complexTypeBinding>

    <cbf:complexTypeBinding name="Listing_List">
        <cbf:java-class name="Damm"/>
    </cbf:complexTypeBinding>


Yes I have seen the examples distributed with Castor but they makes my
bindingsfile look alright.


Castor really needs better documentation how to use the bindings file. A
warning when generating the source code when overwriting an existing
java source would be excellent to spot the naming conflicts.


/Claus

----------------------------------------------------------- 
If you wish to unsubscribe from this mailing, send mail to
[EMAIL PROTECTED] with a subject of:
        unsubscribe castor-dev

Reply via email to