This section describes how the WebSphere MQ bridge handles messages flowing between MQSeries systems that use different national languages. The diagram in Figure 44 is used to describe the flow of a message from an WebSphere MQ Everyplace client application to a WebSphere MQ application.
Figure 44. Message flow from WebSphere MQ Everyplace to WebSphere MQ
The message is not translated at all through this step.
The message is not translated at all through this step.
The transformer creates a WebSphere MQ message as follows:
String value = MQemsg.GetUnicode(fieldname)
Byte value = MQemsg.getByte(fieldName)
If using writeString(), the character set of the string may also be set. The transformer returns the resultant WebSphere MQ message to the calling WebSphere MQ bridge code.
Unicode values in the WebSphere MQ message are translated from big-endian to little-endian, and vice versa, as required. Byte values in the WebSphere MQ message are translated from big-endian to little-endian, and vice versa, as required. The field that was created using writeString() is translated as the message is put to WebSphere MQ, using conversion routines inside the WebSphere MQ Classes for Java. ASCII data should remain ASCII data regardless of the character set conversions performed. The translations done during this step depend on the code page of the message, the CCSID of the sending WebSphere MQ Classes for Java client connection, and the CCSID of the receiving WebSphere MQ server connection.
If the message contains a Unicode string, the application must deal with that string as a Unicode string, or else convert it into some other format, for example, UTF8. If the message contains a byte string, the application may use the bytes as it is (raw data). If the message contains a string, it is read from the message, and may be converted to a different data format as required by the application. This conversion is dependent on the codeset value in the characterSet header field. Java classes provide this automatically.
If you have an WebSphere MQ Everyplace application, and wish to convey character-related data from WebSphere MQ Everyplace to WebSphere MQ, your choice of method is determined largely by the data you wish to convey: