Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

MtomMessageEncodingBindingElement Class

The binding element that specifies the encoding and versioning used for Message Transmission Optimization Mechanism (MTOM) messages.

Namespace:  System.ServiceModel.Channels
Assembly:  System.ServiceModel (in System.ServiceModel.dll)
public sealed class MtomMessageEncodingBindingElement : MessageEncodingBindingElement, 
	IWsdlExportExtension, IPolicyExportExtension

The MtomMessageEncodingBindingElement type exposes the following members.

  NameDescription
Public methodMtomMessageEncodingBindingElement()Initializes a new instance of the MtomMessageEncodingBindingElement class.
Public methodMtomMessageEncodingBindingElement(MessageVersion, Encoding)Initializes a new instance of the MtomMessageEncodingBindingElement class with a specified message version and character encoding.
Top
  NameDescription
Public propertyMaxBufferSizeGets or sets the maximum buffer size.
Public propertyMaxReadPoolSizeGets or sets the maximum number of XML readers that is allocated to a pool and is ready for use to process incoming messages.
Public propertyMaxWritePoolSizeGets or sets the maximum number of XML writers that is allocated to a pool and are ready for use to process outgoing messages.
Public propertyMessageVersionGets or sets the SOAP message and WS-Addressing versions that are used or expected. (Overrides MessageEncodingBindingElement.MessageVersion.)
Public propertyReaderQuotasGets or sets constraints on the complexity of XML messages that can be processed by endpoints configured with this binding element.
Public propertyWriteEncodingGets or sets the encoding that is used to format the characters in the text message.
Top
  NameDescription
Public methodBuildChannelFactory<TChannel>Builds the channel factory stack on the client that creates a specified type of channel for a specified context. (Overrides BindingElement.BuildChannelFactory<TChannel>(BindingContext).)
Public methodBuildChannelListener<TChannel>Builds the channel listener stack on the client that accepts a specified type of channel for a specified context. (Overrides BindingElement.BuildChannelListener<TChannel>(BindingContext).)
Public methodCanBuildChannelFactory<TChannel>Returns a value that indicates whether the current binding can build a factory for a specified type of channel and context. (Overrides BindingElement.CanBuildChannelFactory<TChannel>(BindingContext).)
Public methodCanBuildChannelListener<TChannel>Returns a value that indicates whether the current binding can build a listener for a specified type of channel and context. (Overrides BindingElement.CanBuildChannelListener<TChannel>(BindingContext).)
Public methodCloneCreates a new MtomMessageEncodingBindingElement object initialized from the current one. (Overrides BindingElement.Clone().)
Public methodCreateMessageEncoderFactoryCreates a message encoder factory that encodes MTOM messages. (Overrides MessageEncodingBindingElement.CreateMessageEncoderFactory().)
Public methodEquals(Object)Determines whether the specified object is equal to the current object. (Inherited from Object.)
Public methodGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetProperty<T>Returns a typed object requested, if present, from the appropriate layer in the binding element stack. (Overrides MessageEncodingBindingElement.GetProperty<T>(BindingContext).)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Public methodShouldSerializeMessageVersionReturns whether the SOAP message structure version should be serialized.
Public methodShouldSerializeReaderQuotasReturns whether the constraints placed on the complexity of SOAP message structure should be serialized.
Public methodShouldSerializeWriteEncodingReturns whether the Encoding that is used to format the message characters should be serialized.
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top
  NameDescription
Explicit interface implemetationPrivate methodIPolicyExportExtension.ExportPolicyInserts a policy assertion into the WSDL, when it is generated, which indicates that an MTOM encoding is being used.
Explicit interface implemetationPrivate methodIWsdlExportExtension.ExportContractModifies the WSDL contract for MTOM-specific information.
Explicit interface implemetationPrivate methodIWsdlExportExtension.ExportEndpointPuts the SOAP message version into the WSDL.
Top

Encoding is the process of transforming a message into a sequence of bytes. Decoding is the reverse process. Windows Communication Foundation (WCF) includes three types of encoding for SOAP messages: Text, Binary and Message Transmission Optimization Mechanism (MTOM).

The MTOMMessageEncodingBindingElement represents the binding element that specifies the character encoding and message versioning and other settings used for messages using a Message Transmission Optimization Mechanism (MTOM) encoding. MTOM is an efficient technology for transmitting binary data in WCF messages. The MTOM encoder attempts to create a balance between efficiency and interoperability. The MTOM encoding transmits most XML in textual form, but optimizes large blocks of binary data by transmitting them as-is, without conversion to their base64 encoded format.

For more information about the binding element that specifies that messages are encoded using a textual representation of XML, see TextMessageEncodingBindingElement.

For more information about the binding element that specifies messages are encoded using the .NET Binary Format for XML, see BinaryMessageEncodingBindingElement.

To implement a custom message encoder, use the MessageEncodingBindingElement class.

.NET Framework

Supported in: 4.5.1, 4.5, 4, 3.5, 3.0

.NET Framework Client Profile

Supported in: 4, 3.5 SP1

Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.