Andy,

It sounds like the *Descriptor files have not been compiled, can you
verify that you compiled all classes, keeping in mind that the java
object model that is generated is not "java dependent" on the generated
descriptors, so compiling the class for your top-level element TX, will
only compile TX's dependencies and the descriptor files won't be
compiled.

If you compiled all files including descriptors, and it's still not
working let me know.

Thanks,

--Keith


Andy Scherzinger wrote:
> 
> Hi,
> 
> I have a problem, I generate java files using a binding.xml because of naming 
> collisions, and for example the files I attached inline.  These java clases are 
> generated and compiled without any exception or problem, but if I try to unmarshall 
> a sample XML it's failed.
> 
> Any suggestions or workaround?
> 
> Is is a problem with type="xsd:IDREF" ?
> 
> Thanks
> 
> regards,
> ---Andy
> 
> PrintStackTrace:------------------------------------------------------------------
> 
> #startElement: TX
> #characters:
> 
> #startElement: AuthRequest
> org.xml.sax.SAXException: unable to find FieldDescriptor for 'AuthRequest' in 
> ClassDescriptor of TX
>         at 
> org.exolab.castor.xml.UnmarshalHandler.startElement(UnmarshalHandler.java:1791)
>         at 
> org.exolab.castor.xml.UnmarshalHandler.startElement(UnmarshalHandler.java:1292)
>         at 
> org.apache.xerces.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:446)
>         at 
> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:823)
>         at 
> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(XMLDocumentFragmentScannerImpl.java:1543)
>         at 
> org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:348)
>         at 
> org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:539)
>         at 
> org.apache.xerces.parsers.DTDConfiguration.parse(DTDConfiguration.java:595)
>         at org.apache.xerces.parsers.XMLParser.parse(XMLParser.java:152)
>         at 
> org.apache.xerces.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1125)
>         at org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:605)
>         at org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:513)
>         at org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:691)
>         at txlife.E_TX_E.unmarshal(E_TX_E.java:273)
>         at main_test.<init>(main_test.java:45)
>         at main_test.main(main_test.java:68)
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>         at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
>         at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
>         at java.lang.reflect.Method.invoke(Method.java:324)
>         at com.intellij.rt.execution.application.AppMain.main(Unknown Source)
> 
> PrintStackTraceEnd:------------------------------------------------------------------
> 
> XML:--------------------------------------------------------------------------------
> 
> <?xml version="1.0" encoding="UTF-8"?>
> <TX xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"; 
> xsi:noNamespaceSchemaLocation="C:\dummy.xsd" Version="String">
>         <AuthRequest>
>                 <LoginName>String</LoginName>
>                 <Pwd>
>                         <CryptType>String</CryptType>
>                         <Pswd>String</Pswd>
>                 </Pwd>
>                 <Domain>String</Domain>
>                 <Date>1967-08-13</Date>
>                 <Time>1967-08-13</Time>
>         </AuthRequest>
>         <Request id="ID000006" PrimaryObjectID="ID000006">
>                 <Trans>String</Trans>
>         </Request>
> </TX>
> 
> XMLEnd:---------------------------------------------------------------------------
> 
> XSD:--------------------------------------------------------------------------------
> 
> <?xml version="1.0" encoding="utf-8" standalone="yes"?>
> <xsd:schema xmlns:xsd="http://www.w3.org/2001/XMLSchema"; 
> elementFormDefault="unqualified" attributeFormDefault="unqualified" version="1.45">
>         <xsd:element name="TX">
>                 <xsd:complexType>
>                         <xsd:choice>
>                                 <xsd:sequence>
>                                         <xsd:element ref="AuthRequest" 
> minOccurs="0"/>
>                                         <xsd:element ref="Request" minOccurs="0" 
> maxOccurs="unbounded"/>
>                                 </xsd:sequence>
>                         </xsd:choice>
>                         <xsd:attribute name="Version" type="xsd:string"/>
>                 </xsd:complexType>
>         </xsd:element>
>         <xsd:element name="Request">
>                 <xsd:complexType>
>                         <xsd:sequence>
>                                 <xsd:element ref="Trans"/>
>                         </xsd:sequence>
>                         <xsd:attribute name="id" type="xsd:ID"/>
>                         <xsd:attribute name="PrimaryObjectID" type="xsd:IDREF"/>
>                 </xsd:complexType>
>         </xsd:element>
>         <xsd:element name="AuthRequest">
>                 <xsd:complexType>
>                         <xsd:sequence>
>                                 <xsd:choice>
>                                         <xsd:sequence>
>                                                 <xsd:element ref="LoginName" 
> minOccurs="0"/>
>                                                 <xsd:element ref="Pwd" 
> minOccurs="0"/>
>                                         </xsd:sequence>
>                                         <xsd:sequence>
>                                                 <xsd:element ref="SessionKey" 
> minOccurs="0"/>
>                                         </xsd:sequence>
>                                 </xsd:choice>
>                                 <xsd:element ref="Domain" minOccurs="0"/>
>                                 <xsd:element ref="Date" minOccurs="0"/>
>                                 <xsd:element ref="Time" minOccurs="0"/>
>                         </xsd:sequence>
>                 </xsd:complexType>
>         </xsd:element>
>         <xsd:element name="Pwd">
>                 <xsd:complexType>
>                         <xsd:sequence>
>                                 <xsd:element ref="CryptType" minOccurs="0"/>
>                                 <xsd:choice>
>                                         <xsd:element ref="Pswd" minOccurs="0"/>
>                                         <xsd:element ref="CryptPwd" minOccurs="0"/>
>                                 </xsd:choice>
>                         </xsd:sequence>
>                 </xsd:complexType>
>         </xsd:element>
>         <!-- ********** PROPERTIES ********** -->
>         <xsd:element name="CryptPwd" type="xsd:string"/>
>         <xsd:element name="CryptType" type="xsd:string"/>
>         <xsd:element name="Pswd" type="xsd:string"/>
>         <xsd:element name="Trans" type="xsd:string"/>
>         <xsd:element name="Date" type="xsd:date"/>
>         <xsd:element name="Domain" type="xsd:string"/>
>         <xsd:element name="LoginName" type="xsd:string"/>
>         <xsd:element name="SessionKey" type="xsd:string"/>
>         <xsd:element name="Time" type="xsd:date"/>
> </xsd:schema>
> 
> XSDEnd:---------------------------------------------------------------------------
> 
> _______________________________________________________________________
> ... and the winner is... WEB.DE FreeMail! - Deutschlands beste E-Mail
> ist zum 39. Mal Testsieger (PC Praxis 03/04) http://f.web.de/?mc=021191
> 
> -----------------------------------------------------------
> If you wish to unsubscribe from this mailing, send mail to
> [EMAIL PROTECTED] with a subject of:
>         unsubscribe castor-dev

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

Reply via email to