Hi,
thanks for looking at this.
I just tested it with nightly build and client request looks right now.
But the values in server response are truncated.
<soapenv:Envelope
xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/">
<soapenv:Body>
<ns:testHashtable2Response
xmlns:ns="http://coaching.de">
<ns:return
xmlns:ax21="http://errorhandling.base.de/xsd"
xmlns:ax22="http://coaching.de/xsd"
xmlns:ax23="http://vo.coaching.de/xsd"
xmlns:ax24="http://util.java/xsd"
xmlns:ax26="http://io.java/xsd"
type="de.coaching.Hashtable">
<ax22:keyValuePairs
type="de.coaching.KeyValuePair">
<ax22:key>TestStringKe</ax22:key>
<ax22:value>TestStringVa</ax22:value>
</ax22:keyValuePairs>
<ax22:keyValuePairs
type="de.coaching.KeyValuePair">
<ax22:key />
<ax22:value />
</ax22:keyValuePairs>
<ax22:keyValuePairs
type="de.coaching.KeyValuePair">
<ax22:key>StringKayForinte</ax22:key>
<ax22:value />
</ax22:keyValuePairs>
<ax22:keyValuePairs
type="de.coaching.KeyValuePair">
<ax22:key />
<ax22:value>StringValueForIntege</ax22:value>
</ax22:keyValuePairs>
<ax22:keyValuePairs
type="de.coaching.KeyValuePair">
<ax22:key />
<ax22:value>StringValueForIntege</ax22:value>
</ax22:keyValuePairs>
</ns:return>
</ns:testHashtable2Response>
</soapenv:Body>
Also on the server side i get javax.activation.DataHandler in my KeyValuePair's
instead of the real objects. Ok, this is not really surprising because the
complex type only defines anytype and the real type is not transported in soap
request.
Why isn't the type transported like for integers before the fix?
Like this <ax21:value type="java.lang.Integer"/>.
Regards
-------- Original-Nachricht --------
> Datum: Tue, 12 Feb 2008 18:13:12 +0530
> Von: Deepal jayasinghe <[EMAIL PROTECTED]>
> An: [email protected]
> Betreff: Re: [axis2] axis2 1.3 custom complex type problem
> Hi ,
> When I debug Axis2 with your scenario I found an issue in Axis2 , so I
> have fixed that and committed the change , you may try with nightly
> builds or wait for Axis2 1.4
>
> Thanks
> Deepal
> > Hi all,
> >
> > i have define a new class that has an member which is an array of
> > KeyValuePair. Where KeyValuePair has two member of type object (key and
> value).
> >
> > WSDL is genereated as follows:
> >
> > <xs:complexType name="Hashtable">
> > <xs:sequence>
> > <xs:element maxOccurs="unbounded" minOccurs="0"
> name="keyValuePairs" nillable="true" type="ns2:KeyValuePair"/>
> > </xs:sequence>
> > </xs:complexType>
> > <xs:complexType name="KeyValuePair">
> > <xs:sequence>
> > <xs:element minOccurs="0" name="key" nillable="true"
> type="xs:anyType"/>
> > <xs:element minOccurs="0" name="value" nillable="true"
> type="xs:anyType"/>
> > </xs:sequence>
> > </xs:complexType>
> >
> > Service class method:
> >
> > public Hashtable testHashtable2() {
> > KeyValuePair[] keyValuePairs = new KeyValuePair[] {
> > new KeyValuePair("TestStringKey", "TestStringValue"),
> > new KeyValuePair(new Integer(1), new Integer(2)),
> > new KeyValuePair("StringKayForinteger", new Integer(2)),
> > new KeyValuePair(new Integer(1), "StringValueForInteger"),
> > new KeyValuePair(new Integer(1), new
> String("StringValueForInteger"))
> > };
> >
> > return new Hashtable(keyValuePairs);
> > }
> >
> > and SOAP Response:
> >
> > <soapenv:Envelope
> xmlns:soapenv="http://www.w3.org/2003/05/soap-envelope">
> > <soapenv:Body>
> > <ns:testHashtable2Response xmlns:ns="http://coaching.de">
> > <ns:return type="de.coaching.Hashtable"
> xmlns:ax22="http://vo.coaching.de/xsd" xmlns:ax23="http://io.java/xsd"
> xmlns:ax21="http://coaching.de/xsd">
> > <ax21:keyValuePairs type="de.coaching.KeyValuePair">
> > <ax21:key>TestStringKey</ax21:key>
> > <ax21:value>TestStringValue</ax21:value>
> > </ax21:keyValuePairs>
> > <ax21:keyValuePairs type="de.coaching.KeyValuePair">
> > <ax21:key type="java.lang.Integer"/>
> > <ax21:value type="java.lang.Integer"/>
> > </ax21:keyValuePairs>
> > <ax21:keyValuePairs type="de.coaching.KeyValuePair">
> > <ax21:key>StringKayForinteger</ax21:key>
> > <ax21:value type="java.lang.Integer"/>
> > </ax21:keyValuePairs>
> > <ax21:keyValuePairs type="de.coaching.KeyValuePair">
> > <ax21:key type="java.lang.Integer"/>
> > <ax21:value>StringValueForInteger</ax21:value>
> > </ax21:keyValuePairs>
> > <ax21:keyValuePairs type="de.coaching.KeyValuePair">
> > <ax21:key type="java.lang.Integer"/>
> > <ax21:value>StringValueForInteger</ax21:value>
> > </ax21:keyValuePairs>
> > </ns:return>
> > </ns:testHashtable2Response>
> > </soapenv:Body>
> > </soapenv:Envelope>
> >
> > So for String there are the values but not type and for Integer there
> are no
> > values but the type. Why is this?
> >
> > Regards
> >
>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
--
Psst! Geheimtipp: Online Games kostenlos spielen bei den GMX Free Games!
http://games.entertainment.web.de/de/entertainment/games/free
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]