Commit | Line | Data |
0e567a6c |
1 | package Encode::JP; |
0f3b375a |
2 | BEGIN { |
3 | if (ord("A") == 193) { |
4 | die "Encode::JP not supported on EBCDIC\n"; |
5 | } |
6 | } |
0e567a6c |
7 | use Encode; |
1b2c56c8 |
8 | our $VERSION = do { my @r = (q$Revision: 0.94 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r }; |
ee981de6 |
9 | |
0e567a6c |
10 | use XSLoader; |
11 | XSLoader::load('Encode::JP',$VERSION); |
12 | |
13 | use Encode::JP::JIS; |
14 | use Encode::JP::ISO_2022_JP; |
15 | |
fab31126 |
16 | Encode::define_alias( qr/euc.*jp$/i => '"euc-jp"' ); |
17 | Encode::define_alias( qr/jp.*euc/i => '"euc-jp"' ); |
18 | Encode::define_alias( qr/ujis$/i => '"euc-jp"' ); |
19 | Encode::define_alias( qr/shift.*jis$/i => '"shiftjis"' ); |
20 | Encode::define_alias( qr/sjis$/i => '"shiftjis"' ); |
21 | Encode::define_alias( qr/^jis$/i => '"7bit-jis"' ); |
22 | |
0e567a6c |
23 | 1; |
24 | __END__ |
557e5ea9 |
25 | =head1 NAME |
26 | |
27 | Encode::JP - Japanese Encodings |
28 | |
29 | =head1 SYNOPSIS |
30 | |
1b2c56c8 |
31 | use Encode qw/encode decode/; |
2b217bf7 |
32 | $euc_jp = encode("euc-jp", $utf8); # loads Encode::JP implicitly |
ee981de6 |
33 | $utf8 = decode("euc-jp", $euc_jp); # ditto |
557e5ea9 |
34 | |
35 | =head1 ABSTRACT |
36 | |
37 | This module implements Japanese charset encodings. Encodings |
38 | supported are as follows. |
39 | |
fab31126 |
40 | Canonical Alias Description |
41 | -------------------------------------------------------------------- |
42 | euc-jp /euc.*jp$/i EUC (Extended Unix Character) |
43 | /jp.*euc/i |
44 | /ujis$/i |
45 | shiftjis /shift.*jis$/i Shift JIS (aka MS Kanji) |
46 | /sjis$/i |
47 | 7bit-jis /^jis$/i 7bit JIS |
48 | iso-2022-jp ISO-2022-JP |
49 | (7bit JIS with all Halfwidth Kana |
50 | converted to Fullwidth) |
51 | macjapan Mac Japan (Shift JIS + Apple vendor mappings) |
52 | cp932 Code Page 932 (Shift JIS + Microsoft vendor mappings) |
557e5ea9 |
53 | |
54 | =head1 DESCRIPTION |
55 | |
56 | To find how to use this module in detail, see L<Encode>. |
57 | |
58 | =head1 BUGS |
59 | |
557e5ea9 |
60 | ASCII part (0x00-0x7f) is preserved for all encodings, even though it |
61 | conflicts with mappings by the Unicode Consortium. See |
62 | |
63 | F<http://www.debian.or.jp/~kubota/unicode-symbols.html.en> |
64 | |
65 | to find why it is implemented that way. |
66 | |
67 | =head1 SEE ALSO |
68 | |
69 | L<Encode> |
70 | |
71 | =cut |