Abstract WSDL Documents

An abstract WSDL document contains the following elements: Defniitions, Types, Messages, Parts, Operations and Port types.

  • Definitions  
    is the root element. It enumerates the namespaces referenced in the WSDL document and contains all other elements.
  • Types
     describe the data types of the objects that may be passed in messages.
  • Messages
     consist of one or more logical parts. Each part is associated with a type from a type system using a message-typing attribute.
  • Parts
     a mechanism for describing the logical abstract content of a message.
  • Operations
     are composed of sequences of messages. The direction of the messages (input or output) is from the perspective of the service provider.
  • Port types
     (also referred to as interfaces) are collections of operations.

The following WSDL document fragment contains the abstract WSDL elements for a stock quote service.

<definitions name="StockQuote"
    targetNamespace="http://ns.tibco.com/StockQuote"
          xmlns:tns="http://ns.tibco.com/StockQuote"
          xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
          xmlns:xs="http://www.w3.org/2001/XMLSchema"
          xmlns="http://schemas.xmlsoap.org/wsdl/">
    <types>
        <xs:schema         targetNamespace="http://ns.tibco.com/StockQuote/">
           <xs:element name="QuoteRequest" type="xs:string"/>
           <xs:element name="QuoteResponse" type="xs:float"/>
        </xs:schema>
    </types>
    <message name="QuoteInput">
        <part name="symbol" element="tns:QuoteRequest"/>
    </message>
    <message name="QuoteOutput">
        <part name="quote" element="tns:QuoteResponse"/>
    </message>
    <portType name="StockQuotePortType">
        <operation name="getQuote">
           <input message="tns:QuoteInput"/>
           <output message="tns:QuoteOutput"/>
        </operation>
    </portType>
    ...
</definitions>