Software Internationalization Guide

POSIX and XPG Internationalization Model
Software Internationalization Guide526225-002
3-13
Algorithmic Code-Set Converters
Algorithmic Code-Set Converters
Most multibyte code sets, such as the large Asian code sets, cannot use tables for
conversion and therefore require algorithmic code-set converters. The naming
convention for code-set converters is the same as for conversion tables. For example,
the converter that defines the conversion of Shift-JIS to the Japanese EUC is called
SJIS_AJEC.
Accessing Code-Set Conversion-Tables
The following XPG-defined conversion functions and the iconv command available in
the OSS shell provide access to code-set converters or conversion tables:
iconv_open() opens a code-set converter or a code-set conversion table based
on the search path information contained in the LOCPATH environment variable. If
LOCPATH is not defined, iconv_open() uses the default value of
/usr/lib/nls/loc/iconvTable.
iconv() performs the conversion from one code set to another code set.
iconv_close() closes a code-set conversion table or code-set converter.
See the associated reference pages either online or in the Open System Services
Library Calls Reference Manual for more information about these code-set conversion
functions.
The iconv command converts the encoding of characters in a file from one coded
character set to another and writes the results to the standard output file. See the
iconv(1) reference page either online or in the Open System Services Shell and
Utilities Reference Manual for more information.
Figure 3-3. Generating Code-Set Conversion Table
Source Code File
of Code-Set
Conversion Tables
genxlt
Code-Set
Conversion
Table
VST014.vsd