Converters overview for programming

Multicultural support provides a base for globalization in which data often can be changed from one code set to another. Support of several standard converters for this purpose is provided.

Data sent by one program to another program residing on a remote host may require conversion from the code set of the source machine to that of the receiver. For example, when communicating with a VM system, the workstation converts its ISO8859-1 data to an EBCDIC form.

Code sets define graphic characters and control character assignments to code points. These coded characters must also be converted when a program obtains data in one code set but displays it in another code set.

The system provides the following conversion interfaces:

iconv command
Allows you to request a specific conversion by naming the FromCode and ToCode code sets.
libiconv functions
Allows applications to request converters by name.

The system provides ready-to-use libraries of converters. The converter libraries are found in the /usr/lib/nls/loc/iconv/* and /usr/lib/nls/loc/iconvTable/* directories. Do not define your own converter unless absolutely necessary.

In addition to code set converters, the converter library also provides a set of network interchange converters. In a network environment, the code sets of the communications systems and the protocols of communication determine how the data should be converted.

Interchange converters are used to convert data sent from one system to another. Conversions from one internal code set to another code set require code set converters. When data must be converted from a sender's code set to a receiver's code set or from 8-bit data to 7-bit data, a uniform interface is required. The iconv subroutines provide this interface.