Anne
On 1/26/06, Tomáš Procházka <[EMAIL PROTECTED]> wrote:
Hi.
D> Axis2 can not handle HashMap yet , I mean default Aixs2 MessageRecivers ,
D> but you can write your own message reciver to handle this case.
I tested it only Axis 1.3
Axis 1.3 support HashMap?
Axis 2.0 I never try yet.
-------------------------- Original message --------------------------
From: Deepal Jayasinghe <[EMAIL PROTECTED]>
Subject: HashMap return Long value
Date: Thursday, January 26, 2006, 12:16:40 PM
Attachments: <none>
msgid:[EMAIL PROTECTED]
D> Thanks,
D> Deepal
D> ................................................................
D> ~Future is Open~
D> ----- Original Message -----
D> From: "Tomáš Procházka" < [EMAIL PROTECTED]>
D> To: <[email protected]>; "Tomáš Procházka" <[EMAIL PROTECTED]>
D> Sent: Thursday, January 26, 2006 1:34 PM
D> Subject: Re: HashMap return Long value
D> Hi.
D> No body has this problem?
D> Exist another way to send Map via Axis?
D> And what About Axis2? It's in usable version?
D> -------------------------- Original message --------------------------
D> From: Tomáš Procházka < [EMAIL PROTECTED]>
D> Subject: HashMap return Long value
D> Date: Wednesday, January 25, 2006, 3:00:57 PM
D> Attachments: <none>
D> msgid: [EMAIL PROTECTED]
TP>> Hi.
TP>> I Have problem with HasMap in Axis.
TP>> Can you help me somebody, please.
TP>> I write this method on the server side:
TP>> public HashMap getMap() {
TP>> HashMap map = new HashMap();
TP>> map.put("NAME","Tomas");
TP>> map.put("SEX","male");
TP>> return map;
TP>> }
TP>> When invoke it on the client side get this error:
TP>> java.lang.ClassCastException: java.lang.Long
TP>> at
TP>>
D> cz.atomsoft.bazartip.ws.SynchronizationSoapBindingStub.getMap(SynchronizationSoapBindingStub.java:206)
TP>> WS return Long number. Why?
TP>> When I use SOPA monitor, get this as response:
TP>> <?xml version="1.0" encoding="UTF-8"?>
TP>> <soapenv:Envelope
D> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/ "
TP>> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
TP>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance ">
TP>> <soapenv:Body>
TP>> <ns1:getMapResponse
TP>> soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/ "
D> xmlns:ns1="urn:ws.bazartip.atomsoft.cz">
TP>> <getMapReturn href="">TP>> </ns1:getMapResponse>
TP>> <multiRef id="id0" soapenc:root="0"
TP>> soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
D> xsi:type="ns2:Map"
TP>> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
TP>> xmlns:ns2=" http://xml.apache.org/xml-soap">
TP>> <item>
TP>> <key xsi:type="soapenc:string">SEX</key>
TP>> <value xsi:type="soapenc:string">male</value>
TP>> </item>
TP>> <item>
TP>> <key xsi:type="soapenc:string">NAME</key>
TP>> <value xsi:type="soapenc:string">Tomas</value>
TP>> </item>
TP>> </multiRef>
TP>> </soapenv:Body>
TP>> </soapenv:Envelope>
TP>> I tested it with Apache Axis 1.3 a and 1.4 CVS on the client and also
D> on the server side.
D> ----------------------- End of original message ----------------------
----------------------- End of original message ----------------------
--
Tomas Prochazka
