Encode::JISX0213(3)

NAME
Encode::JISX0213 - JIS X 0213 encodings

SYNOPSIS
    use Encode::JISX0213;
    use Encode qw/encode decode/;
    $byte = encode("iso-2022-jp-2004", $utf8);
    $utf8 = decode("iso-2022-jp-2004", $byte);

ABSTRACT
This module provides following encodings.

  Canonical         Alias                         Description
  --------------------------------------------------------------
  euc-jis-2004      qr/\beuc-?(jis|jp)-?2004$/i   8-bit encoding
  iso-2022-jp-2004  qr/\biso-?2022-?jp-?2004$/i   7-bit encoding
  --------------------------------------------------------------

•   About "shift encoding" see Encode::ShiftJIS2004.

Additionally, it provides encodings for older revision, JIS X 0213:2000:

  Canonical         Alias                         Description
  --------------------------------------------------------------
  euc-jisx0213      qr/\beucjisx0213$/i           8-bit encoding
                    qr/\beuc.*jp[ \-]?(?:2000|2k)$/i
                    qr/\bjp.*euc[ \-]?(2000|2k)$/i
                    qr/\bujis[ \-]?(?:2000|2k)$/i
  iso-2022-jp-3     qr/\biso-?2022-?jp-?3$/i      7-bit encoding
  --------------------------------------------------------------

and for transition from legacy standards:

  Canonical         Alias                         Description
  --------------------------------------------------------------
  x-iso2022jp2004-compatible                      See note.
                    qr/\biso-?2022-?jp-?2004-?compatible$/i
  x-iso2022jp2004-strict                          See note.
                    qr/\biso-?2022-?jp-?2004-?strict$/i
  --------------------------------------------------------------

DESCRIPTION
To find out how to use this module in detail, see Encode.

  Notes on Compatibility
To encode Unicode string to byte string, "x-iso2022jp2004-strict" uses JIS X 0208 as much as possible, strictly conforming to JIS X 0213:2004 Annex 2. It is compatible to other encodings.

"x-iso2022jp2004-compatible" uses JIS X 0208 for the bit combinations co-existing on JIS X 0208 and JIS X 0213 plane 1. It is not compatible to other encodings; it had never been registered by any standards bodies.

However, to decode byte string to Unicode string, encodings in the tables above accept arbitrary sequences of both JIS X 0208 and JIS X 0213. Exception is "x-iso2022jp2004-strict": It accepts only allowed JIS X 0208 sequences.

"euc-jis-2004" and "euc-jisx0213" contains JIS X 0213 plane 2 along with JIS X 0212 in G3. By this non-standard extension, they have forward compatibility with EUC-JP (AJEC) in case of decoding.

  Comparison with Other Modules
Encode::JIS2K provides "euc-jisx0213", "iso-2022-jp-3" and "shift_jisx0213" encodings. "euc-jp" in Encode::JP 1.64 or later can decode "euc-jisx0213" sequences. They support earlier revision of standard, and lack function to encode sequences with multiple Unicode characters such as katakana with semi-voiced sound mark.

ShiftJIS::X0213::MapUTF provides "shift_jisx0213" and "shift_jis-2004". It does not provide interface to contemporary Encode module.

SEE ALSO
JIS X 0213:2000 7ビット及び8ビットの2バイト情報交換用符号化拡張漢字集合 (7-bit and 8-bit double byte coded extended KANJI sets for information interchange), and its amendment JIS X 0213:2000/Amd.1:2004.

Encode, Encode::JP, Encode::ShiftJIS2004.

AUTHOR
Hatuka*nezumi - IKEDA Soji <hatuka(at)nezumi.nu>

COPYRIGHT
Copyright (C) 2013, 2015 Hatuka*nezumi - IKEDA Soji.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.