[TIBCO.EMS .NET client library 7.0 documentation]

Set global string encoding for messages

Namespace:  TIBCO.EMS
Assembly:  TIBCO.EMS (in TIBCO.EMS.dll)

Syntax

public static void SetEncoding(
	string encodingName
)
Public Shared Sub SetEncoding ( _
	encodingName As String _
)
public:
static void SetEncoding(
	String^ encodingName
)

Parameters

encodingName
Type: System..::.String
The name of the encoding (for example, "utf-8"). For a list of standard encoding names, see www.iana.org.

Remarks

Clients can override the global encoding for individual messages. When neither a global nor an individual message encoding has been set, then EMS encodes the strings of an outbound message using the default UTF-8 encoding.

This encoding applies to all strings in message body fields (names and values), and properties (names and values). It does not apply to message header fields. The methods BytesMessage.ReadUTF and BytesMessage.WriteUTF are exempt from global and individual encoding settings.

Note: The only encoding names that are supported by the .NET client are the ones defined by the .NET framework. Please refer to the .NET framework documentation for a complete list of the encoding names supported by the .NET framework.

Exceptions

ExceptionCondition
TIBCO.EMS..::.EMSException If the encoding is not supported.

See Also