使用 Python XSLT API 进行 Web 服务开发
2007-03-29 12:12:01 来源:WEB开发网核心提示: 清单 4. 用于添加服务的 WSDL<?xml version="1.0" encoding="UTF-8"?><definitions name="adder"targetNamespace="htt
清单 4. 用于添加服务的 WSDL
<?xml version="1.0" encoding="UTF-8"?>
<definitions name="adder"
targetNamespace="http://www.topxml.com/"
xmlns:tns="http://www.topxml.com/"
xmlns:xsd="http://www.w3.org/1999/XMLSchema"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<message name="Add">
<part name="A" type="xsd:double" />
<part name="B" type="xsd:double" />
</message>
<message name="AddResponse">
<part name="param" type="xsd:double" />
</message>
<portType name="adder-port-type">
<operation name="Add">
<input message="tns:Add" />
<output message="tns:AddResponse" />
</operation>
</portType>
<binding name="adder-soap-binding" type="tns:adder-port-type"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/">
<soap:binding transport="http://schemas.xmlsoap.org/soap/http"
style="rpc"/>
<operation name="Add">
<soap:operation soapAction="http://tempuri.org/"/>
<input>
<soap:body use="encoded" namespace="http://www.topxml.com/"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</input>
<output>
<soap:body use="encoded" namespace="http://www.topxml.com/"
encodingStyle="http://schemas.xmlsoap.org/soap/encoding/"/>
</output>
</operation>
</binding>
<service name="adder-service">
<port name="adder-port" binding="tns:adder-soap-binding">
<soap:address location="http://127.0.0.1:8888/add"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"/>
</port>
</service>
</definitions>
更多精彩
赞助商链接