Bruce,

thanx, very helpful,  I should've looked there first.  I have worked this
out, but the company third party company have given me a simplified schema
to use instead, which is great, but still has naming collisions.  SO I
wrote another binding file, but can't seem to get this to work with the new
schema.

I'm not the type to need hand holding for this sort of stuff, but the
biggest challenge I'm finding is knowing what the different parts of the
binding xml file are doing?  Wondered if you might be able to help?

I have included the schema, and my binding file, with only the first
element I am trying to do this with!  I use WSAD for development, so as far
as schemas, and xml goes I have been spoilt with generating tools!

I understand if you don't have the time to explain, and I will send this to
the user group if you can't help, but I thought I would try you first as
you gave me the simplest answer to my previous question.

ok:

Binding entry:

This tag can be
elementBinding|attributeBinding|complexTypeBinding|groupBinding I assume
that this is referring to the type of the element you are binding to for
example I am wanting to bind the ward of Premises, so I thought that
elementBinding would be the one I want to work with, then there's the name
attribute, the documentation is soooooo confusing!   but looking at the
example I came to a (logical) conclusion that I would need complexType as
the element Premises is defining (within it) as complexType.  Therefore:

<cbf:elementBinding name="complexType:Premises/Ward">
                  <cbf:java-class name="PremisesWard" />
</cbf:elementTypeBinding>

Unfortunately this isn't doing anything, and I'm still getting the warning
in the output!  I have also tried various permutations using element for
the Binding tag, and the prefix on the name!

Schema:

(See attached file: FlareReqComp.xsd)


Any help would be appreciated!  If I can work it out and understand it, I
think I'll document it and put together a PDF for anyone else using it!
Very frustrating!

mARK
                                                                       
                                                                       
     mARK aNDREWS �                                                    
   Senior Application                                                  
    Specialist � West                                                  
      Sussex County                                                    
         Council                                                       
      Durban House,                                                    
   Bognor Regis, West                                                  
   Sussex, PO22 9RE �                                                  
   (+44) 01243 642315                                                  
                                                                       
                                                                       





                                                                           
             Bruce Snyder                                                  
             <[EMAIL PROTECTED]>                                             
                                                                        To 
             01/12/2004 19:16          [EMAIL PROTECTED]              
                                                                        cc 
                                                                           
             Please respond to                                     Subject 
             <[EMAIL PROTECTED]         Re: [castor-user] Binding Help      
                  ab.org>                                                  
                                                                           
                                                                           
                                                                           
                                                                           
                                                                           





[EMAIL PROTECTED] wrote:

> I am new to this and was wondering if anyone could offer me an example of
a
> schema, and binding file I would be most grateful.  What I am wanting to
do
> is generate some source code from a schema, but there are elements that
> have the same name, therefore some warning are Thrown up.

Mark,

There's an example binding file in the source download/CVS available here:

     src/examples/SourceGenerator/bindingInvoice.xml

FWIW, the binding file can address your situation pretty easily. You're
headed down the correct path.

Bruce
--
perl -e 'print
unpack("u30","<0G)[EMAIL PROTECTED]&5R\"F9E<G)E=\$\!F<FEI+F-O;0\`\`");'

The Castor Project
http://www.castor.org/

Apache Geronimo
http://geronimo.apache.org/



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



Attachment: FlareReqComp.xsd
Description: Binary data

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

Reply via email to