Edit

Share via


SoapHeaderHandling.WriteHeaders Method

Definition

Writes the specified SOAP header content to the SOAP message.

C#
public static void WriteHeaders(System.Xml.XmlWriter writer, System.Xml.Serialization.XmlSerializer serializer, System.Web.Services.Protocols.SoapHeaderCollection headers, System.Web.Services.Protocols.SoapHeaderMapping[] mappings, System.Web.Services.Protocols.SoapHeaderDirection direction, bool isEncoded, string defaultNS, bool serviceDefaultIsEncoded, string envelopeNS);

Parameters

writer
XmlWriter

The XmlWriter to be used in writing the headers.

serializer
XmlSerializer

The XmlSerializer to be used in writing the headers.

headers
SoapHeaderCollection

The SoapHeaderCollection that contains the SOAP headers to be written.

mappings
SoapHeaderMapping[]

An array of type SoapHeaderMapping that contains the mappings for the SOAP headers.

direction
SoapHeaderDirection

A SoapHeaderDirection value that indicates the direction of the SOAP headers.

isEncoded
Boolean

A Boolean that indicates whether the SOAP headers are encoded.

defaultNS
String

A String that contains the default namespace for the XML Web service.

serviceDefaultIsEncoded
Boolean

A Boolean that indicates whether data sent to and from the XML Web service is encoded by default.

envelopeNS
String

A String that contains the namespace for the SOAP message envelope.

Applies to

Product Versions
.NET Framework 2.0, 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1

See also