Re: complex types again
Marc Logemann <[email protected]> Tue, 2 Dec 2003 17:58:22 +0100
| Newsgroups | gmane.comp.java.enhydra.ksoap |
|---|---|
| Message-ID | <Jb2yLhRKANZNNfVkDmEovidwsBZaWqnqOZb14Ap6eG8@akmail> |
Hi,
> > #1: i dont know what to put into the namespace at method
> addMapping(),
> > i guessed it must be urn:CourseService, is it?
> Looks like this ist the namespace of the request method name. The
> namespace for the content seems to be "urn:GolfCourse"
where do you see urn:GolfCourse in the doc? I only see GolfCourse as a xsi:Type
> > #2: When does the deserialization occur?
> If the debug flag is not set, it should occur while parsing the content
> of the request.
Hmmm, still clueless, but lets see.
>> Hi,
>>
>> even with reading though the maillist archives, i cant complex
>> types getting to work.
>>
>> Here is what i get from my Axis Webservice:
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <soapenv:Envelope
>> xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/"
>> xmlns:xsd="http://www.w3.org/2001/XMLSchema"
>> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
>> <soapenv:Body>
>> <ns1:getGolfCourseResponse
>> soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
>> xmlns:ns1="urn:CourseService">
>> <ns1:getGolfCourseReturn href="#id0"/>
>> </ns1:getGolfCourseResponse>
>> <multiRef id="id0" soapenc:root="0"
>> soapenv:encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"
>> xsi:type="ns2:GolfCourse"
>> xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
>> xmlns:ns2="urn:BeanService">
>> <name xsi:type="xsd:string">Attighof</name>
>> <tee xsi:type="xsd:string">gelb</tee>
>> [.. a lot more attributes ..]
>> </multiRef>
>> </soapenv:Body>
>> </soapenv:Envelope>
>>
>>
>> ---
>>
>> here my client code:
>>
>> SoapObject rpc = new SoapObject("urn:CourseService", "getGolfCourse");
>> rpc.addProperty("string", symbol);
>> HttpTransport httpTransport = new
>> HttpTransport("http://localhost:1234/axis/services/CourseService",
>> "urn:CourseService#getGolfCourse");
>> ClassMap classMap = new ClassMap();
>> classMap.addMapping("urn:CourseService", "GolfCourse", new
>> GolfCourse().getClass());
>> httpTransport.setClassMap(classMap);
>> GolfCourse gc = (GolfCourse)httpTransport.call(rpc);
>>
>> ---
>>
>> my KvmSerializable is correct based on the article published on xml.com
>> by Jeff
>> McHugh. The only thing i made different is that i only defined a subet of
>> the complete struct coming back from my Axis Service in the
>> KvmSerializable, because
>> of the horror work. Will do this later.
>>
>> My Error is a simple ClassCastException on the call. Perhaps you will
>> have some hint for me, besides this i have three questions:
>>
>> #1: i dont know what to put into the namespace at method addMapping(), i
>> guessed it must be urn:CourseService, is it?
>> #2: When does the deserialization occur?
>> #3: why is my response soap document so different from the example at
>> http://webservices.xml.com/pub/a/ws/2003/08/19/ksoap.html?
>>
>> Thanks for help. Hopefully this is only a small problem.
>>
>>
>> ---
>> regards
>> Marc Logemann
>> check http://www.logemann.org
>>
>>
>> _______________________________________________
>> Ksoap mailing list
>> [email protected]
>> http://www.enhydra.org/mailman/listinfo.cgi/ksoap
> _______________________________________________
> Ksoap mailing list
> [email protected]
> http://www.enhydra.org/mailman/listinfo.cgi/ksoap
---
regards
Marc Logemann
check http://www.logemann.org