Understanding the .NET Framework Web Service Client


By using the HTTP protocol and a SOAP message, a Web service client can send requests and interpret responses from a Web server. Figure 9.1 depicts the lifetime of a Web method call from a client to the Web server.

Figure 9.1. Lifetime of a Web method call on a Web service.

graphics/09fig01.gif

The following list describes nine steps in the lifetime of a Web method call.

  1. The client application creates an instance of the proxy class. The proxy is a class that manages the communication between your application and the Web service. The client application calls a method on the proxy class that in turn invokes the Web service.

  2. The proxy, using the client-side Web service architecture, serializes the XML Web service request and packages it in a SOAP message.

  3. This SOAP message is then sent to the Web server over HTTP.

  4. The server-side Web service architecture receives and deserializes the SOAP message.

  5. Using the SOAP message, the class representing the Web service is created. Next, the arguments to the Web method are created from the SOAP message. Finally, the Web method is invoked with the specified arguments.

  6. The server-side Web service architecture packages the out parameters and the return value into a SOAP message.

  7. The SOAP message is sent back to the client over HTTP.

  8. The client-side Web service architecture receives the SOAP message and deserializes the out parameters and return value. The values are returned to the proxy class.

  9. The proxy class returns the out parameters and return value to the client application.



Microsoft.NET Compact Framework Kick Start
Microsoft .NET Compact Framework Kick Start
ISBN: 0672325705
EAN: 2147483647
Year: 2003
Pages: 206

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net