2.2 Messages

This section defines messages that are used by this protocol. The syntax of the definitions uses XML Schema as defined in [XMLSCHEMA1] and [XMLSCHEMA2] and Web Services Description Language (WSDL) as defined in [WSDL].

The following information describes the steps by which the API is mapped to structures and operations in the web service.

Each class in the ReportService2006 web service [MSDN-SQL2008RSWS], except the one derived from System.Web.Services.Protocols.SoapHttpClientProtocol, becomes one WSDL type. The following rules apply:

  • Non-inherited public properties become elements in the type, with the following exceptions and additional rules:

    • Any property named AnyAttr becomes the XSD anyAttribute in the type rather than an element.

    • If the name of a property is the concatenation of the name of another property in the same class and "Specified", no element is created for the former property in the type. The minOccurs attribute of the element for the latter property is 0. For other properties, the minOccurs attribute is 1 unless the API data type is String, Byte[], or an array type, in which case the minOccurs attribute is 0.

    • The maxOccurs attribute of the element is 1 for nonarray types and "unbounded" for array types.

  • If the class inherits another class in the web service, the WSDL type of the inherited class becomes an XSD extension in the WSDL type corresponding to the inheriting class.

Each enumeration in the web service becomes one WSDL type as an XSD enumeration.

Each class that inherits System.Web.Services.Protocols.SoapHeader [MSDN-SoapHeader] becomes one SOAP header.

Each method in the class derived from System.Web.Services.Protocols.SoapHttpClientProtocol [MSDN-SoapHttpClientProtocol] that is not derived from a base method in a base class or an interface becomes one WSDL operation with a corresponding SOAP operation, a request WSDL message, a response WSDL message, and corresponding WSDL types. The following rules apply:

  • Out parameters and return values of the method become elements in the WSDL type for the response WSDL message.

  • Other parameters of the method become elements in the WSDL type for the request WSDL message.

  • If the method uses a SOAP header, the WSDL operation contains a WSDL message that has a single part of the WSDL type corresponding to the SOAP header.

An array of a class becomes a WSDL type with an element of the WSDL type corresponding to the class.

The primitive data types used by the API are mapped to WSDL XML Schema types as described in the following table.

API Primitive Data Type

WSDL XML Schema Type

Byte[]

base64Binary

Boolean

boolean

SByte

byte

Double

double

DateTime

dateTime

Decimal

decimal

Single

float

Int32

int

Int64

long

XmlQualifiedName

QName

Int16

short

String

string

Byte

unsignedByte

UInt32

unsignedInt

UInt64

unsignedLong

UInt16

unsignedShort

The result of this mapping can be found in the full WSDL in Appendix A of this specification.