Integrate mainline (Win2k/MinGW all ok except threads/t/end.t)
[p5sagit/p5-mst-13.2.git] / ext / Encode / JP / JP.pm
1 package Encode::JP;
2 BEGIN {
3     if (ord("A") == 193) {
4         die "Encode::JP not supported on EBCDIC\n";
5     }
6 }
7 use Encode;
8 our $VERSION = do { my @r = (q$Revision: 0.94 $ =~ /\d+/g); sprintf "%d."."%02d" x $#r, @r };
9
10 use XSLoader;
11 XSLoader::load('Encode::JP',$VERSION);
12
13 use Encode::JP::JIS;
14 use Encode::JP::ISO_2022_JP;
15
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
23 1;
24 __END__
25 =head1 NAME
26
27 Encode::JP - Japanese Encodings
28
29 =head1 SYNOPSIS
30
31     use Encode qw/encode decode/; 
32     $euc_jp = encode("euc-jp", $utf8);   # loads Encode::JP implicitly
33     $utf8   = decode("euc-jp", $euc_jp); # ditto
34
35 =head1 ABSTRACT
36
37 This module implements Japanese charset encodings.  Encodings
38 supported are as follows.
39
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)
53
54 =head1 DESCRIPTION
55
56 To find how to use this module in detail, see L<Encode>.
57
58 =head1 BUGS
59
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