Re: How does the client of a webservice figure out a complex type
- From: Marvin Smit <marvin.smit@xxxxxxxxx>
- Date: Sat, 10 Sep 2005 14:04:19 +0200
Hi,
try tracing what goes over the wire when you do a call through the
proxy. Take notice of the "return value" on the wire havnig an
attribute with a hint for the client side proxy this is a DataSet.
Hope this helps,
Marvin Smit.
On Fri, 9 Sep 2005 16:23:15 -0700, "Nalaka" <nalaka12@xxxxxxxxxxxxx>
wrote:
>Hi,
>Sorry to be bugging again on the same issue.
>
>if the wsdl does not contain any reference (to DataSet), how does the clinet
>code generator know, that this schema is a DataSet?
>Even before I call the webservice (at design time), client code (proxy) that
>was generated for me by .Net, knew that the return data type is DataSet.
>
>hmmm... or may be it did not???..... just let me assign the return to any
>type (an compile ok)... and then (if I am wrong) at runtime generate an
>error?
>
>I am not sure if I explained my confusion properly....
>
>,
>Nalaka
>
>
>
>
>"Steven Cheng[MSFT]" <stcheng@xxxxxxxxxxxxxxxxxxxx> wrote in message
>news:u$szfIPtFHA.1468@xxxxxxxxxxxxxxxxxxxxxxxx
>> Hi Nalaka,
>>
>> As for how webservice client figure out a complex type, it all depends on
>> the webservice client's programming platform( .NET , java .....). As for
>> webservice standard, the WSDL is the only service contract and provide
>> type
>> definition, the webservice just generate clientside class according to the
>> schemas within the WSDL. As for complex xml types, the certain client will
>> generate the appropriate proxy classes for them, for example as the
>> DataSet
>> you mentioned, the webservice expose it as a schema type since it's XML
>> standard and not platform specific, then the webservice clientside can
>> generate proper client proxy class to represent it. For .NET, the
>> clientside VS.NET(or wsdl.exe) will use DataSet class to represent it, in
>> JAVA, maybe some other class (could just be a XmlDocument class ...).
>>
>> Thanks,
>>
>> Steven Cheng
>> Microsoft Online Support
>>
>> Get Secure! www.microsoft.com/security
>> (This posting is provided "AS IS", with no warranties, and confers no
>> rights.)
>>
>>
>>
>> --------------------
>> From: "Nalaka" <nalaka12@xxxxxxxxxxxxx>
>> References: <#jXSMpItFHA.3040@xxxxxxxxxxxxxxxxxxxx>
>> <icn0i15vmkio7e4ivkpptk2qdbbk5j860n@xxxxxxx>
>> Subject: Re: How does the client of a webservice figure out a complex type
>> Date: Thu, 8 Sep 2005 13:19:04 -0700
>> Lines: 57
>> X-Priority: 3
>> X-MSMail-Priority: Normal
>> X-Newsreader: Microsoft Outlook Express 6.00.2900.2180
>> X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180
>> X-RFC2646: Format=Flowed; Original
>> Message-ID: <OL#pQKLtFHA.3000@xxxxxxxxxxxxxxxxxxxx>
>> Newsgroups: microsoft.public.dotnet.framework.webservices
>> NNTP-Posting-Host: m181-9.bctransit.bc.ca 199.60.181.9
>> Path:
>> TK2MSFTNGXA02.phx.gbl!TK2MSFTNGXA01.phx.gbl!TK2MSFTNGP08.phx.gbl!TK2MSFTNGP1
>> 2.phx.gbl
>> Xref: TK2MSFTNGXA02.phx.gbl
>> microsoft.public.dotnet.framework.webservices:11995
>> X-Tomcat-NG: microsoft.public.dotnet.framework.webservices
>>
>> Thanks Marvin.....
>>
>> Does that mean... to create the client code...
>> Net not only gets the wsdl... it also invokes the webservice itself, to
>> get
>> a instance, to look for .Net speific hints.
>>
>>
>> ,
>> Nalaka
>>
>>
>>
>> "Marvin Smit" <marvin.smit@xxxxxxxxx> wrote in message
>> news:icn0i15vmkio7e4ivkpptk2qdbbk5j860n@xxxxxxxxxx
>>> Hi,
>>>
>>> The trick WebServices in .Net use is "send a hint in the XML instance
>>> document".
>>>
>>> When a DataSet is detected in the WebService generation part an
>>> additional attribute with a 'hint for .Net only' is send allong.
>>>
>>> This allows the (.Net) de-serializer to create the .Net native
>>> 'DataSet' type and populate it.
>>>
>>> I.o.w. It's the toolkit you are using which is able to do this for
>>> you, it has NOTHING to do with the official specs for WebServices.
>>>
>>> Hope this helps,
>>>
>>> Marvin Smit.
>>>
>>> On Thu, 8 Sep 2005 08:30:52 -0700, "Nalaka" <nalaka12@xxxxxxxxxxxxx>
>>> wrote:
>>>
>>>>Hi,
>>>>
>>>>I created a sinple web service that returns a dataSet.
>>>>
>>>>Then I created a client program that uses this web service (that returns
>>>>the
>>>>Dataset).
>>>>
>>>>My question is, how did the client figure out to create a "DataSet" as
>>>>the
>>>>return type from the webservice?
>>>>
>>>>I looked in the wsdl.... there is no reference to DataSet, it just says
>>>>the
>>>>type is "Schema".
>>>>
>>>>
>>>>Thanks
>>>>Nalaka
>>>>
>>>
>>
>>
>>
>
.
- Follow-Ups:
- Re: How does the client of a webservice figure out a complex type
- From: Steven Cheng[MSFT]
- Re: How does the client of a webservice figure out a complex type
- References:
- How does the client of a webservice figure out a complex type
- From: Nalaka
- Re: How does the client of a webservice figure out a complex type
- From: Marvin Smit
- Re: How does the client of a webservice figure out a complex type
- From: Nalaka
- Re: How does the client of a webservice figure out a complex type
- From: Steven Cheng[MSFT]
- Re: How does the client of a webservice figure out a complex type
- From: Nalaka
- How does the client of a webservice figure out a complex type
- Prev by Date: Re: How does the client of a webservice figure out a complex type
- Next by Date: Re: Web service proxy calling a client-side method
- Previous by thread: Re: How does the client of a webservice figure out a complex type
- Next by thread: Re: How does the client of a webservice figure out a complex type
- Index(es):
Relevant Pages
|
Loading