Saturday, November 10, 2007

WSDL Refresher

Powered by Qumana


<xsd:element> defines the elements, and can include complex types within it. One style/pattern of defining the elements is:


Style1


complex type 1


complex type2


element1 uses complex type1


element 2 uses complex type 2


then inside the wsdl:message the element is referenced using


wsdl:part name="anyname" element=element1


OR one can directly DEFINE the element inside the message as in style2


Style2


<wsdl:message>


element1 uses complex type1


</wsdl:message>



once the message is defined using the xsd types and user defined complex types, the message is used as part of an operation


<wsdl:operation>


<wsdl:input  message= messagename1 >


<wsdl:output  message= messagename2 >


One/group of operations form a porttype


<wsdl:porttype name=    operation=>


A porttype is thus a grop of technology independent interfaces.


However interfaces in the end need to be implemented using technology. A possible way of calling/using the interface is using SOAP (technology)


To take it to this next level, a binding is used.


<wsdl:binding type=portname>


<soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>


<wsdl:operation name=opName>
<wsdl:input>
<soap:body use="literal"/>
</wsdl:input>


and same for o/p


but how will the binding be called? for SOAP its through a URI. This forms the service


<wsdl:service name="srvname">
<wsdl:port name="SOAPbindingname" binding="tns:TravelOneServiceSOAP">
<soap:address location="http://localhost:xxx/URL"/>
</wsdl:port>
</wsdl:service>
</wsdl:definitions>











<wsdl:message>


No comments: