ASP.NET and Web Services Part 2 - The Web Service WSDL file
(Page 5 of 8 )
Listing 10 displays the web service WSDL file that strong-types the web service.
Listing 10 IFCEBrokerageFirm WSDL file
<?xml version="1.0"
encoding="utf-8" ? >
<definitions
xmlns:http="http://
schemas.xmlsoap.org/wsdl/http/"
xmlns:soap="http://
schemas.xmlsoap.org/wsdl/soap/"
xmlns:s=
"http://www.w3.org/2001/XMLSchema"
xmlns:s0="http://tempuri.org/"
xmlns:soapenc="http://schemas.xmlsoap.org/soap/encoding/"
xmlns:tm="http://microsoft.com/wsdl/mime/textMatching/"
xmlns:mime=http://schemas.xmlsoap.org/wsdl/mime/
targetNamespace="http://tempuri.org/"
xmlns=
"http://schemas.xmlsoap.org/wsdl/">
<types>
<s:schema
elementFormDefault="qualified"
targetNamespace="http://tempuri.org/">
<s:element
name="StockQuote">
<s:complexType>
<s:sequence>
<s:element minOccurs="0" maxOccurs="1" name="symbol" type="s:string"
/>
</s:sequence>
</s:complexType>
</s:element>
<s:element
name="StockQuoteResponse">
<s:complexType>
<s:sequence>
<s:element minOccurs="1" maxOccurs="1"
name="StockQuoteResult"
type="s:double" />
</s:sequence>
</s:complexType>
</s:element>
</s:schema>
</types>
<message
name="StockQuoteSoapIn">
<part name="parameters"
element="s0:StockQuote" />
</message>
<message
name="StockQuoteSoapOut">
<part name="parameters"
element="s0:StockQuoteResponse" />
</message>
<portType
name="SecuritiesExchangeSoap">
<operation
name="StockQuote">
<input message="s0:StockQuoteSoapIn"
/>
<output message="s0:StockQuoteSoapOut" />
</operation>
</portType>
<binding
name="SecuritiesExchangeSoap" type="s0:SecuritiesExchangeSoap">
<soap:binding transport="http://
schemas.xmlsoap.org/soap/http"
style="document" />
<operation name="StockQuote">
<soap:operation soapAction="http://
tempuri.org/StockQuote"
style="document" />
<input>
<soap:body use="literal"
/>
</input>
<output>
<soap:body
use="literal" />
</output>
</operation>
</binding>
<service
name="SecuritiesExchange">
<documentation>This demonstrates
how to use the Description
attribute</documentation>
<port
name="SecuritiesExchangeSoap" binding="s0:SecuritiesExchangeSoap">
<soap:address
location="http://
localhost/IFCEBrokerage/IFCEBrokerageFirm.asmx"
/>
</port>
</service>
</definitions>
TheWSDL file has several interesting characteristics, described shortly in some detail.
Remember: This is part one of chapter 7 .NET & J2EE Interoperability, by Dwight Peltzer (McGraw-Hill/Osborne, ISBN 0-07-223054-1, 2004). If you like what you see, feel free to click on the following link to get your own copy! Buy this book now.
|
Next: The Standard WSDL File Form >>
More ASP.NET Articles
More By McGraw-Hill/Osborne