Both C++ APIs and Java APIs support Unicode for application data. This allows custom adapters to work with Unicode strings programmatically and to send and receive data between applications that use a variety of supported encodings. The data can be aggregated and serialized, and then sent over the network.
The C++ Adapter SDK includes classes to encapsulate Unicode data. Their constructors allow you to specify the encoding for the source data. A complete list of supported encodings can be found in the
TIBCO Adapter SDK Programmer’s Guide.
If the encoding presented to the constructor is ASCII, Latin-1, or UTF-16, no conversion is needed. For all other cases, the SDK attempts a best-case conversion. If conversion is required (for example, UTF-16 to Latin-1), a replacement character is used for unmappable characters.
For Unicode conversion, the environment variable TIB_ICU_DATA must point to the directory that contains the file named
tibicudata.dat, which provides a lookup table for conversion. If the SDK cannot find this file, it will throw an exception when you attempt to convert certain types of string encodings.
The wire format encoding for messages affects communications for adapter applications. TIBCO Administrator supports either Latin-1 or UTF-8 as its wire format encoding when the adapter application is using a server-based repository.