100 lines
3.4 KiB
HTML
100 lines
3.4 KiB
HTML
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
|
|
<html>
|
|
<head>
|
|
<META http-equiv="Content-Type" content="text/html; charset=utf-8">
|
|
<LINK rel="stylesheet" type="text/css" href="../../../rzahg/ic.css">
|
|
|
|
<title>WSDL architecture</title>
|
|
</head>
|
|
|
|
<BODY>
|
|
<!-- Java sync-link -->
|
|
<SCRIPT LANGUAGE="Javascript" SRC="../../../rzahg/synch.js" TYPE="text/javascript"></SCRIPT>
|
|
|
|
<h2><a name="wswsdlelements"></a>WSDL architecture</h2>
|
|
|
|
<p>Web Services Description Language (WSDL) files are written in eXtensible
|
|
Markup Language (XML). To learn more about XML, see <a href="wsrefs.htm">Web services resources</a>.</p>
|
|
|
|
<p><img src="rzaiz626.gif" alt="Anatomy of a WSDL file" width="467" height="289"></p>
|
|
|
|
<p>A WSDL contains the following parts:</p>
|
|
<ul>
|
|
<li><p><strong>Web service interface definition</strong><br>This is where the elements are
|
|
contained, as well as the namespaces.</p></li>
|
|
<li><p><strong>Web service implementation</strong><br>This is where you find the definition of the service and ports. </p></li>
|
|
</ul>
|
|
|
|
<p>A WSDL file describes a Web service with the following elements:</p>
|
|
|
|
<p><strong>portType</strong></p>
|
|
|
|
<p>The description of the operations and their
|
|
associated messages. PortTypes define abstract operations.</p>
|
|
|
|
<pre><portType name="EightBall">
|
|
<operation name="getAnswer">
|
|
<input message="ebs:IngetAnswerRequest"/>
|
|
<output message="ebs:OutgetAnswerResponse"/>
|
|
</operation>
|
|
</portType>
|
|
</pre>
|
|
|
|
<p><strong>message</strong></p>
|
|
<p>The description of parameters (input and
|
|
output) and return values.</p>
|
|
|
|
<pre><message name="IngetAnswerRequest">
|
|
<part name="meth1_inType" type="ebs:questionType"/>
|
|
</message>
|
|
<message name="OutgetAnswerResponse">
|
|
<part name="meth1_outType" type="ebs:answerType"/>
|
|
</message>
|
|
</pre>
|
|
|
|
<p><strong>types</strong></p>
|
|
<p>The schema for describing XML complex types
|
|
used in the messages.</p>
|
|
<pre><types>
|
|
<xsd:schema targetNamespace="...">
|
|
<xsd:complexType name="questionType">
|
|
<xsd:element name="question" type="string"/>
|
|
</xsd:complexType>
|
|
<xsd:complexType name="answerType">
|
|
...
|
|
</types>
|
|
</pre>
|
|
|
|
<p><strong>binding</strong></p>
|
|
<p>Bindings describe the protocol used to access
|
|
a service, as well as the data formats for the messages defined by a particular
|
|
portType.</p>
|
|
<pre><binding name="EightBallBinding" type="ebs:EightBall">
|
|
<soap:binding style="rpc" transport="schemas.xmlsoap.org/soap/http">
|
|
<operation name="ebs:getAnswer">
|
|
<soap:operation soapAction="urn:EightBall"/>
|
|
<input>
|
|
<soap:body namespace="urn:EightBall" ... />
|
|
...
|
|
</pre>
|
|
|
|
<p>The remaining parts, services and ports, indicate where you can find the
|
|
WSDL.</p>
|
|
|
|
<p><strong>Service</strong></p>
|
|
<p>Contains the Web service name and a list of
|
|
the ports.</p>
|
|
|
|
<p><strong>Ports</strong></p>
|
|
<p>Contains the location of the Web service and
|
|
the binding to used to access the service.</p>
|
|
|
|
<pre><service name="EightBall">
|
|
<port binding="ebs:EightBallBinding" name="EightBallPort">
|
|
<soap:address location="localhost:8080/axis/EightBall"/>
|
|
</port>
|
|
</service>
|
|
</pre>
|
|
</body>
|
|
</html>
|