Hi,

I get the following error when I try to unmarshall from an
xml file. I have checked the archives but could not find any
clues. Any thing fishy in these files?

Thanx in advance.

Brahma.

----
org.xml.sax.SAXException: unable to add 'DropDownOuterMost'
to <castor-container> due to the following exception:
>>>--- Begin Exception ---<<<
java.lang.IllegalArgumentException: argument type mismatch
        at java.lang.reflect.Method.invoke(Native Method)
        at
org.exolab.castor.mapping.loader.FieldHandlerImpl.setValue(FieldHandlerImpl.java:574)
        at
org.exolab.castor.xml.UnmarshalHandler.endElement(UnmarshalHandler.java:803)
        at
org.apache.xerces.parsers.SAXParser.endElement(SAXParser.java:1392)
        at
org.apache.xerces.validators.common.XMLValidator.callEndElement(XMLValidator.java:1436)
        at
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XMLDocumentScanner.java:1205)
        at
org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.java:381)
        at
org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1035)
        at
org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:555)
        at
SGN_Combo_Controller.SCV_Get_Combo_Values(SGN_Combo_Controller.java:107)
        at
SGN_Combo_Controller.main(SGN_Combo_Controller.java:183)
>>>---- End Exception ----<<<

        at
org.exolab.castor.xml.UnmarshalHandler.endElement(UnmarshalHandler.java:836)
        at
org.apache.xerces.parsers.SAXParser.endElement(SAXParser.java:1392)
        at
org.apache.xerces.validators.common.XMLValidator.callEndElement(XMLValidator.java:1436)
        at
org.apache.xerces.framework.XMLDocumentScanner$ContentDispatcher.dispatch(XMLDocumentScanner.java:1205)
        at
org.apache.xerces.framework.XMLDocumentScanner.parseSome(XMLDocumentScanner.java:381)
        at
org.apache.xerces.framework.XMLParser.parse(XMLParser.java:1035)
        at
org.exolab.castor.xml.Unmarshaller.unmarshal(Unmarshaller.java:555)
        at
SGN_Combo_Controller.SCV_Get_Combo_Values(SGN_Combo_Controller.java:107)
        at
SGN_Combo_Controller.main(SGN_Combo_Controller.java:183)
---

I have checked the mapping file and data xml file and both
seem to fine.

Mapping file.
-------------
<?xml version="1.0" encoding="UTF-8"?>
<mapping>
        <class
name="com.eaf.wealthmanager.CommonUtilities.CastorContainer"
auto-complete="false">
                <description>Default mapping for class
CastorContainer</description>
                <map-to xml="castor-container"/>
                <field name="objects1"
type="com.eaf.wealthmanager.Domains.DropDownOuterMost"
collection="collection" required="false">
                        <bind-xml name="DropDownOuterMost"/>
                </field>
        </class>
        <class
name="com.eaf.wealthmanager.Domains.DropDownOuterMost">
                <description> </description>
                <!--  DropDownOuterMost  DropDownOutClass  -->
                <field name="DropDownList"
type="com.eaf.wealthmanager.Domains.DropDownOutClass"
collection="collection">
                        <bind-xml name="DropDownList" node="element"/>
                </field>
                <field name="specFlag" type="string"
handler="org.exolab.castor.mapping.BitSetFieldHandler"
required="false" direct="false" transient="false"
get-method="GetspecFlag" set-method="SetspecFlag">
                        <bind-xml name="spec-flag" node="element"
reference="false"/>
                </field>
        </class>
        <class
name="com.eaf.wealthmanager.Domains.DropDownOutClass">
                <description> </description>
                <field name="DropDownCode" type="string"
handler="org.exolab.castor.mapping.StringBufferFieldHandler">
                        <bind-xml name="DropDownCode" node="element"/>
                </field>
                <field name="DropDownDescription" type="string"
handler="org.exolab.castor.mapping.StringBufferFieldHandler">
                        <bind-xml name="DropDownDescription" node="element"/>
                </field>
                <!--  DropDownOuterMost  DropDownOutClass  -->
                <!--
                <field name="DepDropDownList"
type="com.eaf.wealthmanager.Domains.DropDownOutClass"
collection="collection">
                        <bind-xml name="DepDropDownList" node="element"/>
                </field>
                -->
                <field name="specFlag" type="string"
handler="org.exolab.castor.mapping.BitSetFieldHandler"
required="false" direct="false" transient="false"
get-method="GetspecFlag" set-method="SetspecFlag">
                        <bind-xml name="spec-flag" node="element"
reference="false"/>
                </field>
        </class>
</mapping>
----------

Data file
----------
<?xml version="1.0" encoding="UTF-8"?>
<castor-container>
        <DropDownOuterMost>
                <DropDownList>
                        <DropDownCode>1</DropDownCode>
                        <DropDownDescription>Asset</DropDownDescription>
                        <spec-flag>{0,1}</spec-flag>
                </DropDownList>
        </DropDownOuterMost>
</castor-container>
----------

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

Reply via email to