TextMessageEncodingBindingElement Class
[ This article is for Windows Phone 8 developers. If you’re developing for Windows 10, see the latest documentation. ]
The binding element that specifies the character encoding and message versioning used for text-based SOAP messages.
System.ServiceModel.Channels::BindingElement
System.ServiceModel.Channels::MessageEncodingBindingElement
System.ServiceModel.Channels::TextMessageEncodingBindingElement
Assembly: System.ServiceModel (in System.ServiceModel.dll)
The TextMessageEncodingBindingElement type exposes the following members.
| Name | Description | |
|---|---|---|
![]() | TextMessageEncodingBindingElement() | Initializes a new instance of the TextMessageEncodingBindingElement class. |
![]() | TextMessageEncodingBindingElement(MessageVersion, Encoding) | Initializes a new instance of the TextMessageEncodingBindingElement class with a specified message version and encoding. |
| Name | Description | |
|---|---|---|
![]() | MessageVersion | Gets or sets the SOAP and WS-Addressing versions that are used to format the text message. (Overrides MessageEncodingBindingElement::MessageVersion.) |
![]() | WriteEncoding | Gets or sets the encoding that is used to format the characters in the text message. |
| Name | Description | |
|---|---|---|
![]() | BuildChannelFactory<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).) |
![]() | CanBuildChannelFactory<TChannel> | Returns a value that indicates whether the binding element can build a channel factory for a specific type of channel. (Inherited from BindingElement.) |
![]() | Clone | Creates a new TextMessageEncodingBindingElement object initialized from the current one. (Overrides BindingElement::Clone().) |
![]() | CreateMessageEncoderFactory | Creates a factory for text message encoders that employs the message version and character encoding specified by the current encoding binding element. (Overrides MessageEncodingBindingElement::CreateMessageEncoderFactory().) |
![]() | Equals(Object) | Determines whether the specified Object is equal to the current Object. (Inherited from Object.) |
![]() | Finalize | Allows an object to try to free resources and perform other cleanup operations before the Object is reclaimed by garbage collection. (Inherited from Object.) |
![]() | GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) |
![]() | GetProperty<T> | Returns a typed object requested, if present, from the appropriate layer in the binding element stack. (Overrides MessageEncodingBindingElement::GetProperty<T>(BindingContext).) |
![]() | GetType | Gets the Type of the current instance. (Inherited from Object.) |
![]() | MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) |
![]() | ToString | Returns a string that represents the current object. (Inherited from Object.) |
Encoding is the process of transforming a message into a sequence of bytes. Decoding is the reverse process. Windows Phone uses Text encoding for SOAP messages.
The text encoding represented by the TextMessageEncodingBindingElement is the most interoperable, but the least efficient encoder for XML messages. Web service or Web service client can generally understand textual XML. However, transmitting large blocks of binary data as text is not efficient.
For more information about
how to implement a custom message encoder, use the MessageEncodingBindingElement class.


