- Understanding SOAP FAQs
- How do I invoke a method on a server when I'm using SOAP?
- Do M-POST calls have to occur before POST calls?
- When I'm using XML in SOAP, do I have to use namespaces?
- What happens when a method call has been requested?
- What are the values in a SOAP payload?
- What could cause the performance of a SOAP call to degrade or suffer?
- What kind of security does SOAP implement?
- When using SOAP, how do I implement a simple API for XML?
- How will SOAP impact .Net application development?
- How is ASP+ used when creating web services?
- How do I validate SOAP-based XML using a schema?
- When using SOAP, what is the most efficient way to access services from a client over the Internet?
What are the values in a SOAP payload?
There are two kinds of values in a SOAP payload. The first kind is called a single-reference value and can only be referenced by one accessor. Consider the following XML fragment
<Car>Corvette</Car> <Automobile> Corvette </Automobile>
In this case, both the <Car> element and the <Automobile> element contain their own unique Corvette values. This means that each Corvette value has only been referenced by its surrounding element (that is, accessor) and no other.
The second kind of value in a SOAP payload is called a multi-reference value and can be referenced by one or more accessors. Let's examine a similar XML fragment that uses multi-reference values:
<Car href="#somecar" /> <Automobile id="somecar"> Corvette </Automobile>
In this example, Corvette is referenced by two accessors, the Car accessor and the Automobile accessor; thus, it is considered a multi-reference value.
The purpose for distinguishing between single-reference and multi-reference values helps to deal with identity issues of serializing (that is, marshaling) data across the wire. For instance, if two method parameters reference the same value, in some cases you will want the XML to reflect this identity and in other cases you won't.
Source: This FAQ is excerpted from Understanding SOAP by Kennard Scribner and Mark C. Stiver (2000, Sams, ISBN 0672319225). Refer to this book for more detailed information on SOAP.