<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type='text/xsl' href='xmlspec.xsl'?>
<!DOCTYPE spec PUBLIC "-//W3C//DTD Specification V2.1//EN" "xmlspec.dtd"[
<!ENTITY % entities SYSTEM "entitieswd.dtd" >
<!ENTITY wgmb SYSTEM "http://www.w3.org/2000/xp/Group/wgmb.txt" >
<!ENTITY prevwgmb SYSTEM "http://www.w3.org/2000/xp/Group/prevwgmb.txt" >
%entities;
<!ENTITY status "editors' copy ">
]>
<spec w3c-doctype="per" role="edcopy">
  <header>
    <title>&name-part2;</title>
    <w3c-designation>&w3c-designation-part2;</w3c-designation>
    <w3c-doctype>&status;</w3c-doctype>
    <pubdate>
      <day><!-- PUBONLY &draft.day; --> $Date: 2007/03/07 14:20:42 $</day>
      <month><!-- PUBONLY &draft.month; --></month>
      <year><!-- PUBONLY &draft.year; --></year>
    </pubdate>
<!--    <publoc><loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest" href="&dated-part2;/">&dated-part2;/</loc></publoc> -->
    <prevlocs><loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest" href="http://www.w3.org/TR/2006/PER-soap12-part2-20061219/">http://www.w3.org/TR/2006/PER-soap12-part2-20061219/</loc></prevlocs>
    <latestloc><loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest" href="http://www.w3.org/TR/&shortname-part2;/">http://www.w3.org/TR/&shortname-part2;/</loc></latestloc>
    <authlist>
      <author>
	<name>Martin Gudgin</name>
	<affiliation>Microsoft</affiliation>
      </author>
      <author>
	<name>Marc Hadley</name>
	<affiliation>Sun Microsystems</affiliation>
      </author>
      <author>
	<name>Noah Mendelsohn</name>
	<affiliation>IBM</affiliation>
      </author>
      <author>
	<name>Jean-Jacques Moreau</name>
	<affiliation>Canon</affiliation>
      </author>
      <author>
	<name>Henrik Frystyk Nielsen</name>
	<affiliation>Microsoft</affiliation>
      </author>
      <author>
	<name>Anish Karmarkar</name>
	<affiliation>Oracle</affiliation>
      </author>
      <author>
	<name>Yves Lafon</name>
	<affiliation>W3C</affiliation>
      </author>
    </authlist>

<!--<errata href="http://www.w3.org/2003/06/REC-soap12-20030624-errata.html"/>

<translations>
The English version of this specification is the only normative version. Non-normative <loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest" href="http://www.w3.org/2002/07/soap-translation">translations</loc> may also be available.
</translations>-->

<abstract>
      <p>SOAP Version 1.2 is a lightweight protocol intended for
      exchanging structured information in a decentralized, distributed
      environment. SOAP Version 1.2 Part 2: Adjuncts defines a set of adjuncts that may
      be used with SOAP Version 1.2 Part 1: Messaging Framework. This specification
      depends on SOAP Version 1.2 Part 1: Messaging Framework <bibref
      ref="SOAP-PART1"/>. </p>
  	</abstract>

    <status>
<p>
This section describes the status of this document at the time of its 
publication. Other documents may supersede this document. The latest 
status of this document series is maintained at the W3C.</p>
<!--
<p><em>This section describes the status of this document at the time of its publication. Other documents may supersede this document. A list of current W3C publications and the latest revision of this technical report can be found in the <a href="http://www.w3.org/TR/">W3C technical reports index</a> at http://www.w3.org/TR/.</em></p>

<p>This document is a <a href="http://www.w3.org/2005/10/Process-20051014/tr.html#ProposedEditedRec">Proposed Edited Recommendation</a> of the W3C.
It updates the <a href="http://www.w3.org/TR/2003/REC-soap12-part2-20030624/">original Recommendation</a> by the inclusion of the <a href="http://www.w3.org/2003/06/REC-soap12-20030624-errata.html">errata</a>.
Changes between these two versions are described in a
<a href="diff-part2.html">diff document</a>.
Additionally, it incorporates changes to the SOAP Request Response Message
Exchange pattern (MEP) to permit the SOAP envelope in the response to be
optional, to allow for one-way message interactions.</p>

<p>This document has been produced by the <a
href="http://www.w3.org/2000/xp/Group/">XML Protocol Working Group</a>, which
is part of the <a href="http://www.w3.org/2002/ws/Activity">Web Services
Activity</a>.</p>

<p>Publication as a Proposed Edited Recommendation does not imply endorsement
by the W3C Membership. This is a draft document and may be updated, replaced or
obsoleted by other documents at any time. It is inappropriate to cite this
document as other than work in progress.</p>

<p>W3C Advisory Committee Representatives are invited to submit their formal review per the instructions in the Call for Review. Members of the public 
are also invited to send comments on this his Proposed Edited Recommendation to
the public
mailing-list <a href="mailto:xmlp-comments@w3.org">xmlp-comments@w3.org</a>
(<a href="http://lists.w3.org/Archives/Public/xmlp-comments/">archive</a>).
It is inappropriate to send discussion email to this address.</p>

<p>The review period extends to &per.review;.</p>

<p>Members of the W3C Advisory Committee will find the appropriate review form for this document by consulting their <a href="http://www.w3.org/2002/09/wbs/myQuestionnaires">list of current WBS questionnaires</a>.</p>

<p>SOAP Version 1.2 supercedes all previous versions of SOAP, including SOAP Version 1.1 <bibref ref="soap11"/></p>

<p>The SOAP 1.2 Implementation Report can be found at <a
href="http://www.w3.org/2000/xp/Group/2/03/soap1.2implementation.html">
http://www.w3.org/2000/xp/Group/2/03/soap1.2implementation.html</a>.
Additional implementation experience of the Request
Optional Response MEP can be found in the WSDL 2.0 implementation testing here:
<a href="http://dev.w3.org/cvsweb/~checkout~/2002/ws/desc/test-suite/Dashboard.html">http://dev.w3.org/cvsweb/~checkout~/2002/ws/desc/test-suite/Dashboard.html</a>.</p>

<p> This document is governed by the <a href="http://www.w3.org/TR/2002/NOTE-patent-practice-20020124">24 January 2002 CPP</a> as amended by the <a href="http://www.w3.org/2004/02/05-pp-transition">W3C Patent Policy Transition Procedure</a>. W3C maintains a <a rel="disclosure" href="http://www.w3.org/2000/xp/Group/2/10/16-IPR-statements.html">public list of any patent disclosures</a> made in connection with the deliverables of the group; that page also includes instructions for disclosing a patent. An individual who has actual knowledge of a patent which the individual believes contains <a href="http://www.w3.org/Consortium/Patent-Policy-20040205/#def-essential">Essential Claim(s)</a> must disclose the information in accordance with <a href="http://www.w3.org/Consortium/Patent-Policy-20040205/#sec-Disclosure">section 6 of the W3C Patent Policy</a>. </p>

<p>A list of current <a href="http://www.w3.org/TR/">W3C Recommendations and
other technical reports</a> can be found at <a
href="http://www.w3.org/TR">http://www.w3.org/TR</a>.</p>
-->
    </status>
    <langusage>
      <language id="en">English</language>
    </langusage>
    <revisiondesc>
      <p>Last Modified: $Date: 2007/03/07 14:20:42 $ CET</p>
    </revisiondesc>
  </header>
  <body>


    <div1 id="intro">
      <head>Introduction</head>

      <p>SOAP Version 1.2 (SOAP) is a lightweight protocol intended
	for exchange of structured information in a
	decentralized, distributed environment. The SOAP specification
	consists of three parts. Part 2 (this document)
	defines a set of adjuncts that MAY be used with the SOAP
	messaging framework:</p>
      
      <olist>
	<item>
	  <p>The SOAP Data Model represents application-defined data structures and values
            as a directed, edge-labeled graph of nodes (see <specref
	      ref="datamodel"/>).</p>
	</item>
	<item>
	  <p>The SOAP Encoding defines a set of rules for encoding
            instances of data that conform to the SOAP Data Model for
            inclusion in SOAP messages (see <specref
	      ref="soapenc"/>).</p>
	</item>
	<item>
	  <p>The SOAP RPC Representation defines a convention for how
	    to use the SOAP Data Model for representing RPC calls and
	    responses (see <specref ref="soapforrpc"/>).</p>
	</item>
	<item>
	  <p>The section for describing features and bindings defines
	    a convention for describing features and binding in terms
	    of properties and property values (see <specref
	    ref='soapfeatspec'/>).</p>
	</item>
				<item>
					<p>The section on SOAP-Supplied Message Exchange
					Patterns and Features defines a request response
					message exchange pattern and a message exchange
					pattern supporting non-SOAP requests for SOAP
					responses, (see <specref ref="soapsupmep"/>).</p>
				</item>
                <item>
					<p>The SOAP Web Method feature defines a feature for
					control of methods used on the World Wide Web (see
					<specref ref="WebMethodFeature"/>).</p>
				</item>
				<item>
					<p>The SOAP HTTP Binding defines a binding of SOAP
					to HTTP (see <bibref ref="RFC2616"/>) following the
					rules of the <xspecref xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
					href="&dated-part1;/#transpbindframew">SOAP Protocol
					Binding Framework</xspecref>, <bibref
					ref="SOAP-PART1"/> (see <specref
					ref="soapinhttp"/>).</p>
				</item>
			</olist>
   <p>SOAP 1.2 Part 0 <bibref ref="SOAP-PART0"/> is a non-normative document intended to
provide an easily understandable tutorial on the features of the SOAP Version
1.2 specifications.</p> 
   <p>SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> defines the SOAP messaging
framework.</p> 
			<note>
				<p>In previous versions of this specification the SOAP
	  name was an acronym. This is no longer the case.</p>
      </note>
	
        <div2 id="notcon">
	<head>Notational Conventions</head>

        <p>The keywords "MUST", "MUST NOT", "REQUIRED", "SHALL",
	  "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY",
	  and "OPTIONAL" in this document are to be interpreted as
	  described in RFC 2119 <bibref ref="RFC2119"/>.</p>
	  
	  <p>This specification uses a number of namespace prefixes throughout; they
	  are listed in <specref ref="tabprefns"/>. Note that the choice of any namespace
	  prefix is arbitrary and not semantically significant (see XML Infoset <bibref
	  ref="XMLInfoSet"/>).</p>
  
        <table border="1" id="tabprefns">
          <caption>Prefixes and Namespaces used in this specification</caption>
          <tbody>
          <tr>
            <th>Prefix</th>
            <th>Namespace</th>
            <th>Notes</th>
          </tr>
          <tr>
            <td>env</td>
            <td><attval>http://www.w3.org/2003/05/soap-envelope</attval></td>
            <td>Defined by SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>.</td>
          </tr>
          <tr>
            <td>enc</td>
            <td><attval>http://www.w3.org/2003/05/soap-encoding</attval></td>
            <td>A normative XML Schema <bibref ref="XMLSchemaP1"/>,
            <bibref ref="XMLSchemaP2"/> document for the
            <attval>http://www.w3.org/2003/05/soap-encoding</attval>
            namespace can be found at <loc
            xmlns:xlink="http://www.w3.org/1999/xlink"
            xlink:type="simple"
            href="http://www.w3.org/2003/05/soap-encoding"
            xlink:show="replace"
            xlink:actuate="onRequest">http://www.w3.org/2003/05/soap-encoding</loc>.</td>
          </tr>
          <tr>
            <td>rpc</td>
            <td><attval>http://www.w3.org/2003/05/soap-rpc</attval></td>
            <td>A normative XML Schema <bibref ref="XMLSchemaP1"/>,
            <bibref ref="XMLSchemaP2"/> document for the
            <attval>http://www.w3.org/2003/05/soap-rpc</attval>
            namespace can be found at <loc
            xmlns:xlink="http://www.w3.org/1999/xlink"
            xlink:type="simple"
            href="http://www.w3.org/2003/05/soap-rpc"
            xlink:show="replace"
            xlink:actuate="onRequest">http://www.w3.org/2003/05/soap-rpc</loc>.</td>
          </tr>
          <tr>
            <td>xs</td>
            <td><attval>http://www.w3.org/2001/XMLSchema</attval></td>
            <td>Defined in the W3C XML Schema
          specification <bibref ref="XMLSchemaP1"/>, <bibref
          ref="XMLSchemaP2"/>.</td>
          </tr>
          <tr>
            <td>xsi</td>
            <td><attval>http://www.w3.org/2001/XMLSchema-instance</attval></td>
            <td>Defined in the W3C XML Schema
          specification <bibref ref="XMLSchemaP1"/>, <bibref
          ref="XMLSchemaP2"/>.</td>
          </tr>
          </tbody>
        </table>

        <p>Namespace names of the general form <attval>http://example.org/...</attval>
          and <attval>http://example.com/...</attval> represent
          application or context-dependent URIs (see RFC 3986 <bibref ref="RFC3986"/>).</p>

        <p>This specification uses the Extended Backus-Naur Form
          (EBNF) as described in XML 1.0 <bibref ref="XML"/>.</p>

    	<p>With the exception of examples and sections explicitly marked
    	as "Non-Normative", all parts of this specification are
    	normative.</p>
      
      </div2>
    </div1>

    <div1 id="datamodel">
      <head>SOAP Data Model</head>
      
      <p>The SOAP Data Model represents application-defined data
      structures and values as a directed edge-labeled graph of nodes.
      Components of this graph are described in the following
      sections.</p>

      <p>
	  The purpose of the SOAP Data Model is to provide a mapping
	  of non-XML based data to some wire representation. It is important
	  to note that use of the SOAP Data Model, the accompanying SOAP
	  Encoding (see <specref ref="soapenc"/>), and/or the SOAP RPC
	  Representation (see <specref ref="soapforrpc"/>) is
	  OPTIONAL. Applications which already model data in XML may not need to use the SOAP
	  Data Model. Due to their optional nature, it is NOT a
	  requirement to implement the SOAP Data Model, the SOAP
	  Encoding and/or the SOAP RPC Representation as part of a
	  SOAP node.
      </p>

	  <div2 id='graphedges'>
	    <head>Graph Edges</head>
	    <p>
	    Edges in the graph are said to <emph>originate</emph> at a
	    graph node
	    and <emph>terminate</emph> at a graph node. An edge that
	    originates at a graph
	    node is known as an <emph>outbound edge</emph> with respect to that
	    graph node. An edge that terminates at a graph node is known as an <emph>inbound
	    edge</emph> with respect to that graph node. An edge MAY originate and
	    terminate at the same graph node. An edge MAY
	    have only an originating graph node, that is be outbound only. An edge MAY have only a
	    terminating graph node, that is be inbound only.</p>
        
        <p>The outbound edges of a given graph node MAY be
	    distinguished by label or by position. Position 
	    is a total order on such edges; thus, if any
	    outbound edges from a given node are distinguished by
	    position, then all outbound edges from that node are so distinguished.</p>
	    
	    <div3 id='edgelabels'>
	    <head>Edge labels</head>

	    <p>An edge label is an XML qualified name. Two edge
	    labels are equal if and only if their XML expanded names are
	    equal. I.e., both of the following are true:</p>

	    <olist>
	      <item>
		    <p>
		    Their local name values are the same.
		    </p>
		  </item>
	      <item>
		    <p>
		    Either of the following is true:</p>
		    <olist>
		      <item>
			    <p>
			    Both of their namespace name values are missing.
			    </p>
			  </item>
			  <item>
			    <p>
			    Their namespace name values are both present and are
			    both the same.
			    </p>
			  </item>
	        </olist>
		  </item>
	    </olist>

		<p>See <specref ref='values' /> for uses of edge labels and position
	    to distinguish the members of encoded values, and 
	    XML Schema <bibref ref='XMLSchemaP2' /> for more
	    information about comparing XML qualified names.
	    </p>
		</div3>
      </div2>

	  <div2 id='graphnodes'>
	    <head>Graph Nodes</head>

	    <p>A graph node has zero or more outbound edges. A graph node that has no
	    outbound edges has an optional lexical value. All graph nodes have an
	    optional type name of type <emph>xs:QName</emph> in the namespace named
	    "http://www.w3.org/2001/XMLSchema" (see 
	    XML Schema <bibref ref='XMLSchemaP2' />).</p>
	
	    <div3 id='singlemultiref'>
		  <head>Single and Multi Reference Nodes</head>
	      <p>
	      A graph node may be <emph>single reference</emph> or
	      <emph>multi reference</emph>. A 
	      single reference graph node has a single inbound edge. A multi
	      reference graph node has multiple inbound edges.
	      </p> 
		</div3>
      </div2>
	  <div2 id='values'>
	    <head>Values</head>

	    <p>A simple value is represented as a graph node with a lexical value.
	    </p>

	    <p>A compound value is represented as a graph node with zero or more
	    outbound edges as follows:
	    </p>

   	    <olist>
   	      <item>
   	    	<p>
   	    	A graph node whose outbound edges are distinguished solely
   	    	by their labels is known as a "struct". The outbound edges
   	    	of a struct MUST be labeled with distinct names (see
   	    	<specref ref='edgelabels' />).
   	    	</p>
   	    	</item>
   	    	<item>
   	    	<p>
   	    	A graph node whose outbound edges are distinguished solely
   	    	by position is known as an "array". The outbound edges of
   	    	an array MUST NOT be labeled.
   	    	</p>
   	    	</item>
   	    </olist>
		
  	  </div2>
	</div1> 

    <div1 id="soapenc">
      <head>SOAP Encoding</head>
      
      <p>
	  SOAP Encoding provides a means of encoding instances of data
	  that conform to the data model described in <specref
	  ref="datamodel"/>. This encoding
	  MAY be used to transmit data in SOAP header blocks and/or SOAP
	  bodies. Other data models, alternate encodings of the SOAP
	  Data Model as well as unencoded data MAY also be used in SOAP
	  messages (see SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>,
	  <xspecref xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
	  href="&dated-part1;/#soapencattr">SOAP
	  encodingStyle Attribute</xspecref> for specification of alternative
	  encoding styles and see <specref ref='soapforrpc' />  for
	  restrictions on data models and encodings used to represent SOAP 
	  Remote Procedure Calls (RPC)).
	  </p>

      <p>The serialization rules defined in this section are
      identified by the URI
      <attval>http://www.w3.org/2003/05/soap-encoding</attval>. SOAP
      messages using this particular serialization SHOULD indicate
      that fact by using the SOAP <att>encodingStyle</att> attribute
      information item (see SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>
      <xspecref xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
      href="&dated-part1;/#soapencattr">SOAP
      encodingStyle Attribute</xspecref>).
	  </p>

      <div2 id="encrules">
        <head>Mapping between XML and the SOAP Data Model</head>

        <p>
		XML allows very flexible encoding of data. SOAP Encoding
        defines a narrower set of rules for encoding the graphs
        described in <specref ref='datamodel' />. This section
        defines the encoding at a high level, and the subsequent
        sub-sections describe the encoding rules in more detail. The
        encodings described in this 
        section can be used in conjunction with the mapping of RPC
        requests and responses specified in <specref ref="soapforrpc"/>.
		</p>

		<p>
		The encodings are described below from the perspective of a
		de-serializer. In each case, the presence of an XML
		serialization is presumed, and the mapping to a corresponding
		graph is described.
		</p>

		<p>
		More than one encoding is typically possible
		for a given graph. When serializing a graph for transmission
		inside a SOAP message,
		a representation that deserializes to the identical graph MUST
		be used; when multiple such representations are possible, any
		of them MAY be used. When receiving an encoded SOAP message,
		all representations MUST be accepted.
		</p>
		
		<div3 id='encodingedgesandnodes' >
		  <head>Encoding Graph Edges and Nodes</head>

		  <p>
		  Each graph edge is encoded as an <emph>element information
		  item</emph> and each <emph>element information item</emph>
		  represents a graph edge. <specref ref='complexenc' />
		  describes the relationship between edge labels and the [local name] and
		  [namespace name] properties of such <emph>element 
		  information items</emph>.
		  </p>

		  <p>The graph node at which an edge terminates is
		  determined by examination of the serialized XML as follows:</p>
		  <olist>
		    <item>
		      <p>
			  If the <emph>element information item</emph> representing
			  the edge does not have a <att>ref</att> <emph>attribute
			  information item</emph> (see <specref ref='refattr' />)
			  among its attributes then that <emph>element information
			  item</emph> is said to <emph>represent</emph> a node in
			  the graph and the edge terminates at that node.
			  In such cases the <emph>element
			  information item</emph> represents both a graph edge
			  and a graph node</p>
		    </item>
		    <item>
		      <p>
			  If the <emph>element information item</emph> representing
			  the edge does have a <att>ref</att> <emph>attribute
			  information item</emph> (see <specref
			  ref='refattr' />) among its attributes,
			  then the value of that <emph>attribute information
			  item</emph> MUST be identical to the value of exactly one
			  <att>id</att> <emph>attribute information item</emph> (
			  see <specref ref='idattr' />) in the same envelope. 
			  In this case the edge terminates at the graph node
			  represented by the <emph>element information item</emph>
			  on which the <att>id</att> <emph>attribute information
			  item</emph> appears. That <emph>element information
			  item</emph> MUST be in the scope of an
			  <att>encodingStyle</att> attribute with a value of
			  <attval>http://www.w3.org/2003/05/soap-encoding</attval>
                          (see SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>,
                          <xspecref
                          xmlns:xlink="http://www.w3.org/1999/xlink"
                          xlink:type="simple" href="&dated-part1;/#soapencattr">SOAP encodingStyle
                          Attribute</xspecref>).
			  </p>
		    </item>
		  </olist>

		  <p>
		  All nodes in the graph are encoded as described in 1
		  above. Additional inbound edges for multi reference graph nodes
		  are encoded as described in 2 above.
		  </p>
		</div3>

		<div3 id="simpleenc">
		  <head>Encoding Simple Values</head>
		  <p>
		  The lexical
		  value of a graph node representing a simple value is the sequence of
		  Unicode characters identified by the <emph>character
		  information item</emph> children of the <emph>element
		  information item</emph> representing that node.
		  The <emph>element information item</emph> representing a simple value node MAY have
		  among its attributes a 'nodeType' <emph>attribute information item</emph> (see <specref ref="nodeTypeattr"/>).
		  Note that
		  certain Unicode characters cannot be represented in XML (see XML 1.0 <bibref ref='XML' />).
		  </p>
		</div3>

		<div3 id="complexenc">
		  <head>Encoding Compound Values</head>
		  <p>
		  An outbound edge of a graph node is encoded as an
		  <emph>element information item</emph> child of the
		  <emph>element information item</emph> that represents the
		  node (see <specref ref='encodingedgesandnodes' />).
		  Particular rules apply depending on what kind of compound
		  value the graph node represents. These rules are as follows:</p>

		  <olist>
		    <item>
		      <p>For a graph edge which is distinguished by label, the [local name] and
			  [namespace name] properties of the child
			  <emph>element information item</emph>
			  together determine the value of the edge
			  label. 
			  </p>
			</item>
			<item>
			  <p>
			  For a graph edge which is distinguished by position:</p>
	
			  <ulist>
			    <item>
				  <p>
				  The ordinal position of the graph edge corresponds
				  to the position of the child <emph>element information
				  item</emph> relative to its siblings
				  </p>
				</item>
			    <item>
				  <p>The [local name] and [namespace name]
				  properties of the child <emph>element information
				  item</emph> are not significant.
				  </p>
				</item>
			  </ulist>
			</item>
			<item>
			  <p>The element information item representing a compound
			  value node MAY have among its attributes a
			  <att>nodeType</att> <emph>attribute information
			  item</emph> (see <specref ref="nodeTypeattr"/>).
			  </p>
			</item>
			<item>
			  <p>The following rules apply to the encoding of a graph node that
			  represents an "array":</p>
			  <ulist>
			    <item>
				  <p>
				  The <emph>element information item</emph>
				  representing an array node MAY have among its
				  attributes an <att>itemType</att> <emph>attribute
				  information item</emph> (see <specref
				  ref='itemtypeattr' />). 
				  </p>
				</item>
			    <item>
				  <p>
				  The <emph>element information item</emph>
				  representing an array node MAY have among its
				  attributes an <att>arraySize</att> <emph>attribute
				  information item</emph> (see <specref
				  ref='arraySizeattr' />). 
				  </p>
				</item>
			  </ulist>
			</item>
			<item>
			  <p>
			   If a graph edge does not terminate in a graph node then
			   it can either be omitted from the serialization or it can be
			   encoded as an <emph>element information item</emph>
			   with an <emph>xsi:nil</emph> <emph>attribute
			   information item</emph> whose value is <attval>true</attval>.
			  </p>
			</item>
		  </olist>
	  </div3>

	  <div3 id='enctypename'>
	    <head>Computing the Type Name Property</head>
		<p>
		The type name property of a graph node is a {namespace name,
		local name} pair computed as follows:</p>

		<olist>
		<item>
		<p>
		If the <emph>element information item</emph> representing the
		graph node has an <att>xsi:type</att> <emph>attribute
		information item</emph> 
		among its attributes then the type name property of the
		graph node is the value of the <att>xsi:type</att> <emph>attribute
		information item</emph>.</p>
		<note>
		<p>
		This attribute is of type <emph>xs:QName</emph> (see 
		XML Schema <bibref ref='XMLSchemaP2' />); its value consists of the 
		pair {namespace name, local name}. Neither the prefix used to
		construct the QName nor any information relating to any
		definition of the type is considered to be part of the
		value. The SOAP graph carries only the qualified name of the
		type.
		</p>
		</note>
		</item>
		<item>
		<p>
		Otherwise if the parent <emph>element information item</emph> of the
		<emph>element information item</emph> representing the graph
		node has an <att>enc:itemType</att> <emph>attribute
		information item</emph> (see <specref ref='itemtypeattr' />)
		among its attributes then the type
		name property of the graph node is the value of the
		<att>enc:itemType</att> <emph>attribute information item</emph>
		</p>
		</item>
		<item>
		<p>
		Otherwise the value of the type name property of the graph
		node is unspecified.
		</p>
		</item>
		</olist>

		<note>
		<p>
		These rules define how the type name property
		of a graph node in
		a graph is computed from a serialized encoding. This
		specification does not mandate validation using any particular
		schema language or type system. Nor does it include built in types or
		provide any standardized faults to reflect value/type
		name conflicts.
		</p>
		<p>
		However, nothing prohibits development of
		additional specifications to describe the use of SOAP Encoding with
		particular schema languages or type systems. Such additional
		specifications MAY mandate validation using particular
		schema language, and MAY specify faults to be generated if
		validation fails. Such additional specifications MAY specify
		augmentations to the deserialized graph based on information
		determined from such a validation. The use by SOAP Encoding of xsi:type
		is intended to facilitate integration with the W3C XML Schema
		language (see <specref ref='encschema' />). Other XML based
		schema languages, data schemas and programmatic type systems
		MAY be used but only to the extent that they are compatible
		with the serialization described in this specification.
		</p>		
		</note>

	    <div4 id="itemtypeattr">
	     <head>itemType Attribute Information Item</head>
         <p>
		 The <att>itemType</att> <emph>attribute information item</emph> has
		 the following Infoset properties:
		 </p> 
	 <ulist>

	        <item>
			  <p>
			  A [local name] of <att>itemType</att>.
			  </p>
			</item>

            <item>
			  <p>
			  A [namespace name] of <attval>http://www.w3.org/2003/05/soap-encoding</attval>. 
			  </p>
			</item>

            <item>
			  <p>
			  A [specified] property with a value of <attval>true</attval>.
			  </p>
			</item>

		  </ulist> 
	      <p>
		  The type of the <att>itemType</att> <emph>attribute
          information item</emph> is <emph>xs:QName</emph>.
          The value of the <att>itemType</att> <emph>attribute 
          information item</emph> is used to compute the type name
          property (see <specref ref='enctypename' />) of members of
          an array.
		  </p>

		</div4>

	   </div3>

	  <div3 id='uniqueids'>
	    <head>Unique identifiers</head>
		
	    <div4 id="idattr">
	     <head>id Attribute Information Item</head>
         <p>
		 The <att>id</att> <emph>attribute information item</emph> has
		 the following Infoset properties:
		 </p> 
		 <ulist>

	        <item>
			  <p>A [local name] of <att>id</att>.</p>
			</item>

            <item>
			  <p>A [namespace name] of <attval>http://www.w3.org/2003/05/soap-encoding</attval>.</p>
			</item>

            <item>
			  <p>A [specified] property with a value of
			  <attval>true</attval>.</p>
			</item>

		  </ulist> 
	      <p>
		  The type of the <att>id</att> <emph>attribute
          information item</emph> is <emph>xs:ID</emph>.
          The value of the <att>id</att> <emph>attribute information
          item</emph> is a unique identifier that can be referred to by
          a <att>ref</att> <emph>attribute information item</emph>
          (see <specref ref="refattr"/>).
		  </p>
		 </div4>

	     <div4 id="refattr">
	      <head>ref Attribute Information Item</head>
          <p>
		  The <att>ref</att> <emph>attribute information item</emph> has
		  the following Infoset properties:
		  </p> 
		  <ulist>

	        <item>
			  <p>A [local name] of <att>ref</att>.</p>
			</item>

            <item>
			  <p>A [namespace name] of <attval>http://www.w3.org/2003/05/soap-encoding</attval>.</p>
			</item>

            <item>
              <p>A [specified] property with a value of
              <attval>true</attval>.</p>
			</item>
 
		   </ulist> 
	       <p>
		   The type of the <att>ref</att> <emph>attribute information
		   item</emph> is <emph>xs:IDREF</emph>.
		   The value of the <att>ref</att> <emph>attribute information
		   item</emph> is a reference to a unique identifier defined
		   by an <att>id</att> <emph>attribute information item</emph>
		   (see <specref ref="idattr"/>).
		   </p>

		</div4>
		<div4 id='uniqueidconstraints' >
		  <head>Constraints on id and ref Attribute Information
		  Items</head>
		  <p>
		  The value of a <att>ref</att> <emph>attribute information item</emph> MUST also be
		  the value of exactly one <att>id</att> <emph>attribute information item</emph>.
		  </p>
		  <p>
		  A <att>ref</att> <emph>attribute information item</emph> and
		  an <att>id</att> <emph>attribute information item</emph>
		  MUST NOT appear on the same <emph>element information item</emph>.
		  </p>
		</div4>
	  </div3>



	   <div3 id="arraySizeattr">
	     <head>arraySize Attribute Information Item</head>
         <p>
		 The <att>arraySize</att> <emph>attribute information item</emph> has
		 the following Infoset properties:
		 </p> 
		 <ulist>

	        <item>
			  <p>
			  A [local name] of <att>arraySize</att>.
			  </p>
			</item>

            <item>
			  <p>A [namespace name] of <attval>http://www.w3.org/2003/05/soap-encoding</attval>. 
              </p>
			</item>			
		  </ulist> 
		  
	      <p>
		  The type of the <att>arraySize</att> <emph>attribute
          information item</emph> is <emph>enc:arraySize</emph>.
          The value of the <att>arraySize</att> <emph>attribute information item</emph>
          MUST conform to the following EBNF grammar</p>

		  <scrap headstyle="suppress">
		    <head></head>
            <prod id="arraysizedefn">
              <lhs>arraySizeValue</lhs> 
              <rhs>("*" | concreteSize) nextConcreteSize*</rhs>
            </prod>
            <prod id="nextconcretesize">
              <lhs>nextConcreteSize</lhs>
			  <rhs>whitespace concreteSize</rhs>
            </prod>
            <prod id="concretesize">
              <lhs>concreteSize</lhs>
              <rhs>[0-9]+</rhs>
            </prod>
			<prod id="whitespace">
			  <lhs>white space</lhs>
			  <rhs>(#x20 | #x9 | #xD | #xA)+</rhs>
			</prod>
          </scrap>
		  <p>
		      The arraySize attribute conveys a suggested mapping of a SOAP array to a
multi-dimensional program data structure.  The cardinality of the arraySize
list represents the number of dimensions, with individual values providing
the extents of the respective dimensions.  When SOAP encoding
multidimensional arrays, nodes are selected such that the last subscript
(i.e., the subscript corresponding to the last specified dimension) varies
most rapidly, and so on with the first varying most slowly.    An asterisk
MAY be used only in place of the first size to indicate a dimension of
unspecified extent;  asterisks MUST NOT appear in other positions in the
list.  The default value of the <att>arraySize</att> <emph>attribute information item</emph> is
"*", i.e., a single dimension of unspecified extent.
</p>

		</div3>
	   <div3 id="nodeTypeattr">
	     <head>nodeType Attribute Information Item</head>
         <p>
		 The <att>nodeType</att> <emph>attribute information item</emph> has
		 the following Infoset properties:
		 </p> 
		 <ulist>

	        <item>
			  <p>
			  A [local name] of <att>nodeType</att>.
			  </p>
			</item>

            <item>
			  <p>A [namespace name] of <attval>http://www.w3.org/2003/05/soap-encoding</attval>. 
              </p>
			</item>
            <item>
			  <p>A [specified] property with a value of
			  <attval>true</attval>.</p>
			</item>
			
		  </ulist> 
	      <p>
		  The type of the <att>nodeType</att> <emph>attribute
          information item</emph> is <emph>enc:nodeType</emph>.</p>

             
            <p>
	    The value of the <att>nodeType</att> <emph>attribute information item</emph>
            MUST, if present, be one of the strings "simple" or "struct" or "array". The value
	    indicates what kind of a value this node represents - a simple value, a 
	    compound struct value or a compound array value respectively.
	    </p>


	</div3>

      </div2>

      <div2 id="encfaults">
        <head>Decoding Faults</head>

		<p>
		During deserialization a SOAP receiver:
 	    </p>

        <ulist>

		  <item>
		    <p>
			SHOULD generate an <attval>env:Sender</attval> SOAP
            fault with a subcode of <code>enc:MissingID</code>
			if the message contains a <att>ref</att> <emph>attribute
            information item</emph> but no corresponding <att>id</att>
            <emph>attribute information item</emph> (see <specref
            ref='uniqueidconstraints' />).
			</p>
		  </item>

		  <item>
		    <p>
			SHOULD generate an <attval>env:Sender</attval> SOAP
            fault with a subcode of <code>enc:DuplicateID</code>
			if the message contains two or more <att>id</att> <emph>attribute
            information item</emph> that have the same value. (see <specref
            ref='uniqueidconstraints' />).
			</p>
		  </item>

	      <item>
		    <p>
			MAY generate an <attval>env:Sender</attval> SOAP fault with a
			subcode of <code>enc:UntypedValue</code> if the type name
			property of an encoded graph node is unspecified.
			</p>
	      </item>

        </ulist>
     </div2>

    </div1>


    <div1 id="soapforrpc">
      <head>SOAP RPC Representation</head>
      
      <p>One of the design goals of SOAP is to facilitate
	the exchange of messages that map conveniently to definitions
	and invocations of methods and procedures in commonly used
	programming languages. For that purpose, this section defines
	a uniform representation of remote procedure call (RPC) requests and responses. It
	does not define actual mappings to any particular programming
	language. The representation is entirely platform-independent
	and considerable effort has been made to encourage usage that
	is consistent with the Web in general.</p>

      <p>As mentioned in section <specref ref="datamodel"/>, use and
	implementation of the SOAP RPC Representation is OPTIONAL.</p>

      <p> The SOAP <att>encodingStyle</att> attribute information item (see
      SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
      xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href='&dated-part1;/#soapencattr'>SOAP encodingStyle
      Attribute</xspecref>) is used to indicate the encoding style of
      the RPC representation. The encoding thus specified MUST support the <specref
      ref='datamodel' />. The encoding style defined in <specref
      ref='soapenc' /> supports such constructs and is therefore
      suitable for use with the SOAP RPC Representation. </p>

      <p>
      This SOAP RPC Representation is not predicated on any SOAP
      protocol binding. When SOAP is bound to HTTP, an RPC invocation
      maps naturally to an HTTP request and an RPC response maps to an
      HTTP response. (see <specref ref='soapinhttp'/>). However, the
      SOAP RPC Representation is not limited to the SOAP HTTP Binding.
      </p>

      <p>To invoke an RPC, the following information is needed:</p>

      <ulist>
        <item><p>The address of the target SOAP node.</p></item>

        <item><p>A procedure or method name.</p></item>

        <item>
					<p>The identities
        and values of any arguments to be passed to the procedure or method. Arguments used to
identify Web resources SHOULD be distinguished from those representing data or control information (see
<specref ref="RPCWebArguments"/>.)</p>
</item>
                                <item>
                                     <p>Values for properties as required by any features of the 
binding to be used. For example, <attval>GET</attval> or <attval>POST</attval>
for the <att>http://www.w3.org/2003/05/soap/features/web-method/Method</att> property of the <specref ref="WebMethodFeature"/>.</p>
                                </item>

        <item><p>Optional header data.</p></item>

      </ulist>

      <p>SOAP RPC relies on the protocol binding to provide a mechanism
      for carrying the URI of the target SOAP node. For HTTP the request URI
      indicates the resource against which the invocation is being
      made. Other than requiring it to be a valid URI, SOAP places no
      restriction on the form of an identifier (see RFC 3986 <bibref ref="RFC3986"/>
      for more information on URIs). The section <specref ref="RPCWebArguments"/> further discusses the use
of URIs for identifying RPC resources.</p>
<p>The SOAP RPC Representation employs the <specref ref="singlereqrespmep"/> and <specref ref="soapresmep"/>. Use of the SOAP RPC Representation with other MEPs MAY be possible, but is beyond the
scope of this specification.</p>



			<div2 id="RPConWeb">
                              <head>Use of RPC on the World Wide Web</head>
                              <p> 
The following guidelines SHOULD be followed when deploying 
SOAP RPC applications 
on the World Wide Web.</p>
                            
<div3 id="RPCWebArguments">
<head>Identification of RPC Resources</head>
<p>The World Wide Web identifies resources with URIs, but common programming conventions convey identification information in the arguments to 
procedures, or in the names of those procedures. For example, the call:</p>
<p><code>
updateQuantityInStock(PartNumber="123", NewQuantity="200")
</code></p>
<p>suggests that the resource to be
updated is the <el>QuantityInStock</el> for <el>PartNumber</el> <attval>123</attval>.
Accordingly, when mapping to
or from a programming language method or procedure, any arguments that serve to identify resources
(such as the part number above) should when practical be represented in the URI to which the SOAP message is addressed. 
When mapping to or from a programming language method or procedure, the name of which
identifies or qualifies the identification of a resource (such as QuantityInStock above), such naming or
qualification should when practical be represented in the URI to which the SOAP message is addressed.
No standard means of representation of arguments or method names is provided by this specification.</p>

<note>
<p>Conventions for specific URI encodings of procedure
names and arguments, as well as for controlling the
inclusion of such arguments in the SOAP RPC body could be established in conjunction with the development
of Web Service interface description languages. They could be developed when SOAP is bound to particular
programming languages or could be established on an application- or
procedure-specific basis.</p>
</note>

</div3>

<div3 id="RPCResourceRetrieval">
<head>Distinguishing Resource Retrievals from other RPCs</head>
<p>
The World Wide Web depends on mechanisms that optimize commonly performed information retrieval
tasks. Specifically, protocols such as HTTP <bibref ref="RFC2616"/> provide a GET method which is 
used to perform safe
retrievals, i.e., to perform retrievals that are idempotent, free of side effects, and for which security considerations  do not
preclude the use of cached results or URI-based resource identification.</p>
<p>
Certain procedure or method calls represent requests for information retrieval. For example, the call:</p>
   <p><code>getQuantityInStock(PartNumber="123")</code></p>
<p>might be used to retrieve the quantity established in
the example above.</p>

<p>The following conventions can be employed to implement SOAP retrievals and other
RPCs on the Web:
</p>
<ulist>
<item>
<p>
The conventions described in <specref ref="RPCWebArguments"/> are used to identify the
resource with a URI.
</p>
</item>
<item>
<p>In cases where all the arguments have been represented in the URI,
no SOAP header blocks are to be transmitted and the operation is a safe
retrieval, the <specref ref="WebMethodFeature"/> and the <specref
ref="soapresmep"/> are used. Accordingly, no SOAP envelope is
transmitted for the request, and the
<att>http://www.w3.org/2003/05/soap/features/web-method/Method</att>
property is set to <attval>GET</attval>. The results of the retrieval
are a SOAP RPC response as described in <specref ref="rpcresponse"/></p>
</item>
<item>
<p>
In cases where the operation to be performed is not a retrieval, when
SOAP header  blocks are to be transmitted (a digital signature, for example),
or when a retrieval is not safe, the <specref ref="WebMethodFeature"/> and the <specref
ref="singlereqrespmep"/> are used. The
request envelope is encoded as described in <specref
ref="rpcinvocation"/>, and the results are as described in <specref
ref="rpcresponse"/>. The <att>http://www.w3.org/2003/05/soap/features/web-method/Method</att> property is
set to <attval>POST</attval>.</p>
</item></ulist>

<p>The SOAP RPC Representation does not define any other value for the
<att>http://www.w3.org/2003/05/soap/features/web-method/Method</att>.</p>

</div3>

</div2>

<div2 id="rpcsoapbdy">
	<head>RPC and SOAP Body</head>

    <p>RPC invocations (except for safe retrievals: see <specref
    ref="RPCResourceRetrieval"/>) and responses are both carried in the
    SOAP <el>Body</el> element (see SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
    xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="&dated-part1;/#soapbody">SOAP Body</xspecref>) using the
    following representation:</p>

    <div3 id="rpcinvocation">
        <head>RPC Invocation</head>
        
        <p>An RPC invocation is modeled as follows:</p>
          
        <ulist>
          <item><p>The invocation is represented by a single
          struct containing an outbound edge for each [in] or [in/out]
          parameter. The struct is named identically to the procedure or
          method and the conventions of <specref ref="namemap"/>
          SHOULD be used to represent method names that are not legal
          XML names.</p></item>

          <item><p>Each outbound edge has a label
          corresponding to the name of the parameter. The conventions of
          <specref ref="namemap"/> SHOULD be used to represent parameter
          names that are not legal XML names.</p></item>

        </ulist>

        <p>Applications MAY process invocations with missing
        parameters but also MAY fail to process the invocation and return a fault.</p>
        
        </div3>
        
        
        <div3 id="rpcresponse">
        <head>RPC Response</head>
        
        <p>An RPC response is modeled as follows:</p>

        <ulist>
          <item><p>The response is represented by a single struct
          containing an outbound edge for the return value and each [out]
          or [in/out] parameter. The name of the struct is not significant.</p></item>

		  <item><p>Each parameter is represented by an outbound edge
		  with a label corresponding to the name of the parameter. The conventions of
          <specref ref="namemap"/> SHOULD be used to represent parameter
          names that are not legal XML names.</p></item>

		  <item><p>
		  A non-void return value is represented as follows:</p>

		  <olist>
		    <item>
			  <p>There MUST be an outbound edge with a local name of <el>result</el> and a namespace
		  name of <attval>http://www.w3.org/2003/05/soap-rpc</attval>
		  which terminates in a terminal node</p>
			</item>
			<item>
			<p>
			The type of that terminal node is a xs:QName and its value
			is the name of the outbound edge which terminates in the
			actual return value. 
			</p>
			</item>
		  </olist>

		  <p>If the return value of the procedure is void
		  then an outbound edge with a local name of <el>result</el> and a namespace
		  name of <attval>http://www.w3.org/2003/05/soap-rpc</attval>
		  MUST NOT be present.</p>
		  </item>


          <item><p>Invocation faults are handled according to the
          rules in <specref ref="rpcfaults"/>. If a protocol binding
          adds additional rules for fault expression, those MUST also
          be followed.</p></item>
        </ulist>

        
        </div3>
        
        <div3 id="rpcencrestriction">
        
            <head>SOAP Encoding Restriction</head>
            
            <p>When using SOAP encoding (see <specref ref="soapenc"/>) in
            conjunction with the RPC convention described here, the SOAP
            <el>Body</el> MUST contain only a single child <emph>element
            information item</emph>, that child being the serialized RPC
            invocation or response struct.</p>
                        
        </div3>

      </div2>

      <div2 id="rpcsoaphead">
	<head>RPC and SOAP Header</head>
        
        <p>Additional information relevant to the encoding of an RPC
        invocation but not part of the formal procedure or method
        signature MAY be expressed in a SOAP envelope carrying an RPC invocation or response.
        Such additional information MUST be expressed as SOAP header blocks.</p>
        

      </div2>

      <div2 id="rpcfaults">
        <head>RPC Faults</head>

        <p>The SOAP RPC Representation introduces additional SOAP fault
        subcode values to be used in conjunction with the fault codes
        described in SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
        xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
        href="&dated-part1;/#faultcodes">SOAP Fault Codes</xspecref>.</p>
        
        <p>Errors arising during RPC invocations are reported
        according to the following rules:</p>

	<olist>

	  <item><p>A fault with a <el>Value</el> of
          <el>Code</el> set to <attval>env:Receiver</attval> SHOULD
          be generated when the receiver cannot handle the message
          because of some temporary condition, e.g. when it is out of
          memory.</p>

	    <note>
	      <p>Throughout this document, the term "<el>Value</el> of
		<el>Code</el>" is used as a shorthand for "value of
		the <el>Value</el> child <emph>element information
		item</emph> of the <el>Code</el> <emph>element
		information item</emph>" (see SOAP 1.2 Part 1 <bibref
		ref="SOAP-PART1"/>, <xspecref
		xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
		href="&dated-part1;/#faultcodeelement">SOAP Code
		Element </xspecref>).</p>
	    </note>

	  </item>

          <item>
            <p>A fault with a <el>Value</el> of <el>Code</el>
            set to <attval>env:DataEncodingUnknown</attval>
	    SHOULD be generated when the arguments
            are encoded in a data encoding unknown to the
            receiver.</p>
          </item>

	  <item>
            <p>A fault with a <el>Value</el> of <el>Code</el>
            set to <attval>env:Sender</attval> and a
            <el>Value</el> of <el>Subcode</el> set to
	    <attval>rpc:ProcedureNotPresent</attval>
            MAY be generated when the receiver
            does not support the procedure or method specified.</p>

	    <note>
	      <p>Throughout this document, the term "<el>Value</el> of
		<el>Subcode</el>" is used as a shorthand for "value of
		the <el>Value</el> child <emph>element information
		item</emph> of the <el>Subcode</el> <emph>element
		information item</emph>" (see SOAP 1.2 Part 1 <bibref
		ref="SOAP-PART1"/>, <xspecref
		xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
		href="&dated-part1;/#faultsubcodeelement">SOAP Subcode
		element</xspecref>).</p>
	    </note>

	  </item>

	  <item>
            <p>A fault with a <el>Value</el> of <el>Code</el>
            set to <attval>env:Sender</attval> and a
            <el>Value</el> of <el>Subcode</el> set to 
            <attval>rpc:BadArguments</attval> 
            MUST be generated when the receiver
            cannot parse the arguments or when there is a
            mismatch in number and/or type of the arguments
            between what the receiver expects and what was
            sent.</p>
	  </item>

	  <item><p>Other faults arising in an extension or from the
          application SHOULD be generated as described in SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
          xmlns:xlink="http://www.w3.org/1999/xlink"
          xlink:type="simple" href="&dated-part1;/#soapfault">SOAP Fault Codes</xspecref>.</p>
      </item>

	</olist>
        
        <p>In all cases the values of the <el>Detail</el> and
        <el>Reason</el> <emph>element information items</emph>
        are implementation-defined. Details of their use MAY be specified by an
        external document.</p>
        
        <note><p>Senders might receive different faults from
        those listed above in response to an RPC invocation if the
        receiver does not support the (optional) RPC convention described
        here.</p></note>

      </div2>
    </div1>

<div1 id="soapfeatspec">
  <head>A Convention for Describing Features and Bindings</head>

<p>This section describes a convention describing Features (including
MEPs) and Bindings in terms of properties and property values. The
convention is sufficient to describe the distributed states of Feature
and Binding specifications as mandated by the Binding Framework (see
SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="&dated-part1;/#transpbindframew">SOAP Protocol Binding
Framework</xspecref>) and it is used to describe a Request-Response MEP (see <specref
ref="singlereqrespmep"/>),  a Response MEP (see <specref
ref='soapresmep' />), the SOAP Web Method feature (see <specref
ref='WebMethodFeature' />) and the SOAP HTTP Binding (see <specref
ref="soapinhttp"/>) elsewhere in this document. Along with the convention
itself, an informal model is defined that describes how properties
propagate through a SOAP system. Note that this model is intended to be
illustrative only, and is not meant to imply any constraints on the
structure or layering of any particular SOAP implementation.</p>

<div2 id="modprop"><head>Model and Properties</head>

<p>In general, a SOAP message is the information that one SOAP node wishes to
exchange with another SOAP node according to a particular set of features,
including a MEP. In addition, there may be information essential to exchanging
a message that is not part of the message itself. Such information is sometimes
called message metadata. In the model, the message, any message metadata,
and the various information items that enable features are represented as
abstractions called properties.</p>

<div3 id="bindprops"><head>Properties</head>

<p>Under the convention, properties are represented as follows:</p>

<ulist>
    <item><p>Properties are named with URIs.</p></item>

    <item><p>Where appropriate, property values SHOULD have
    an XML Schema <bibref ref="XMLSchemaP1"/> <bibref
    ref="XMLSchemaP2"/> type listed in the specification which
    introduces the property.</p></item>
</ulist>

</div3>

<div3 id="bindpropsscope"><head>Property Scope</head>

<p>Properties within a SOAP node differ in terms of their scope and the
origins of their values. As shown in the figure below, we make the
distinction between per-message-exchange properties and more widely scoped
properties by assigning them to different containers called Message
Exchange Context and Environment Context respectively. All properties,
regardless of their scope, are shared by a SOAP node and a particular
Binding.</p>

<graphic xmlns:xlink="http://www.w3.org/1999/xlink" 
xlink:type="simple" id="soapframepropfig" source="xmlp-framework-props.png"
xlink:show="embed" xlink:actuate="onLoad" 
alt="Model describing properties shared between SOAP and Binding">
  <caption>Model describing properties shared between SOAP and Binding</caption>
</graphic>

<div4 id="soapmec"><head>Message Exchange Context</head>

<p>A message exchange context is a collection of properties whose scope is
limited to an instance of a given message exchange pattern. An example
of a message exchange context property is the identifier of the message
exchange pattern in use.</p>

</div4>



<div4 id="soapenvc"><head>Environment Context</head>

<p>The Environment Context is a collection of properties whose scope
extends beyond an instance of a given message exchange pattern.
Examples of Environment Context properties are the IP address of the
SOAP node or the current date and time.</p>

<p>The values of properties in Environment Context may depend upon local
circumstances (as depicted by the external arrow from Environment Context in
the figure above). More specifically, the properties in the example
could be influenced by an operating system user ID on whose behalf a
message exchange is being executed. The mapping of information in a
particular implementation to such properties is outside the scope of
the binding framework although the abstract representation of such
information as properties is not.</p>

</div4>

</div3>

<div3 id="bindpropfeat"><head>Properties and Features</head>

<p>A feature may be expressed through multiple properties and a single property
may enable more than one feature. For example, the properties called User ID and
Password may be used to enable a feature called Authentication. As a second example,
a single property called Message ID could be used to enable one feature called
Transaction and a second feature called Message Correlation.</p>

</div3>

</div2>

</div1>

    <div1 id="soapsupmep"><head>SOAP-Supplied Message Exchange Patterns and Features</head>
    
      <div2 id="meppropconv"><head>Property Conventions for SOAP Message Exchange Patterns</head>

       <p><specref ref="tabmeppropdefs"/> describes the properties
       (in accordance with the property naming conventions
       defined in this document) that support the description of
       message exchange patterns (MEPs). Other properties may
       be involved in the specification of particular MEPs,
       but the properties in this table are generally applicable to all MEPs.</p>

        <table border="1" id="tabmeppropdefs">
          <caption>Property definitions supporting the description of MEPs</caption>
          <tbody>
	    <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw>The name
		of the MEP in
		operation.  
              </td>
	    </tr>
	    <tr>
	      <td>
                 <kw>Type:</kw> xs:anyURI
              </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>
	    <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> A value that denotes a pattern-specific, 
	       binding-independent reason for the failure of a message 
	       exchange. Underlying protocol binding specifications
		may define properties to convey more binding-specific
		details of the failure. 
              </td>
	    </tr>
	    <tr>
	      <td>
                 <kw>Type:</kw> xs:anyURI
              </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>
	    <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw>The identifier of the pattern-specific role of the
		  local SOAP node participating in the message
		  exchange.
              </td>
	    </tr>
	    <tr>
	      <td>
                 <kw>Type:</kw> xs:anyURI
              </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr><tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/State</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> The identifier of the current state of the message
		  exchange. This value is managed by the binding
		  instance and may be inspected by other entities
		  monitoring the progress of the message
		  exchange.
              </td>
	    </tr>
	    <tr>
	      <td>
                 <kw>Type:</kw> xs:anyURI
              </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>
	  </tbody>
        </table>

      </div2>

      <div2 id="singlereqrespmep">
        <head>SOAP Request-Response Message Exchange Pattern</head>

	<p>This section defines the message exchange pattern (MEP) called "Request-Response". The
	  description is an abstract presentation of the operation of
	  this MEP. It is not intended to describe a real
	  implementation or to suggest how a real implementation should
	  be structured.</p>

	<div3 id="mepname"> <head>SOAP Feature Name</head>

       <p>This message exchange pattern is identified by
	  the URI (see SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
	  xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="&dated-part1;/#procsoapmsgs">SOAP Features</xspecref>):</p>
	  <ulist><item><p><attval>http://www.w3.org/2003/05/soap/mep/request-response/</attval></p></item></ulist>
    
    </div3>
         
         <div3 id="bindinfdesc">
           <head>Description</head>

	  <p>The SOAP Request-Response MEP defines a
	    pattern for the exchange of a SOAP message acting as a
	    request followed by a message acting as a response.
            The response message MAY contain a SOAP envelope,
            or else the response MUST be a binding-specific
            message indicating that the request has been received.
            In the absence of failure in the underlying
	    protocol, this MEP consists of exactly two 
	    messages.</p>

       <p>In the normal operation of a message exchange conforming to
       the Request-Response MEP, a
       request message is first transferred from the requesting SOAP
       node to the responding SOAP node. Following the successful
       processing of the request message by the responding SOAP node,
       a response message is transferred from the responding
       SOAP node to the requesting SOAP node. </p>

       <p>Abnormal operation during a Request-Response message exchange
       might be caused by a failure to transfer the request message, a
       failure at the responding SOAP node to process the request
       message, or a failure to transfer the response message. Such
       failures might be silent at either or both of the requesting and
       responding SOAP nodes involved, or might result in the generation of a SOAP 
       or binding-specific fault (see <specref ref="bindfaulthdn"/>).
       Also, during abnormal operation
       each SOAP node involved in the message exchange might differ in
       its determination of the successful completion of the message
       exchange. </p>
       
       <p>The scope of a Request-Response MEP is limited to
       the exchange of a request message and a response message between
       one requesting and one responding SOAP node. This pattern does
       not mandate any correlation between multiple requests nor
       specific timing for multiple requests. Implementations MAY choose
       to support multiple ongoing requests (and associated response
       processing) at the same time.</p>
				</div3>
    <div3 id="bindformdesc">
      <head>State Machine Description</head>

	  <p>The Request-Response MEP defines a set of properties described in <specref ref="tabreqresprops"/>.</p>

<table border="1" id="tabreqresprops">
	    <caption>Property definitions for Request-Response MEP</caption>
	    <tbody>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att>
</td>
</tr>
<tr>
<td><kw>Value: </kw>An abstract structure that represents the current
		  outbound message in the message exchange. This
		  abstracts both SOAP Envelope and any other
		  information structures that are transferred along
		  with the envelope.</td>
</tr>
<tr>
<td><kw>Type: </kw>Not specified</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/mep/InboundMessage</att>
</td>
</tr>
<tr>
<td><kw>Value: </kw>An abstract structure that represents the current
		  inbound message in the message exchange. This
		  abstracts both SOAP Envelope and any other
		  information structures that are transferred along
		  with the envelope.</td>
</tr>
<tr>
<td><kw>Type: </kw>Not specified</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att>
</td>
</tr>
<tr>
<td><kw>Value: </kw>The identifier of the immediate destination of an
		  outbound message.</td>
</tr>
<tr>
<td><kw>Type: </kw>xs:anyURI</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/mep/ImmediateSender</att>
</td>
</tr>
<tr>
<td><kw>Value: </kw>The identifier of the immediate sender of an inbound
		  message.</td>
</tr>
<tr>
<td><kw>Type: </kw>xs:anyURI</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
</tbody>
</table>

	  <p>To initiate a message exchange conforming to the
	  Request-Response MEP, the requesting SOAP node instantiates a
	  local message exchange context. <specref ref="tabreqcon"/> describes how
	  the context is initialized.</p>

        <table border="1" id="tabreqcon">
          <caption>Instantiation of a Message Exchange Context
              for a requesting SOAP node</caption>
          <tbody>
	    <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> <attval>http://www.w3.org/2003/05/soap/mep/request-response/</attval></td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>
           <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> <attval>None</attval></td>
	    </tr>
	    <tr>
	      <td>
                 <kw>Notes:</kw> A relative URI whose 
      base URI is the value of the property named
<att><span class="squeezeBigLiterals">http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</span></att>
              </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>
           <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> <attval>RequestingSOAPNode</attval></td>
	    </tr>
	    <tr>
	      <td>
                 <kw>Notes:</kw>  A relative URI whose 
      base URI is the value of the property named
<att><span class="squeezeBigLiterals">http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</span></att>
              </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>

           <tr>
	    <td>
            <innerTable border="1"> 
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/State</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> <attval>Init</attval></td>
	    </tr>
	    <tr>
	      <td>
                 <kw>Notes:</kw> A relative URI whose base URI is the value of the property named
<att><span class="squeezeBigLiterals">http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/Role</span></att>
              </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>
           <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/mep/OutboundMessage</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> An abstraction of the request message </td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>
           <tr>
	    <td>
            <innerTable border="1">
	    <tbody>
	    <tr>
	      <td>
                 <kw>Property name:</kw> <att><span class="squeezeBigLiterals">http://www.w3.org/2003/05/soap/mep/ImmediateDestination</span></att>
              </td>
	    </tr>
	    <tr>
	      <td>
               <kw>Value:</kw> An identifier (URI) that denotes the responding SOAP node</td>
	    </tr>
	    </tbody>
            </innerTable>
           </td>
           </tr>

	  </tbody>
        </table>
         
           <p>There may be other properties related to the operation of
           the message exchange context instance. Such properties are
           initialized according to their own feature specifications.
           </p>

           <p>Once the message exchange context is initialized, control
           of the context is passed to a (conforming) local binding
           instance. </p>

           <p>The diagram below shows the logical state transitions at
           the requesting and responding SOAP nodes during the lifetime
           of the message exchange. At each SOAP node, the local binding
           instance updates (logically) the value of the
           <att>http://www.w3.org/2003/05/soap/bindingFramework/
           ExchangeContext/State</att> property to reflect the current
           state of the message exchange. The state names are relative
           URIs, relative to a base URI value carried in the
           <att>http://www.w3.org/2003/05/soap/bindingFramework/
           ExchangeContext/Role</att> property of the local message
           exchange context.</p>

	   <graphic xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
	   source="StateTransitions.png" xlink:show="embed" xlink:actuate="onLoad"
	   alt="Request-Response MEP State Transition Diagram.">
	     <caption>Request-Response MEP State Transition Diagram.</caption>
	   </graphic>

           <p>When the local binding instance at the responding SOAP
           node starts to receive an inbound request message, it
           (logically) instantiates a message exchange context. <specref ref="tabrescon"/>
           describes the properties that the binding initializes as
           part of the context's instantiation.</p>
           	  
<table border="1" id="tabrescon">
          <caption>Instantiation of Message Exchange Context for
             an inbound request message at a responding SOAP node</caption>
          <tbody>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
</td>
</tr>
<tr>
<td>
<kw>Value: </kw><attval>http://www.w3.org/2003/05/soap/mep/request-response/</attval>
               </td>
</tr>
<tr>
<td><kw>Notes: </kw>Initialized as early as possible during the life cycle
              of the message exchange.</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att>
</td>
</tr>
<tr>
<td>
<kw>Value: </kw><attval>None</attval>
</td>
</tr>
<tr>
<td><kw>Notes: </kw>A relative URI whose base URI is the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td><kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role</att>
</td>
</tr>
<tr>
<td>
<kw>Value: </kw><attval>RespondingSOAPNode</attval>
              </td>
</tr>
<tr>
<td>
<kw>Notes: </kw>A relative URI whose base URI is the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>.
Initialized as early as possible during the life cycle the message exchange.
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw><att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/State</att>
</td>
</tr>
<tr>
<td>
<kw>Value: </kw><attval>Init</attval>
</td>
</tr>
<tr>
<td><kw>Notes: </kw>A relative URI whose base URI is the
value of  the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/Role</att>
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
</tbody>
</table>

	 <p>When the requesting and responding SOAP nodes transition between
	 states, the local binding instance (logically) updates a number of
	 properties. <specref ref="tabreqstatetrans"/> and <specref
	 ref="tabresstatetrans"/> describe these updates for the requesting
	 and the responding SOAP nodes, respectively.</p>
     
<table border="1" id="tabreqstatetrans">
<caption>Requesting SOAP Node State Transitions</caption>
<tbody>
<tr>
 <th>CurrentState</th>
 <th>&nbsp;</th>
</tr>
<tr>
 <td><attval>Init</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Unconditional</td></tr>
    <tr><td><kw>NextState: </kw><attval>Requesting</attval></td></tr>
    <tr><td><kw>Action: </kw>Initiate transmission of request message
		    abstracted in
		    <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Requesting</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message transmission failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
		      <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to
		      <attval>transmissionFailure</attval></td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Start receiving response message</td></tr>
    <tr><td><kw>NextState: </kw><attval>Sending+Receiving</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
		      <att>http://www.w3.org/2003/05/soap/mep/ImmediateSender</att> to denote the sender of the response message (may differ from the values in <att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att>).
		      Start making an abstraction of the response message available in <att>http://www.w3.org/2003/05/soap/mep/InboundMessage</att>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Sending+Receiving</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message exchange failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
		      <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to
		      <attval>exchangeFailure</attval></td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Completed sending request message. Completed receiving response message.</td></tr>
    <tr><td><kw>NextState: </kw><attval>Success</attval></td></tr>
    <tr><td><kw>Action: </kw>If a SOAP envelope is received in the response (I.e., in <att>http://www.w3.org/2003/05/soap/mep/InboundMessage</att>), then process it according to the SOAP processing model.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>
</tbody>
</table>

       <p>&nbsp;</p>

<table border="1" id="tabresstatetrans">
<caption>Responding SOAP Node State Transitions</caption>
<tbody>
<tr>
 <th>CurrentState</th>
 <th>&nbsp;</th>
</tr>
<tr>
 <td><attval>Init</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Start receiving request message</td></tr>
    <tr><td><kw>NextState: </kw><attval>Receiving</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
		      <att>http://www.w3.org/2003/05/soap/mep/ImmediateSender</att> to denote the sender of the request message (if determinable).
		      Start making an abstraction of the request message available in <att>http://www.w3.org/2003/05/soap/mep/InboundMessage</att>.
		      Pass control of message exchange context to SOAP processor.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Receiving</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message reception failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
		      <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to
		      <attval>receptionFailure</attval>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Start of response message available in <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att></td></tr>
    <tr><td><kw>NextState: </kw><attval>Receiving+Sending</attval></td></tr>
    <tr><td><kw>Action: </kw>Initiate transmission of response message.  If an envelope is provided in  abstracted in <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att> then include that in the response message.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Receiving+Sending</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message exchange failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to 
		      <attval>exchangeFailure</attval>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Completed receiving request message. Completed sending response message.</td></tr>
    <tr><td><kw>NextState: </kw><attval>Success</attval></td></tr>
<!--    <tr><td><kw>Action: </kw>&nbsp;</td></tr> -->
   </tbody>
  </innerTable>
 </td>
</tr>
</tbody>
</table>

	  <p>Bindings that implement this MEP
	  MAY provide for streaming of SOAP responses.
	  That is, responding SOAP nodes MAY begin transmission
	  of a SOAP response while a SOAP request is still being
	  received and processed. When SOAP nodes implement
	  bindings that support streaming, the following
	  rules apply:</p>

      <ulist>
        <item><p>All the rules in SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>
        <xspecref xmlns:xlink="http://www.w3.org/1999/xlink"
        xlink:type="simple" href="&dated-part1;/#bindfw">Binding
        Framework</xspecref> regarding streaming of individual SOAP
        messages MUST be obeyed for both request and response SOAP
        messages.</p></item>
        
        <item><p>When using streaming SOAP bindings, requesting SOAP nodes
        MUST avoid deadlock by accepting and if necessary processing
        SOAP response information while the SOAP request is being transmitted.</p>
        
        <note><p>Depending on the implementation used and the size of
        the messages involved, this rule MAY require that SOAP applications
        stream application-level response processing in parallel with request
        generation.</p></note>
        </item>
        
        <item><p>A requesting SOAP node MAY enter the <attval>Fail</attval> state,
        and thus abort transmission of the outbound SOAP request,
        based on information contained in an incoming streamed SOAP
        response.</p></item>

      </ulist>
      
         </div3>
         
         <div3 id="bindfaulthdn">
         
           <head>Fault Handling</head>
           
	  <p>During the operation of the Request-Response MEP, the
	    participating SOAP nodes may generate SOAP faults.</p>

           <p>If a SOAP fault is generated by the responding SOAP node
           while it is in the <attval>Receiving</attval> state, the SOAP
           fault is made available in <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att> and the
           state machine transitions to the <attval>Receiving+Sending</attval> state.</p>

           <p>This MEP makes no claims about the disposition or
           handling of SOAP faults generated by the requesting SOAP node
           during any processing of the response message that follows the
           <attval>Success</attval> state in the requesting SOAP node's state transition
           table (see <specref ref="tabreqstatetrans"/>).</p>
    
         </div3>
         
      </div2>

      
      <div2 id="soapresmep">
        
        <head>SOAP Response Message Exchange Pattern</head>
		
		<p>This section defines the message exchange pattern (MEP)
		called "SOAP Response". The description is an abstract
		presentation of the operation of this MEP. It is not intended to
		describe a real implementation or to suggest how a real
		implementation should be structured.</p>

        <div3 id="mepname2">
            <head>SOAP Feature Name</head>
	  <p>This message exchange pattern is identified by
	    the URI (see SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
	    xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
	    href="&dated-part1;/#procsoapmsgs">SOAP Features</xspecref>):</p>
            <ulist>
                <item>
                    <p>
                        <attval>http://www.w3.org/2003/05/soap/mep/soap-response/</attval>
                    </p>
                </item>
            </ulist>
        </div3>
        <div3 id="bindinfdesc2">
            <head>Description</head>

	  <p>The SOAP Response MEP defines a pattern for
	    the exchange of a non-SOAP message acting as a request
	    followed by a SOAP message acting as a response. In the
	    absence of failure in the underlying protocol, this MEP
	    consists of exactly two messages, only one of which is a
	    SOAP message:</p>

            <ulist>
                <item>
                    <p>A request  
transmitted in a binding-specific manner that does not include a SOAP envelope and hence does not
involve any SOAP processing by the receiving SOAP node.</p>
                </item>
                <item>
                    <p>A response message which contains a SOAP
envelope. The MEP is completed by the processing of the SOAP envelope
following the rules of the SOAP processing model (see
SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>, section
<xspecref xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:type="simple" href="&dated-part1;/#msgexchngmdl">SOAP Processing Model</xspecref>).
</p>
                </item>
            </ulist>
            <p>
Abnormal operation during a SOAP Response message exchange might be
caused by a failure to transfer the request message or the
response message. Such failures might be silent at either or both
of the requesting and responding SOAP nodes involved, or might
result in the generation of a SOAP or binding-specific fault (see
section <specref ref="bindfaulthdn2"/>). Also, during abnormal
operation each SOAP node involved in the message exchange might
differ in its determination of the successful completion of the
message exchange.
</p>

            <p>The scope of a SOAP Response MEP is limited to
the request for an exchange of a response message between
one requesting and one responding SOAP node. This pattern does
not mandate any correlation between multiple requests nor
specific timing for multiple requests. Implementations MAY choose
to support multiple ongoing requests (and associated response
processing) at the same time.</p>
            <note>
                <p>This MEP cannot be used in conjunction with features expressed as SOAP header blocks in the request because there is no SOAP envelope in which to carry them.</p>
            </note>


        </div3>

        <div3 id="bindformdesc2">
            <head>State Machine Description</head>
            <p>The SOAP Response MEP defines a set of properties described in <specref ref="tabreqresprops2"/>.</p>
            <table border="1" id="tabreqresprops2">
                <caption>Property definitions for SOAP Response MEP</caption>
                <tbody>
                    <tr>
                        <th>Property Name</th>
                        <th>Property Description</th>
                        <th>Property Type</th>
                    </tr>
                    <tr>
                        <td>
                            <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att>
                        </td>
                        <td>An abstract structure that represents the current
  outbound message in the message exchange. This
  abstracts both SOAP Envelope Infoset (which MAY be null) and any other
  information structures that are transferred along
  with the envelope.</td>
  <td>Not specified</td>
                    </tr>
                    <tr>
                        <td>
                            <att>http://www.w3.org/2003/05/soap/mep/InboundMessage</att>
                        </td>
                        <td>An abstract structure that represents the current
  inbound message in the message exchange. This
  abstracts both SOAP Envelope Infoset (which MAY be null) and any other
  information structures that are transferred along
  with the envelope.
                        </td>
                        <td>Not specified</td>
                    </tr>
                    <tr>
                        <td>
                            <att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att>
                        </td>
                        <td><p>The identifier of the immediate destination of an
  outbound message.</p></td>
  <td>xs:anyURI</td>
                    </tr>
                    <tr>
                        <td>
                            <att>http://www.w3.org/2003/05/soap/mep/ImmediateSender</att>
                        </td>
                        <td><p>The identifier of the immediate sender of an inbound
  message.</p></td>
  <td>xs:anyURI</td>
                    </tr>
                </tbody>
            </table>
            <p>To initiate a message exchange conforming to the
SOAP Response MEP, the requesting SOAP node instantiates a
local message exchange context. <specref ref="tabreqcon2"/> describes how
the context is initialized.</p>

            <table border="1" id="tabreqcon2">
                <caption>Instantiation of a Message Exchange Context
      for a requesting SOAP node</caption>
                <tbody>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
                            <attval>http://www.w3.org/2003/05/soap/mep/soap-response/</attval>
                        </td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
<attval>None</attval>
</td>
</tr>
<tr>
<td>
<kw>Notes: </kw>A relative URI that will be resolved against the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
<attval>RequestingSOAPNode</attval>
</td>
</tr>
<tr>
<td>
<kw>Notes: </kw>A relative URI that will be resolved against the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/State</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
<attval>Init</attval>
</td>
</tr>
<tr>
<td>
<kw>Notes: </kw>A relative URI whose base URI is the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/Role</att>
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>An abstraction of the request
                        message that does not include a SOAP
                        envelope infoset.</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>An identifier (URI) that denotes
                        the responding SOAP node </td>
</tr>

</tbody>
</innerTable>
</td>
</tr>
</tbody>
            </table>

            <p>There may be other properties related to the operation of
   the message exchange context instance. Such properties are
   initialized according to their own feature specifications.
   </p>
            <p>Once the message exchange context is initialized, control
   of the context is passed to a (conforming) local binding
   instance. </p>
            <p>The diagram below shows the logical state transitions at
   the requesting and responding SOAP nodes during the lifetime
   of the message exchange. At each SOAP node, the local binding
   instance updates (logically) the value of the
   <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/State</att> property to
   reflect the current state of the message exchange. The state names
   are relative URIs, relative to a Base URI value carried in
   the <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role</att> property of the local
   message exchange context.</p>
            <graphic xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
            source="StateTransitions2.png" xlink:show="embed" xlink:actuate="onLoad"
            alt="SOAP Response MEP State Transition Diagram.">
              <caption>SOAP Response MEP State Transition Diagram</caption>
            </graphic>
            <p>When the local binding instance at the responding SOAP
   node starts to receive an inbound request message, it
   (logically) instantiates a message exchange context. <specref ref="tabrescon2"/>
   describes the properties that the binding initializes as
   part of the context's instantiation.</p>

            <table border="1" id="tabrescon2">
                <caption>Instantiation of Message Exchange Context for
     an inbound request message</caption>
                <tbody>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
                            <attval>http://www.w3.org/2003/05/soap/mep/soap-response/</attval>
</td>
</tr>
<tr>
<td>
<kw>Notes: </kw>
                            Initialized as early as possible during the life cycle of the message exchange. </td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
<attval>None</attval>
</td>
</tr>
<tr>
<td>
<kw>Notes: </kw>A relative URI that will be resolved against the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
<attval>RespondingSOAPNode</attval>
</td>
</tr>
<tr>
<td>
<kw>Notes: </kw>
A relative URI that will be resolved against the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>.
Initialized as early as possible during the life cycle the message exchange.
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
<tr>
<td>
<innerTable>
<tbody>
<tr>
<td>
<kw>Property name: </kw>
                            <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/State</att>
                        </td>
</tr>
<tr>
<td>
<kw>Value: </kw>
<attval>Init</attval>
</td>
</tr>
<tr>
<td>
<kw>Notes: </kw>A relative URI that will be resolved against the value of the property named <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/Role</att>
</td>
</tr>
</tbody>
</innerTable>
</td>
</tr>
</tbody>
            </table>

            <p>When the requesting and responding SOAP nodes transition between
states, the local binding instance (logically) updates a number of
properties. <specref ref="tabreqstatetrans2"/> and <specref ref="tabresstatetrans2"/> describe these updates for the requesting
and the responding SOAP nodes, respectively.</p>
<table border="1" id="tabreqstatetrans2">
<caption>Requesting SOAP Node State Transitions</caption>
<tbody>
<tr>
 <th>CurrentState</th>
 <th>&nbsp;</th>
</tr>

<tr>
 <td><attval>Init</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Unconditional</td></tr>
    <tr><td><kw>NextState: </kw><attval>Requesting</attval></td></tr>
    <tr><td><kw>Action: </kw>Initiate request</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Requesting</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message transmission failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
      <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to
      <attval>transmissionFailure</attval></td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Start receiving response message</td></tr>
    <tr><td><kw>NextState: </kw><attval>Receiving</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
      <att>http://www.w3.org/2003/05/soap/mep/ImmediateSender</att> to denote the sender of the response message
      (may differ from the values in <att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att>).
      Start making an abstraction of the response message available in
      <att>http://www.w3.org/2003/05/soap/mep/InboundMessage</att>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Receiving</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message exchange failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
      <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to
      <attval>exchangeFailure</attval></td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Completed receiving response message.</td></tr>
    <tr><td><kw>NextState: </kw><attval>Success</attval></td></tr>
<!--    <tr><td><kw>Action: </kw>&nbsp;</td></tr> -->
   </tbody>
  </innerTable>
 </td>
</tr>
</tbody>
</table>
            <p>&nbsp;</p>

<table border="1" id="tabresstatetrans2">
<caption>Responding SOAP Node State Transitions</caption>
<tbody>
<tr>
 <th>CurrentState</th>
 <th>&nbsp;</th>
</tr>

<tr>
 <td><attval>Init</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Start receiving request</td></tr>
    <tr><td><kw>NextState: </kw><attval>Receiving</attval></td></tr>
    <tr><td><kw>Action: </kw>Set <att>http://www.w3.org/2003/05/soap/mep/ImmediateSender</att>
      to denote the sender of the request message (if determinable). Pass control of message exchange context to SOAP processor.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Receiving</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message reception failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set
      <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to
      <attval>receptionFailure</attval>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Start of response message available in
                        <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att></td></tr>
    <tr><td><kw>NextState: </kw><attval>Sending</attval></td></tr>
    <tr><td><kw>Action: </kw>Initiate transmission of response message abstracted in
                        <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td rowspan="2"><attval>Sending</attval></td>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Message exchange failure</td></tr>
    <tr><td><kw>NextState: </kw><attval>Fail</attval></td></tr>
    <tr><td><kw>Action: </kw>Set <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/FailureReason</att> to 
      <attval>exchangeFailure</attval>.</td></tr>
   </tbody>
  </innerTable>
 </td>
</tr>

<tr>
 <td>
  <innerTable>
   <tbody>
    <tr><td><kw>Transition Condition: </kw>Completed sending response message.</td></tr>
    <tr><td><kw>NextState: </kw><attval>Success</attval></td></tr>
<!--    <tr><td><kw>Action: </kw>&nbsp;</td></tr> -->
   </tbody>
  </innerTable>
 </td>
</tr>
</tbody>
</table>
        </div3>
				<div3 id="bindfaulthdn2">
					<head>Fault Handling</head>
					<p>During the operation of the SOAP Response MEP, the
	    participating SOAP nodes may generate SOAP faults.</p>

					<p>If a SOAP fault is generated
					by the responding SOAP node while it is in the
					<attval>Receiving</attval> state, the SOAP fault is
					made available in
                        <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att>
					and the state machine transitions to the
					<attval>Sending</attval> state.</p>

					<p>This MEP makes no claims about the disposition or
           handling of SOAP faults generated by the requesting SOAP node
           during any processing of the response message that follows the
           <attval>Success</attval> state in the requesting SOAP node's state transition
           table (see <specref ref="tabreqstatetrans2"/>).</p>

				</div3>
			</div2>
                       <div2 id="WebMethodFeature">
                           <head>SOAP Web Method Feature</head>
                              <p>This section defines the "SOAP Web Method Feature".</p>
                               <div3 id="WebMethodFeatureName">
					<head>SOAP Feature Name</head>
	  <p>The SOAP Web Method feature is identified by the URI (see
	  SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
	  xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="&dated-part1;/#procsoapmsgs">SOAP Features</xspecref>):</p>
					<ulist>
						<item>
							<p>
								<attval>http://www.w3.org/2003/05/soap/features/web-method/</attval>
							</p>
						</item>
					</ulist>

				</div3>
                <div3 id="WebMethodFeatureDesc">
					<head>Description</head>

					
<p>
Underlying protocols designed for use on the World 
Wide Web provide for manipulation of resources using a small set of Web methods 
such as GET, PUT, POST, and DELETE.
These methods are formally defined in the HTTP specification <bibref ref="RFC2616"/>, but other underlying protocols might also support them. 
Bindings to HTTP or such other protocols SHOULD use the 
SOAP Web Method feature to give applications control over the Web methods to be used when sending a SOAP message.</p>

<p>Bindings supporting this feature SHOULD use the appropriate embodiment of that method if provided by the underlying protocol; for example, the HTTP binding
provided with this specification represents the <attval>GET</attval> Web method as an HTTP GET request, and the <attval>POST</attval> method
as an HTTP POST request (see <specref ref="soapinhttp"/>). Bindings supporting this feature SHOULD provide to the receiving node indication of the Web method used for transmission.</p>

<p>The SOAP Web Method feature MAY be implemented by bindings to underlying
transports that have no preferred embodiment of particular Web methods (e.g. do not distinguish GET from POST). Such bindings SHOULD provide to the receiving node indication of the Web method used for transmission, but need take no other action in support of the feature. </p>
					
				</div3>
<div3 id="webmethodstatemachine">
					<head>SOAP Web Method Feature State Machine </head>
					<p>The SOAP Web Method feature defines a single property, which is described in <specref ref="tabwebmethprops"/>.</p>
					<table border="1" id="tabwebmethprops">
						<caption>Property definition for the SOAP Web Method feature</caption>
						<tbody>
							<tr>
								<th>Property Name</th>
								<th>Property Description</th>
								<th>Property Type</th>
							</tr>
							<tr>
								<td>
									<att>http://www.w3.org/2003/05/soap/features/web-method/Method</att>
								</td>
								<td>One of <attval>GET</attval>, <attval>POST</attval>,
								    <attval>PUT</attval>, <attval>DELETE</attval> (or others which may subsequently be added to the repertoire
of Web methods.)</td>
<td>Not specified</td>
							</tr>
							
							
						</tbody>
					</table>
					<p>This specification provides for the use of the SOAP Web Method feature in conjunction with the
<specref ref="singlereqrespmep"/> and <specref ref="soapresmep"/> message exchange patterns. This
feature MAY be used with other MEPs if and only if provided for in the specifications of those MEPs.</p>
<p>
A node sending a request message MUST provide a value for the
<att>http://www.w3.org/2003/05/soap/features/web-method/Method</att> property. 
A protocol binding supporting this feature SHOULD set the value of the
<att>http://www.w3.org/2003/05/soap/features/web-method/Method</att> property at the receiving node to match that provided by the sender;
the means of
transmission for the method property is binding-specific.</p>

<p>A responding node SHOULD respond in a manner consistent with the Web method requested (e.g. a
<attval>GET</attval> should
result in retrieval of a representation of the identified resource) or SHOULD fault in an
application-specific manner if the Web method cannot be supported. </p>

<p>Bindings implementing this feature
  MUST employ a Message Exchange Pattern with semantics that are
  compatible with the Web method selected.  For example, the SOAP
  Response Message Exchange Pattern (see <specref ref='soapresmep'/>) is compatible with GET.</p>
		
				</div3>
             </div2>

                       <div2 id="ActionFeature">
                           <head>SOAP Action Feature</head>
                              <p>This section defines the "SOAP Action Feature".</p>
                               <div3 id="ActionFeatureName">
					<head>SOAP Feature Name</head>
	  <p>The SOAP Action feature is identified by the URI
	  (see SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
	  xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="&dated-part1;/#procsoapmsgs">SOAP Features</xspecref>):</p>
					<ulist>
						<item>
							<p>
								<attval>http://www.w3.org/2003/05/soap/features/action/</attval>
							</p>
						</item>
					</ulist>

				</div3>
                <div3 id="ActionFeatureDesc">
					<head>Description</head>

					
<p>
Many SOAP 1.2 underlying protocol bindings will likely
utilize the <attval>application/soap+xml</attval> media type (described in
<specref ref="ietf-draft"/>) to transmit XML serializations of SOAP messages.
The media type specifies an optional <att>action</att> parameter, which can be used to optimize dispatch or routing,
among other things. The Action Feature specifies well-known
URIs to indicate support for the <att>action</att> parameter in
bindings which use MIME, and also to refer to value of the
parameter itself.
</p>
					
				</div3>
<div3 id="actionstatemachine">
					<head>SOAP Action Feature State Machine </head>
					<p>The SOAP Action feature defines a single property, which is described in <specref ref="tabactionprops"/>. The value of this property MUST be an absolute URI<bibref ref="RFC3986"/> and MUST NOT be empty.</p>
					<table border="1" id="tabactionprops">
						<caption>Property definition for the SOAP Action feature</caption>
						<tbody>
							<tr>
								<th>Property Name</th>
								<th>Property Type</th>
							</tr>
							<tr>
								<td>
									<p><att>http://www.w3.org/2003/05/soap/features/action/Action</att></p>
								</td>
                                <td><p><att>xsd:anyURI</att></p></td>
							</tr>
							
							
						</tbody>
					</table>
					<p>If the <att>http://www.w3.org/2003/05/soap/features/action/Action</att>
					property has a value at a SOAP sender utilizing a
binding supporting this feature, the sender MUST use the
property value as the value of the <att>action</att> parameter in
the media type designator.</p>

<p>Conversely, if a value arrives in the <att>action</att> parameter of
the media type designator at a SOAP receiver, the receiver MUST
make that value available as the value of the <att>http://www.w3.org/2003/05/soap/features/action/Action</att>
property.</p>
		
				</div3>
             </div2>

                             
		</div1>

<div1 id="soapinhttp"><head>SOAP HTTP Binding</head>

  <div2 id="http-intro"><head>Introduction</head>
  
    <p>The SOAP HTTP Binding provides a binding of SOAP to HTTP. The
    binding conforms to the SOAP Protocol Binding Framework (see SOAP 1.2 Part 1 <bibref
    ref="SOAP-PART1"/> <xspecref
    xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="&dated-part1;/#transpbindframew">SOAP Protocol Binding
    Framework</xspecref>) and supports the message
    exchange patterns and features described in <specref ref="soapsupmep"/>.</p>

    <div3 id="httpoptionality">
    
      <head>Optionality</head>
	  
	  <p>The SOAP HTTP Binding is optional and SOAP nodes are NOT
	    required to implement it. A SOAP node that correctly and
	    completely implements the SOAP HTTP Binding may to be said
	    to "conform to the SOAP 1.2 HTTP Binding."</p>
	  
	  <p>The SOAP version 1.2 specification does not preclude
	    development of other bindings to HTTP or bindings to other
	    protocols, but communication with nodes using such other
	    bindings is not a goal. Note that other bindings of SOAP
	    to HTTP MAY be written to provide support for SOAP Message
	    exchange patterns other than <specref
	    ref="singlereqrespmep"/> or the <specref
	    ref="soapresmep"/>. Such alternate bindings MAY therefore
	    make use of HTTP features and status codes not required
	    for this binding. </p>
    
    </div3>    
    
    
    <div3 id="httpuse"><head>Use of HTTP</head>   
    
      <p>The SOAP HTTP binding defines a base URI according
      to the rules in HTTP/1.1 <bibref ref="RFC2616"/>. I.e., the base URI
      is the HTTP Request-URI or the value of the HTTP
      Content-Location header field.</p>
      
	  <p>This binding of SOAP to HTTP is intended to make
	    appropriate use of HTTP as an application protocol. For
	    example, successful responses are sent with status code
	    200 or 202, and failures are indicated as 4XX or 5XX. This
	    binding is not intended to fully exploit the features of
	    HTTP, but rather to use HTTP specifically for the purpose
	    of communicating with other SOAP nodes implementing the
	    same binding. Therefore, this HTTP binding for SOAP does
	    not specify the use and/or meaning of all possible HTTP
	    methods, header fields and status responses. It specifies
	    only those which are pertinent to the <specref
	    ref="singlereqrespmep"/> or the <specref
	    ref="soapresmep"/>, or which are likely to be introduced
	    by HTTP mechanisms (such as proxies) acting between the
	    SOAP nodes.</p>
    
	    <p>Certain
	    optional features provided by this binding depend on capabilities provided by
	    HTTP/1.1, for example content
	    negotiation. Implementations SHOULD thus use HTTP/1.1
	    <bibref ref="RFC2616"/> (or later compatible versions that share the
	    same major version number). Implementations MAY also be
	    deployed using HTTP/1.0, although in this case certain optional binding features
	    may not be provided.</p>

	    <note><p>SOAP HTTP Binding implementations need to account for the
	    fact that HTTP/1.0 intermediaries (which may or may
	    not also be SOAP intermediaries) may alter the representation of
	    SOAP messages, even in situations where both the initial SOAP sender and
	    ultimate SOAP receiver use HTTP/1.1.</p></note>

    
    </div3>
    
    
    <div3 id="httpinterop"><head>Interoperability with non-SOAP HTTP Implementations</head>
		<p>
		Particularly when used with the <specref ref="soapresmep"/>, the HTTP messages 
		produced by this binding are likely to be
		indistinguishable from those produced by non-SOAP implementations
		performing similar operations. 
		Accordingly, some degree of interoperation can be made possible between SOAP nodes and other HTTP
		implementations when using this binding.
		For example, a conventional Web server (i.e., one not
		written specifically to conform to this specification) might be used to respond
		to SOAP-initiated HTTP GET's with representations of
		<att>Content-Type</att> <attval>application/soap+xml</attval>.
		Such interoperation is not a normative feature of this specification.
		</p>
    
	  <p>Even though HTTP often is used on the
	    well-known TCP port 80, the use of HTTP is not limited to
	    that port. As a result, it is possible to have a dedicated
	    HTTP server for handling SOAP processing on a distinct TCP
	    port. Alternatively, it is possible to use a separate
	    virtual host for dealing with SOAP processing. Such
	    configuration, however, is a matter of convenience and is
	    not a requirement of this specification (see SOAP 1.2 Part 1 <bibref
	    ref="SOAP-PART1"/> <xspecref
	    xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
	    href="&dated-part1;/#secbindappspecprot">Binding to
	    Application-Specific Protocols</xspecref>).</p>
    </div3>
    
    
    <div3 id="httpmediatype"><head>HTTP Media-Type</head>
    <p>Conforming implementations of this binding:</p>
    
    <olist>
    
        <item><p>MUST be capable of sending and receiving messages
        serialized using media type <attval>application/soap+xml</attval> whose proper
        use and parameters are described in <specref ref="ietf-draft"/>.</p></item>

        <item><p>MAY send requests and responses using other media types
        providing that such media types provide for at least the
        transfer of SOAP XML Infoset.</p></item>
        
        <item><p>MAY, when sending requests, provide an HTTP Accept
        header field. This header field:</p>
        
            <ulist>
            
                <item><p>SHOULD indicate an ability to accept at minimum
                <attval>application/soap+xml</attval>.</p></item>

                <item><p>MAY additionally indicate willingness to accept
                other media types that satisfy 2 above.</p></item>
                
            </ulist>
            
        </item>
        
    </olist>

	</div3>

  </div2>

  <div2 id="http-bindname"><head>Binding Name</head>

	<p>This binding is identified by the URI (see
	  SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> <xspecref
	  xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="&dated-part1;/#transpbindframew">SOAP Protocol Binding
	  Framework</xspecref>):</p>
    
    <ulist>

      <item><p><attval>http://www.w3.org/2003/05/soap/bindings/HTTP/</attval></p>
      </item>

    </ulist>
    
  </div2>

  <div2 id="http-suptransmep"><head>Supported Message Exchange Patterns</head>

    <p>An implementation of the SOAP HTTP Binding
    MUST support the following message exchange
    patterns (MEPs):</p>
    
    <ulist>
      <item><p>  
      <attval>http://www.w3.org/2003/05/soap/mep/request-response/</attval> 
      (see <specref ref="singlereqrespmep"/>) </p></item>
					<item>
						<p>
							<attval>http://www.w3.org/2003/05/soap/mep/soap-response/</attval> 
      (see <specref ref="soapresmep"/>) </p>
					</item>
				</ulist>
			</div2>
<div2 id="http-suptfeatures">
				<head>Supported Features</head>
				<p>An implementation of the SOAP HTTP Binding
    MUST support the following additional features:</p>
				<ulist>
					<item>
						<p>
							<attval>http://www.w3.org/2003/05/soap/features/web-method/</attval> 
      (see <specref ref="WebMethodFeature"/>) </p>
					</item>
					
					<item>
					    <p>
					       <attval>http://www.w3.org/2003/05/soap/features/action/</attval>
      (see <specref ref="ActionFeature"/>) </p>
					</item>
    </ulist>
    
    <p>The possible values of
    <att>http://www.w3.org/2003/05/soap/features/web-method/Method</att>
    property are restricted in this HTTP binding according to the MEP
    in use (as present in
    <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>):</p>

        <table border="1" id="tabwebmethodvalues">
          <caption>Possible values of the Web-Method Method property</caption>
          <tbody>
            <tr>
              <th><att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</att></th>
              <th><att>http://www.w3.org/2003/05/soap/features/web-method/Method</att></th>
            </tr>
            <tr>
              <td><attval>http://www.w3.org/2003/05/soap/mep/request-response/</attval></td>
              <td><attval>POST</attval></td>
            </tr>
            <tr>
              <td><attval>http://www.w3.org/2003/05/soap/mep/soap-response/</attval></td>
              <td><attval>GET</attval></td>
            </tr>
         </tbody>
       </table>              

    <note><p>Other SOAP Version 1.2 bindings to HTTP may permit
    other combinations of
    <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/ExchangePatternName</att>
    and
    <att>http://www.w3.org/2003/05/soap/features/web-method/Method</att>.</p></note>


  </div2>

  <div2 id="http-msgexop"><head>MEP Operation</head>

    <p>For binding instances conforming to this specification:</p>
    
    <ulist>
    
      <item><p>A SOAP node instantiated at an HTTP client may assume the role (i.e., the 
      property <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/Role</att>) of 
      <attval>RequestingSOAPNode</attval>.</p></item>
      
      <item><p>A SOAP node instantiated at an HTTP server may assume the role (i.e., 
      the property <att>http://www.w3.org/2002/12/soap/bindingFramework/ExchangeContext/Role</att>) of 
      <attval>RespondingSOAPNode</attval>. </p></item>
      
    </ulist>
    
    <p>The remainder of this section describes the MEP state machine 
    and its relation to the HTTP protocol. In the state tables below, 
    the states are defined as values of the property <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/State</att>
    (see <specref ref="singlereqrespmep"/> and <specref ref='soapresmep'/>), and are of type <att>xs:anyURI</att>.
    For brevity, relative URIs are used, the base URI being the value of <att>http://www.w3.org/2003/05/soap/bindingFramework/ExchangeContext/Role</att>.</p>
    
    <p>The message exchange pattern in use is indicated by the HTTP method
used in the request. HTTP GET corresponds to the SOAP-Response MEP,
HTTP POST corresponds to the SOAP Request-Response MEP.</p>
      
	<div3 id="http-reqsoapnode">
					
	  <head>Behavior of Requesting SOAP Node</head>

	  <p>The overall flow of the behavior of a requesting SOAP node
	  follows a state machine description consistent with either <specref
	  ref="singlereqrespmep"/> or <specref ref="soapresmep"/>
	  (differences are indicated as necessary.) This binding supports
	  streaming and, as a result, requesting SOAP nodes MUST avoid
	  deadlock by accepting and if necessary processing SOAP response
	  information while the SOAP request is being transmitted (see
	  <specref ref="bindformdesc"/>). The following subsections describe
	  each state in detail.</p>

      <div4 id="http-reqbindreqstate"><head>Init</head>
      
      <p>In the <attval>Init</attval> state, a HTTP request is formulated according to <specref
      ref="tabreqstateinitfields"/> and transmission of the request is initiated.</p>


        <table border="1" id="tabreqstateinitfields">
          <caption>HTTP Request Fields</caption>
          <tbody>
            <tr>
            <th>Field</th>
            <th>Value</th></tr>
            <tr>
            <td>HTTP Method</td>
            <td>According to the <att>http://www.w3.org/2003/05/soap/features/web-method/Method</att> property. POST and GET are the only values supported by this binding.</td></tr>
            <tr>
            <td>Request URI</td>
            <td>The value of the URI carried in the  
              <att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att> property of the 
              message exchange context.</td></tr>
            <tr>
            <td><p>Content-Type header field</p></td>
            <td>The media type of the request entity body, if present; otherwise,
              omitted (see <specref ref="http-intro"/> for a description of permissible media types).
              If the SOAP envelope infoset in the <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att> property is null,
              then the <att>Content-Type</att> header field MAY be omitted.</td>
            </tr>
            <tr>
            <td><p>action parameter</p></td>
            <td><p>According to the value of the <att>http://www.w3.org/2003/05/soap/features/action/Action</att> property.</p></td>
            </tr>
            <tr>
            <td><p>Accept header field (optional)</p></td>
            <td>List of media types that are acceptable in 
            response to the request message.</td>
            </tr>
            <tr>
            <td><p>Additional header fields</p></td>
            <td><p>Generated in accordance with the rules for the binding-specific expression of any optional features in use for this
            message exchange. For example, a Content-Encoding header field
            (see HTTP <bibref ref="RFC2616"/>, section 14.11) may be used to
            express an optional compression feature.</p></td>
            </tr>
            <tr>
            <td>HTTP entity body</td>
            <td><p>SOAP message serialized according to the rules for
            carrying SOAP messages in the media type given by the
            Content-Type header field. Rules for carrying SOAP messages in
            media type <attval>application/soap+xml</attval> are given
            in <specref ref="ietf-draft"/>. If the SOAP envelope infoset in the
            <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att> property is null,
            the entity body is omitted</p></td>
            </tr>
          </tbody>
        </table>

      </div4>

      <div4 id="http-reqbindwaitstate">
        
        <head>Requesting</head>
              
        <p>In the <attval>Requesting</attval> state, sending
        of the request continues while waiting for the start of the
        response message. <specref ref="tabreqstatereqtrans"/> details
        the transitions that take place when a requesting SOAP node
        receives an HTTP status line and response header fields. For
        some status codes there is a choice of possible next state. In
        cases where <attval>Fail</attval> is one of the choices, the
        transition is dependent on whether a SOAP message is present in
        the HTTP response. If a SOAP message is present, the next state
        is <attval>Sending+Receiving</attval> or
        <attval>Receiving</attval>, otherwise the next state is
        <attval>Fail</attval>. The choice between
        <attval>Sending+Receiving</attval> and
        <attval>Receiving</attval> depends of the MEP in use:
        <attval>Sending+Receiving</attval> is the next state for Request-Response while
        <attval>Receiving</attval> is the next state for SOAP-Response.</p>

<table border="1" id="tabreqstatereqtrans">
  <caption>HTTP status code dependent transitions</caption>
  <tbody>
  <tr>
    <th valign="top">Status Code</th>
    <th valign="top">Reason phrase</th>
    <th valign="top">Significance/Action</th>
    <th valign="top">NextState</th></tr>
  <tr>
    <td valign="top">2xx</td>
    <td valign="top">Successful</td>
    <td valign="top">&nbsp;</td>
    <td valign="top">&nbsp;</td></tr>
  <tr>
    <td valign="top">200</td>
    <td valign="top">OK</td>
    <td valign="top">
      <p>The response message follows in the HTTP response entity body.
      Start making an abstraction of the response message available in
      <att>http://www.w3.org/2003/05/soap/mep/InboundMessage</att>.</p></td>
    <td valign="top"><attval>Sending+Receiving</attval> or <attval>Receiving</attval></td></tr>
   <tr>
    <td valign="top">202</td>
    <td valign="top">OK</td>
    <td valign="top">
      <p>        The request has been accepted, but either (a) no response envelope 
       is provided or (b) an envelope representing information related to 
       the request is provided -- such envelopes SHOULD be processed using 
       the SOAP Processing model (see
SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>, section
<xspecref xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:type="simple" href="&dated-part1;/#msgexchngmdl">SOAP Processing Model</xspecref>).</p></td>
    <td valign="top"><attval>Receiving</attval> (which will immediately transition to 
          <attval>Success</attval>)</td></tr>
 <tr>
    <td valign="top">301, 302, 307</td>
    <td valign="top">Redirect</td>
    <td valign="top"><p>The requested resource has 
      moved. In the case of unsafe HTTP method, like POST or PUT, explicit confirmation
      is required before proceeding as follow. </p>
      <p>In the case of a safe method, like GET, or if the redirection has been approved, 
      the HTTP request SHOULD be retried using the URI carried in the 
      associated Location header field as the new value for the  
      <att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att> property.</p></td>
    <td valign="top"><attval>Init</attval> or <attval>Fail</attval></td></tr>
  <tr>
    <td valign="top">303</td>
    <td valign="top">See Other</td>
    <td valign="top"><p>The requested resource has moved and the HTTP request SHOULD be 
	retried using the URI carried in the associated Location header field as the new
        value for the <att>http://www.w3.org/2003/05/soap/mep/ImmediateDestination</att>
        property. The value of 
        <att>http://www.w3.org/2003/05/soap/features/web-method/Method</att> is changed to
        "<attval>GET</attval>", the value of <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att> is 
        set to <attval>null</attval>. [Note: Status code 303 MUST NOT be sent unless the request 
        SOAP envelope has been processed according to the SOAP processing model 
        and the SOAP response is to be made available by retrieval from the URI
        provided with the 303.]</p></td>
    <td valign="top"><attval>Init</attval></td></tr>
  <tr>
    <td valign="top">4xx</td>
    <td valign="top">Client Error</td>
    <td valign="top">&nbsp;</td>
    <td valign="top">&nbsp;</td></tr>
  <tr>
    <td valign="top">400</td>
    <td valign="top">Bad Request</td>
    <td valign="top">
      <p>Indicates a problem with the received HTTP request message.</p></td>
    <td valign="top"><p><attval>Sending+Receiving</attval>, <attval>Receiving</attval> or <attval>Fail</attval></p></td></tr>
  <tr>
    <td valign="top">401</td>
    <td valign="top">Unauthorized</td>
    <td valign="top"><p>Indicates that the HTTP 
      request requires authorization.</p>
      <p>The message exchange is 
      regarded as having completed unsuccessfully.</p>
    </td>
    <td valign="top"> 
      <attval>Requesting</attval> or <attval>Fail</attval></td></tr>
  <tr>
    <td valign="top">405</td>
    <td valign="top">Method not allowed</td>
    <td valign="top">
      <p>Indicates that the peer HTTP server does not support the requested HTTP 
      method at the given request URI. The message exchange is 
      regarded as having completed unsuccessfully.</p></td>
    <td valign="top"><attval>Fail</attval></td></tr>
  <tr>
    <td valign="top">415</td>
    <td valign="top">Unsupported Media Type</td>
    <td valign="top">
      <p>Indicates that the peer HTTP server does not support the Content-type used 
      to encode the request message. The message exchange is regarded 
      as having completed unsuccessfully.</p></td>
    <td valign="top"> 
      <attval>Fail</attval></td></tr>
  <tr>
    <td valign="top">5xx</td>
    <td valign="top">Server Error</td>
    <td valign="top">&nbsp;</td>
    <td valign="top">&nbsp;</td></tr>
  <tr>
    <td valign="top">500</td>
    <td valign="top">Internal Server Error</td>
    <td valign="top">
      <p>Indicates a server problem or a problem with the received request</p></td>
    <td valign="top"> 
      <p><attval>Sending+Receiving</attval>, <attval>Receiving</attval> or <attval>Fail</attval></p></td></tr>
</tbody>
</table>

        <p><specref ref="tabreqstatereqtrans"/> refers to
        some but not all of the existing HTTP/1.1 <bibref
        ref="RFC2616"/> status codes. In addition to these status codes,
        HTTP provides an open-ended mechanism for supporting status
        codes defined by HTTP extensions (see RFC 2817 <bibref ref="RFC2817"/>
        for a registration mechanism for new status codes). HTTP status
        codes are divided into status code classes as described in
        HTTP <bibref ref="RFC2616"/>, section 6.1.1. The SOAP HTTP binding
        follows the rules of any HTTP application which means that an
        implementation of the SOAP HTTP binding must understand the
        class of any status code, as indicated by the first digit, and
        treat any unrecognized response as being equivalent to the x00
        status code of that class, with the exception that an
        unrecognized response must not be cached.</p>

    <note><p>There may be elements in the HTTP infrastructure
    configured to modify HTTP response entity bodies for
    4xx and 5xx status code responses. For example, some
    HTTP origin servers have such a feature as
    a configuration option. This behavior may interfere with
    the use of 4xx and 5xx status code responses carrying SOAP
    fault messages in HTTP and it is recommended that such behavior
    be disabled for resources accepting SOAP/HTTP requests.
    If the rewriting behavior cannot be disabled, SOAP/HTTP
    cannot be used in such configurations.</p></note>
    
</div4>

<div4 id="http-reqbindrecstate"><head>Sending+Receiving</head>
      
  <p>In the <attval>Sending+Receiving</attval> state
  (<specref ref="singlereqrespmep"/> only), the transmission of the
  request message and receiving of the response message is completed.
  Only in the case that a status code 200 is received, 
  the response message is assumed to contain a SOAP envelope serialized
  according to the rules for carrying SOAP messages in the media type
  given in the Content-Type header field.</p>

  <p>The response MAY be of content type other than
  <attval>application/soap+xml</attval>. Such usage is considered
  non-normative, and accordingly is not modeled in the state machine.
  Interpretation of such responses is at the discretion of the
  receiver.
  Similarly, receipt of any response entity-body with a status code of 202
  is not normative.  If such an unexpected response is of type 
  <attval>application/soap+xml</attval>, then SOAP processing of that
  response is beyond the scope of the specification for this binding.</p>

</div4>

<div4 id="http-reqbindrecstate2">

    <head>Receiving</head>
    
    <p>In the <attval>Receiving</attval> state (<specref
    ref="soapresmep"/> only), receiving of the response message is
    completed. Only in the case of status code 200, 
    the response message is assumed to contain a SOAP
    envelope serialized according to the rules for carrying SOAP
    messages in the media type given in the Content-Type header
    field.</p>

    <p>The response MAY be of content type other than
    <attval>application/soap+xml</attval>. Such a result is particularly
    likely when a SOAP request sent with a <att>http://www.w3.org/2003/05/soap/features/web-method/Method</att> of
    <attval>GET</attval> is directed (intentionally or otherwise) to a
    non-SOAP HTTP server. Such usage is considered non-normative, and
    accordingly is not modeled in the state machine. Interpretation of
    such responses is at the discretion of the receiver.
    Similarly, receipt of any response entity-body with a status code of 202
  is not normative.  If such an unexpected response is of type 
  <attval>application/soap+xml</attval>, then SOAP processing of that
  response is beyond the scope of the specification for this binding.</p>

</div4>


<div4 id="http-reqsuccfail"><head>Success and Fail</head>

<p><attval>Success</attval> and <attval>Fail</attval> are the terminal states of the 
Request-Response and SOAP-Response MEPs. Control over the  
message exchange context returns to the local SOAP node.</p>

<p>If the "success" state has been reached and if a SOAP envelope has been 
received, then the local node is a SOAP Receiver as defined in SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/> section
<xspecref xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:type="simple" href="&dated-part1;/#senderreceiverconcepts">Message Sender and Receiver Concepts</xspecref>, and in particular MUST obey the 
requirement of section
<xspecref xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:type="simple" href="&dated-part1;/#soapnodes">SOAP Nodes</xspecref> to 
process the message according to the SOAP Processing Model (see <xspecref xmlns:xlink="http://www.w3.org/1999/xlink"
xlink:type="simple" href="&dated-part1;/#msgexchngmdl">SOAP Processing Model</xspecref>).</p>

</div4>

</div3>

<div3 id="http-bindrespnode"><head>Behavior of Responding SOAP Node</head>

<p>The overall flow of the behavior of a responding SOAP node
      follows a state machine description consistent with either <specref ref="singlereqrespmep"/> or
<specref ref="soapresmep"/> (differences are indicated as necessary). The following subsections describe each state
in detail.</p>

<div4 id="http-respbindreceive"><head>Init</head>

<p>In the <attval>Init</attval> state, the binding waits for
the start of an inbound request message. <specref
ref='tabresstateinitfaults'/> describes the errors that a responding
SOAP node might generate while in the <attval>Init</attval> state. In
this state no SOAP message has been received, therefore the SOAP node
cannot generate a SOAP fault.</p>

<table border="1" id="tabresstateinitfaults">
  <caption>Errors generated in the Init state</caption>
  <tbody>
  <tr>
    <th valign="top">Problem with Message</th>
    <th valign="top">HTTP Status Code</th>
    <th valign="top">HTTP Reason Phrase 
      (informative)</th>
  </tr>
  <tr>
    <td valign="top">Malformed Request Message</td>
    <td valign="top">400</td>
    <td valign="top">Bad request</td>
  </tr>
  <tr>
    <td valign="top">HTTP Method is neither POST nor GET</td>
    <td valign="top">405</td>
    <td valign="top">Method Not Allowed</td>
  </tr>
  <tr>
    <td valign="top">Unsupported message encapsulation method</td>
    <td valign="top">415</td>
    <td valign="top">Unsupported Media</td>
  </tr>
  </tbody>
</table>

</div4>

<div4 id="http-respbindprocess"><head>Receiving</head>

<p>In the <attval>Receiving</attval> state, the binding
receives the request and any associated message and waits for the
start of a response message to be available. <specref
ref="tabresstaterecheads"/> describes the HTTP response header fields
generated by the responding SOAP node. <specref
ref="tabresstatereccodes"/> describes the HTTP status codes associated
with SOAP faults that can be generated by the responding SOAP node.</p>

<table border="1" id="tabresstaterecheads">
  <caption>HTTP Response Headers Fields</caption>
  <tbody>
  <tr>
    <th>Field</th>
    <th>Value</th></tr>
  <tr>
    <td>Status line</td>
    <td><p>If a SOAP Envelope response is available in <att>http://www.w3.org/2003/05/soap/mep/OutboundMessage</att> then 200, or set according to <specref ref='tabresstatereccodes'/> if a SOAP
    fault was generated.  Otherwise, if no such SOAP envelope is provided, then 202.</p></td></tr>
  <tr>
    <td><p>Content-Type header field</p></td>
    <td><p>If Status line is 200, then the media type of the response body, see <specref
    ref="http-intro"/> for a description of permissible media
    types.  If status line is other than 200, then the Content-Type header is not sent.</p></td>
  </tr>
  <tr>
    <td><p>Additional header fields</p></td>
    <td><p>Generated in accordance with the rules for the binding-specific
    expression of any optional features in use for this message
    exchange. For example, a Content-Encoding header field (see HTTP <bibref
    ref="RFC2616"/>, section 14.11) may be used to express an optional
    compression feature.</p></td>
  </tr>
  <tr>
    <td>HTTP Entity Body</td>
    <td><p>Only if status line is 200, the SOAP message serialized according to the rules for carrying SOAP
    messages in the media type given by the Content-Type header field. Rules
    for carrying SOAP messages in <attval>application/soap+xml</attval> are
    given in <specref ref="ietf-draft"/>.</p></td>
</tr>
</tbody></table>
       <p>&nbsp;</p>

<table border="1" id="tabresstatereccodes">
  <caption>SOAP Fault to HTTP Status Mapping</caption>
  <tbody>
  <tr>
    <th>SOAP Fault</th>
    <th>HTTP Status Code</th>
    <th>HTTP Reason Phrase (informative)</th></tr>
  <tr>
    <td>env:VersionMismatch</td>
    <td>500</td>
    <td>Internal server error</td></tr>
  <tr>
    <td>env:MustUnderstand</td>
    <td>500</td>
    <td>Internal server error</td></tr>
  <tr>
    <td>env:Sender</td>
    <td>400</td>
    <td>Bad request</td></tr>
  <tr>
    <td>env:Receiver</td>
    <td>500</td>
    <td>Internal server error</td></tr>
  <tr>
    <td>env:DataEncodingUnknown</td>
    <td>500</td>
    <td>Internal server error</td></tr> 
  </tbody></table>
</div4>
     
<div4 id="http-respbindrespond"><head>Receiving+Sending</head>

<p>In the <attval>Receiving+Sending</attval> state (<specref
ref="singlereqrespmep"/> only) the binding completes receiving of the
request message and transmission of the response message.</p>
</div4>

<div4 id="http-respbindrespond2"><head>Sending</head>

<p>In the <attval>Sending</attval> state (<specref
ref="soapresmep"/> only) the binding completes transmission of the response message.</p>
          
</div4>

<div4 id="http-respsuccfail"><head>Success and Fail</head>

<p><attval>Success</attval> and <attval>Fail</attval> are the terminal states for the 
Request-Response and SOAP-Response MEPs. From the point-of-view of 
the local node this message exchange has completed.</p>

</div4>

</div3>

</div2>


<div2 id='seccond'><head>Security Considerations</head>

<p>The SOAP
      HTTP Binding (see <specref ref="soapinhttp" />) can be considered as
      an extension of the HTTP application protocol. As such, all of the
      security considerations identified and described in section 15 of
      the HTTP specification <bibref ref="RFC2616"/>
      apply to the SOAP HTTP Binding in
      addition to those described in SOAP 1.2 Part 1 <bibref ref="SOAP-PART1"/>
      <xspecref xmlns:xlink="http://www.w3.org/1999/xlink"
      xlink:type="simple" href="&dated-part1;/#secconsiderations">Security Considerations</xspecref>.
      Implementors of the SOAP HTTP Binding should
      carefully review this material.</p>
      
</div2>

</div1>



	

    <div1 id="refs">
      <head>References</head>

      <div2 id="refs-norm">
	<head>Normative References</head>

        <blist>

   <bibl key="SOAP Part 1" 
        id="SOAP-PART1">
	<titleref href="&dated-part1;">&name-part1;</titleref>, 
	Martin Gudgin, Marc Hadley, Noah Mendelsohn, Jean-Jacques Moreau,
	Henrik Frystyk Nielsen, Anish Karmarkar, Yves Lafon, Editors.
	World Wide Web Consortium, &draft.day; &draft.month; &draft.year;.
	This version is &dated-part1;.
	The <a href="http://www.w3.org/TR/soap12-part1/">latest version</a> is
	available at http://www.w3.org/TR/soap12-part1/.</bibl>

    <bibl key="RFC 2616" 
	id="RFC2616">
	<titleref href="http://www.ietf.org/rfc/rfc2616.txt">Hypertext 
	Transfer Protocol -- HTTP/1.1</titleref>, R. Fielding,
 	J. Gettys, J. C. Mogul, H. Frystyk Nielsen, P. Leach, 
	L. Masinter and T. Berners-Lee,
	Editors.
	IETF, June 1999. 
	This RFC is available at http://www.ietf.org/rfc/rfc2616.txt.</bibl>

    <bibl key="RFC 2119" 
	id="RFC2119">
	<titleref href="http://www.ietf.org/rfc/rfc2119.txt">Key words for 
	use in RFCs to Indicate Requirement Levels</titleref>, S. Bradner, 
	Editor.
	IETF, March 1997.
	This RFC is available at http://www.ietf.org/rfc/rfc2119.txt.</bibl>

    <bibl key="XML Schema Part 1" 
        id="XMLSchemaP1">
        <titleref href="http://www.w3.org/TR/2004/REC-xmlschema-1-20041028/">
	XML Schema Part 1: 
	Structures Second Edition</titleref>, David Beech, Murray Maloney, 
	Henry S. Thompson, and Noah Mendelsohn, Editors. 
	World Wide Web Consortium, 28 October 2004. 
	This version is http://www.w3.org/TR/2004/REC-xmlschema-1-20041028/
	The <a href="http://www.w3.org/TR/xmlschema-1/">latest version</a> is
	available at http://www.w3.org/TR/xmlschema-1/.</bibl>

    <bibl key="XML Schema Part 2" 
        id="XMLSchemaP2">
	<titleref href="http://www.w3.org/TR/2004/REC-xmlschema-2-20041028/">
	XML Schema Part 2:
	Datatypes Second Edition</titleref>, 
	Ashok Malhotra and Paul V. Biron, Editors. 
	World Wide Web Consortium, 28 October 2004. 
	This version is http://www.w3.org/TR/2004/REC-xmlschema-2-20041028/. 
	The <a href="http://www.w3.org/TR/xmlschema-2/">latest version</a> is
	available at http://www.w3.org/TR/xmlschema-2/.</bibl>

    <bibl key="RFC 3986" 
	id="RFC3986">
	<titleref href="http://www.ietf.org/rfc/rfc3986.txt">Uniform Resource 
	Identifiers (URI): Generic Syntax</titleref>, T. Berners-Lee, 
	R. Fielding and L. Masinter, Editors.
	IETF, January 2005. 
	<emph>Obsoletes: <span id="RFC2396">RFC 2396</span>, 
	<span id="RFC2732">RFC 2732</span></emph>.
	This RFC is available at http://www.ietf.org/rfc/rfc3986.txt.</bibl>

    <bibl key="Namespaces in XML" 
        id="XMLNS">
	<titleref href="http://www.w3.org/TR/2006/REC-xml-names-20060816">
	Namespaces in
	XML (Second Edition)</titleref>, Tim Bray, Dave Hollander, 
        Andrew Layman, and Richard Tobin, Editors. 
	World Wide Web Consortium, 16 August 2006. 
	This version is http://www.w3.org/TR/2006/REC-xml-names-20060816.
	The <a href="http://www.w3.org/TR/REC-xml-names">latest version</a> is
	available at http://www.w3.org/TR/REC-xml-names.</bibl>

    <bibl key="XML 1.0" 
        id="XML">
	<titleref href="http://www.w3.org/TR/2006/REC-xml-20060816">Extensible
	Markup Language (XML) 1.0 (Fourth Edition)</titleref>, Jean Paoli,
	Eve Maler, Tim Bray, <emph>et. al.</emph>, Editors. 
	World Wide Web Consortium, 16 August 2006. 
	This version is http://www.w3.org/TR/2006/REC-xml-20060816. 
	The <a href="http://www.w3.org/TR/REC-xml">latest version</a> is
	available at http://www.w3.org/TR/REC-xml.</bibl>

    <bibl key="XML InfoSet" 
	id="XMLInfoSet">
	<titleref href="http://www.w3.org/TR/2004/REC-xml-infoset-20040204">XML
	Information Set (Second Edition)</titleref>, Richard Tobin and 
	John Cowan, Editors. 
	World Wide Web Consortium, 04 February 2004. 
	This version is http://www.w3.org/TR/2004/REC-xml-infoset-20040204. 
	The <a href="http://www.w3.org/TR/xml-infoset">latest version</a> is
	available at http://www.w3.org/TR/xml-infoset.</bibl>

    <bibl key="RFC 3023" 
	id="RFC3023">
	<titleref 
         href="http://www.ietf.org/rfc/rfc3023.txt">XML Media Types</titleref>
        M. Murata, S. St.Laurent, D. Kohn, Editors.
        IETF, January 2001.
	This RFC is available at http://www.ietf.org/rfc/rfc3023.txt.</bibl>
	
    <bibl key="RFC 3902" 
	id="soap-media-type">
	<titleref href="http://www.ietf.org/rfc/rfc3902.txt">
	The "application/soap+xml" media type</titleref>, M. Baker, 
	M. Nottingham, Editors.
	IETF, September 2004.
	This RFC is available at http://www.ietf.org/rfc/rfc3902.txt.</bibl>

        </blist>

      </div2>

      <div2 id="refs-inform">
 	<head>Informative References</head>

	<blist>
   <bibl key="SOAP 1.1"
        id="soap11">
	<titleref href="http://www.w3.org/TR/2000/NOTE-SOAP-20000508/">Simple Object
	Access Protocol (SOAP) 1.1</titleref>, 
	Don Box, David Ehnebuske, Gopal
	Kakivaya, Andrew Layman, Noah Mendelsohn, Henrik Nielsen,
	Satish Thatte, Dave Winer, Editors.
	DevelopMentor, IBM, Microsoft, Lotus Development Corp., 
        UserLand Software, Inc., 30 July 2003.
	This version is http://www.w3.org/TR/2000/NOTE-SOAP-20000508/.</bibl>

   <bibl key="SOAP Part 0" 
        id="SOAP-PART0">
	<titleref href="&dated-part0;">&name-part0;</titleref>, 
	Nilo Mitra, Yves Lafon, Editors. 
	World Wide Web Consortium, &draft.day; &draft.month; &draft.year;.
	This version is &dated-part0;.
	The <a href="http://www.w3.org/TR/soap12-part0/">latest version</a> is
	available at http://www.w3.org/TR/soap12-part0/.</bibl>


      <bibl key="XMLP Comments" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest" href="http://lists.w3.org/Archives/Public/xmlp-comments/" id="CommentArchive">XML Protocol Comments Archive</bibl>

	  <bibl key="XMLP Dist-App" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest" href="http://lists.w3.org/Archives/Public/xml-dist-app/" id="DiscussionArchive">XML Protocol Discussion
	    Archive</bibl>

	  <bibl key="XMLP Charter" xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" xlink:show="replace" xlink:actuate="onRequest" href="http://www.w3.org/2005/07/XML-Protocol-Charter" id="XMLPCharter">XML Protocol Charter</bibl>

        <bibl key="RFC 2045" 
	id="RFC2045">
	<titleref href="http://www.ietf.org/rfc/rfc2045.txt">
	Multipurpose Internet Mail Extensions (MIME) Part One:
        Format of Internet Message Bodies
	</titleref>, N. Freed, N. Borenstein, Editors.
	IETF, November 1996. 
	This RFC is available at http://www.ietf.org/rfc/rfc2045.txt.</bibl>

        <bibl key="RFC 2026" 
	id="RFC2026">
	<titleref href="http://www.ietf.org/rfc/rfc2026.txt">
	The Internet Standards Process -- Revision 3</titleref>, 
        S. Bradner, Editor.
	IETF, October 1996. 
	This RFC is available at http://www.ietf.org/rfc/rfc2026.txt.</bibl>

        <bibl key="RFC 2817" 
	id="RFC2817">
	<titleref href="http://www.ietf.org/rfc/rfc2817.txt">
	Upgrading to TLS Within HTTP/1.1</titleref>, 
        R. Khare, S. Lawrence, Editors.
	IETF, May 2000. 
	This RFC is available at http://www.ietf.org/rfc/rfc2817.txt.</bibl>

    <bibl key="RFC 3987" 
	id="RFC3987">
	<titleref href="http://www.ietf.org/rfc/rfc3987.txt">
	Internationalized Resource Identifiers (IRIs)
	</titleref>, 
	M. Duerst, Editors.
	IETF, January 2005. 
	This RFC is available at http://www.ietf.org/rfc/rfc3987.txt.</bibl>

   <bibl id="CharMod" key="CharMod">
	<titleref href="http://www.w3.org/TR/2005/REC-charmod-20050215/">
        Character Model for the World Wide Web 1.0: Fundamentals</titleref>, 
        Martin J. Dürst, François Yergeau, Richard Ishida, Misha Wolf, 
        Tex Texin, Editors. 
	World Wide Web Consortium, 15 February 2005.
	This version is http://www.w3.org/TR/2005/REC-charmod-20050215/.
	The <a href="http://www.w3.org/TR/charmod/">latest version</a> is 
	available at http://www.w3.org/TR/charmod/.</bibl>

	</blist>

      </div2>

    </div1>

  </body>




  <back>

    <div1 id="ietf-draft">
    <head>The <attval>application/soap+xml</attval> Media Type</head>
      
    <p>The original contents of this section have been superceded by RFC3902<bibref ref="soap-media-type"/>.</p>

	  </div1>
    
    
    
    <div1 id="namemap">
      <head>Mapping Application-Defined Names to XML Names</head>
      
	  <p>This appendix details an algorithm for taking an
	  application-defined name, such as the name of a variable or
	  field in a programming language, and mapping it to the Unicode
	  characters that are legal in the names of XML elements and
	  attributes as defined in Namespace in XML <bibref ref='XMLNS' /></p>
	  

      <scrap><head>Hex Digits</head><prod id="hexDigit"><lhs>hexDigit</lhs><rhs>[0-9A-F]</rhs></prod>
      </scrap>

	  <div2 id="namemap-rules">
      <head>Rules for Mapping Application-Defined Names to XML Names</head>

      <olist>

        <item><p>An XML Name has two parts: <var>Prefix</var> and
        <var>LocalPart</var>. Let
        <var>Prefix</var> be determined per the rules and constraints
        specified in Namespaces in XML <bibref ref="XMLNS"/>.</p></item>

        <item><p>Let <var>T</var> be a name in an application, represented as
		a sequence of characters encoded in a particular character encoding.
		</p>
		</item>

        <item><p>Let <function>M</function> be the implementation-defined function for
		transcoding of the characters used in the application-defined
		name to an equivalent string of Unicode characters.
		</p>
		<note><p>Ideally, if this transcoding is from a
		non-Unicode encoding, it should be both reversible and Unicode
		Form C normalizing (that is, combining sequences will be in
		the prescribed canonical order). It should be noted that some
		transcodings cannot be perfectly reversible and that Normalization Form C (NFC)
		normalization may alter the original sequence in a few
		cases (see Character Model for the World Wide Web <bibref ref="CharMod"/>). To
		ensure that matching names continue to match after mapping,
		Unicode sequences should be normalized using Unicode
		Normalization Form C.
		</p></note>
		<note><p>This transcoding is explicitly to Unicode
		scalar values ("code points") and not to any particular
		character encoding scheme of Unicode, such as UTF-8 or UTF-16.
		</p></note>
		<note><p>Note: Properly formed surrogate pair
		sequences must be converted to their respective scalar values
		("code points") [That is, the sequence U+D800 U+DC00 should be
		transcoded to the character U+10000]. If the transcoding
		begins with a Unicode encoding, non-conforming (non-shortest
		form) UTF-8 and UTF-16 sequences must be converted to their
		respective scalar values.
		</p></note>
		<note><p>The number of characters in <var>T</var> is not
		necessarily the same as the number of characters in <function>M</function>, because
		transcoding may be one-to-many or many-to-one. The details of
		transcoding may be implementation-defined. There may be (very
		rarely) cases where there is no equivalent Unicode
		representation for <var>T</var>; such cases are not covered here.
		</p></note>
		</item>

        <item><p>Let <var>C</var> be the sequence of Unicode
		scalar values (characters) represented by <function>M(T)</function></p>
		</item>

        <item><p>Let <var>N</var> be the number of characters in
		<var>C</var>. Let <var>C</var><sub>1</sub>,
		<var>C</var><sub>2</sub>, ..., <var>C</var><sub>N</sub> be the
		characters of <var>C</var>, in order from most to least
		significant (logical order).</p>
		</item>
		<item>
		<p>For each <var>i</var> between 1 (one) and
		<var>N</var>, let <var>X</var><sub>i</sub> be the Unicode
		character string defined by the following rules:
		</p>

        <p>Case:</p>
        <olist>

          <item><p>If <var>C</var><sub>i</sub> is undefined (that
		  is, some character or sequence of characters as defined in
		  the application's character sequence <var>T</var> contains
		  no mapping to Unicode), then <var>X</var><sub>i</sub> is
		  implementation-defined.</p>
		  </item>

          <item><p>If <var>i</var>&lt;=<var>N</var>-1 and
		  <var>C</var><sub>i</sub> is <attval>_</attval> (U+005F LOW LINE) and
		  <var>C</var><sub>i+1</sub> is <attval>x</attval> (U+0078 LATIN SMALL LETTER
		  X), then let <var>X</var><sub>i</sub> be <attval>_x005F_</attval>.
		  </p>
		  </item>

          <item><p>If <var>i</var>=1, and <var>N</var>&gt;=3, and
		  <var>C</var><sub>1</sub> is <attval>x</attval> (U+0078 LATIN
		  SMALL LETTER X) or <attval>X</attval> (U+0058 LATIN CAPITAL
		  LETTER X), and <var>C</var><sub>2</sub> is <attval>m</attval> (U+006D LATIN
		  SMALL LETTER M) or <attval>M</attval> (U+004D LATIN CAPITAL
		  LETTER M), and <var>C</var><sub>3</sub> is <attval>l</attval> (U+006C LATIN
		  SMALL LETTER L) or <attval>L</attval> (U+004C LATIN CAPITAL
		  LETTER L) (in other words, a string three letters or longer
		  starting with the text <attval>xml</attval> or any
		  re-capitalization thereof), 
                  then if <var>C</var><sub>1</sub> is
		  <attval>x</attval> (U+0078 LATIN SMALL LETTER X)
		  then let <var>X</var><sub>1</sub> be
		  <attval>_x0078_</attval>; otherwise, if
		  <var>C</var><sub>1</sub> is <attval>X</attval>
		  (U+0058 LATIN CAPITAL LETTER X) then let
		  <var>X</var><sub>1</sub> be <attval>_x0058_</attval>.
		  </p>
		  </item>

          <item><p>If <var>C</var><sub>i</sub> is not a valid XML
		  NCName character (see Namespaces in XML <bibref ref='XMLNS' />) or if
		  <var>i</var>=1 (one) and <var>C</var><sub>1</sub> is not a
		  valid first character of an XML NCName then:</p>

          <p>Let <var>U<sub>1</sub></var>, <var>U<sub>2</sub></var>,
          ... , <var>U<sub>6</sub></var> be the six hex digits
          <specref ref="hexDigit"/> such
          that <var>C<sub>i</sub></var> is <attval>U+</attval>
          <var>U<sub>1</sub></var> <var>U<sub>2</sub></var>
          ... <var>U<sub>6</sub></var> in the Unicode scalar value.</p>

          <p>Case:</p>

          <olist>

            <item>

              <p>If <var>U<sub>1</sub></var>=0,
              <var>U<sub>2</sub></var>=0, <var>U<sub>3</sub></var>=0, and
              <var>U<sub>4</sub></var>=0, then let
              <var>X<sub>i</sub></var>=<attval>_x</attval>
              <var>U<sub>5</sub></var>
              <var>U<sub>6</sub></var> <attval>_</attval>.</p>

              <p>This case implies that
              <var>C<sub>i</sub></var> is a character in the Basic
              Multilingual Plane (Plane 0) of Unicode and can be
              wholly represented by a single UTF-16 code point sequence
              U+<var>U<sub>5</sub></var><var>U<sub>6</sub></var>.</p>
            </item>

            <item>

              <p>Otherwise, let <var>X<sub>i</sub></var> be
              <attval>_x</attval> <var>U<sub>1</sub></var>
              <var>U<sub>2</sub></var>
              <var>U<sub>3</sub></var> <var>U<sub>4</sub></var>
              <var>U<sub>5</sub></var>
              <var>U<sub>6</sub></var> <attval>_</attval>.</p>
            </item>

          </olist>

          </item>

          <item><p>Otherwise, let <var>X<sub>i</sub></var> be
          <var>M<sub>i</sub></var>. That is, any character in <var>X</var> that is a
          valid character in an XML NCName is simply copied.</p></item>

        </olist>
        </item>


        <item>
          <p>Let <var>LocalPart</var> be the character string
          concatenation of <var>X<sub>1</sub></var>, <var>X<sub>2</sub></var>,
          ... , <var>X<sub>N</sub></var> in order from most to least significant.</p>
        </item>

        <item>
          <p>Let XML Name be the QName per Namespaces in XML <bibref ref="XMLNS"/></p>
        </item>

      </olist>
	  </div2>
	  <div2 id="namemap-ex"><head>Examples</head>

	  <example>
	  <eg xml:space="preserve">
Hello world -&gt; Hello_x0020_world
Hello_xorld -&gt; Hello_x005F_xorld
Helloworld_ -&gt; Helloworld_

          x -&gt; x
        xml -&gt; _x0078_ml
       -xml -&gt; _x002D_xml
       x-ml -&gt; x-ml

     &#x00C6;lfred -&gt; &#x00C6;lfred
   &#x03AC;&#x03B3;&#x03BD;&#x03C9;&#x03C3;&#x03C4;&#x03BF;&#x03C2; -&gt; &#x03AC;&#x03B3;&#x03BD;&#x03C9;&#x03C3;&#x03C4;&#x03BF;&#x03C2;
&#x1709;&#x1705;&#x170E;&#x1708;        -&gt; _x1709__x1705__x170E__x1708_
&#x13D9;&#x13DA;&#x13A5;         -&gt; _x13D9__x13DA__x13A5_
      </eg>
	  </example>
	  </div2>
    </div1>

    <inform-div1 id="encschema">
	  <head>Using W3C XML Schema with SOAP Encoding</head>
	  
	  <p>
	  As noted in <specref ref='enctypename' /> SOAP graph nodes are
	  labeled with type names, but conforming processors are not required to perform
	  validation of encoded SOAP messages.</p>

	  <p>These sections
	  describe techniques that can be used when validation with W3C
	  XML schemas is desired for use by SOAP applications. Any errors
	  or faults resulting from such validation are beyond those
	  covered by the normative Recommendation; from the perspective of
	  SOAP, such faults are considered to be application-level
	  failures.
	  </p>	  
	  <div2 id='validmin'>
	    <head>Validating Using the Minimum Schema</head>
		<p>
		Although W3C XML schemas are conventionally exchanged in the
		form of schema documents (see XML Schema <bibref ref='XMLSchemaP1' />), the schema
		Recommendation is built on an abstract definition of schemas,
		to which all processors need to conform. The schema
		Recommendation provides that all such schemas include
		definitions for a core set of built in types, such as
		integers, dates, and so on (see XML Schema <bibref ref='XMLSchemaP1' />, 
		<xspecref xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
		href='http://www.w3.org/TR/2001/REC-xmlschema-1-20010502/#Simple_Type_Definitions'
		>Built-in Simple Type Definition</xspecref>). 
		Thus, it is possible to discuss validation of a SOAP
		message against such a minimal schema, which is the one that
		would result from providing no additional definitions or
		declarations (i.e., no schema document) to a schema processor.
		</p>

		<p>
		The minimal schema provides that any well formed XML document
		will validate, except that where an xsi:type is provided, the
		type named must be built in, and the corresponding element must be
		valid per that type. Thus, validation of a SOAP 1.2 message using a
		minimal schema approximates the behavior of the built-in types
		of SOAP 1.1.
		</p>
	  </div2>
	  <div2 id='validenc'>
	    <head>Validating Using the SOAP Encoding Schema</head>

		<p>
		Validation against the minimal schema (see <specref
		ref='validmin' />) will not succeed where encoded graph nodes
		have multiple inbound edges. This is because
		elements representing such graph nodes will carry <att>id</att>
		<emph>attribute information items</emph> which are not legal
		on elements of type <attval>xs:string</attval>,
		<attval>xs:integer</attval> etc. The SOAP Encoding of such graphs MAY be validated
		against the <xspecref
		xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple"
		href='http://www.w3.org/2003/05/soap-encoding'>SOAP Encoding schema</xspecref>.
		In order for the encoding to validate, edge labels, and
		hence the
		[local name] and [namespace name] properties of the
		<emph>element information items</emph>, need to match those
		defined in the SOAP Encoding schema. Validation of the encoded
		graph against the SOAP Encoding schema would result in the
		type name property of the nodes in the graph being assigned
		the relevant type name.
		</p>

	  </div2>
	  <div2 id='validschema'>
	    <head>Validating Using More Specific Schemas</head>

		<p>
		It may be that schemas could be constructed to describe the encoding of
		certain graphs. Validation of the encoded graph against such a schema would
		result in the type name property of the graph nodes being assigned the
		relevant type name.   Such a schema can also supply default or fixed values
		for one or more of the <att>itemType</att>, <att>arraySize</att> or 
		<att>nodeType</att> <emph>attribute
		information items</emph>;  the values of such defaulted attributes affect the
		deserialized graph in the same manner as if the attributes had been
		explicitly supplied in the message.  Errors or inconsistencies thus
		introduced (e.g. if the value of the attribute is erroneous or inappropriate)
		should be reported as application-level errors; faults from the 
		<attval>http://www.w3.org/2003/05/soap-encoding</attval>
		namespace should be reported only if the normative parts of this
		specification are violated.
		</p>

	  </div2>
	</inform-div1>    

    <inform-div1>
      <head>Acknowledgements</head>

      <p>This document is the work of the W3C XML Protocol Working Group.</p>

      <p>Participants in the Working Group are (at the time of writing, and by
      alphabetical order): &wgmb;</p>

      <p>Previous participants were: &prevwgmb;</p>

<p>The people who have contributed to discussions on
<loc xmlns:xlink="http://www.w3.org/1999/xlink" xlink:type="simple" href="mailto:xml-dist-app@w3.org">xml-dist-app@w3.org</loc>
are also gratefully acknowledged.</p>

    </inform-div1>

  </back>
</spec>
