/[suikacvs]/perl/lib/Encode/ISO2022/ISO646.pm
Suika

Contents of /perl/lib/Encode/ISO2022/ISO646.pm

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.4 - (hide annotations) (download)
Sat Oct 12 07:27:01 2002 UTC (22 years, 1 month ago) by wakaba
Branch: MAIN
CVS Tags: HEAD
Changes since 1.3: +7 -2 lines
2002-10-12  Nanashi-san

	* SJIS.pm: New module.
	* SJIS/: New directory.
	(Commited by Wakaba <w@suika.fam.cx>)

1 wakaba 1.1 =head1 NAME
2    
3     Encode::ISO2022::ISO646 --- Encode and decode of versions of
4     ISO/IEC 646
5    
6     =head1 ENCODINGS
7    
8     =over 4
9    
10     =cut
11    
12     require 5.7.3;
13     use strict;
14     package Encode::ISO2022::ISO646;
15     use vars qw($VERSION);
16 wakaba 1.4 $VERSION=do{my @r=(q$Revision: 1.3 $=~/\d+/g);sprintf "%d."."%02d" x $#r,@r};
17 wakaba 1.1 use base qw(Encode::Encoding);
18     require Encode::ISO2022;
19    
20     sub encode ($$;$) {
21     my ($obj, $str, $chk) = @_;
22     $_[1] = '' if $chk;
23     $str = &Encode::ISO2022::internal_to_iso2022 ($str, $obj->__2022_encode);
24     return $str;
25     }
26    
27     sub decode ($$;$) {
28     my ($obj, $str, $chk) = @_;
29     $_[1] = '' if $chk;
30     return &Encode::ISO2022::iso2022_to_internal ($str, $obj->__2022_decode);
31     }
32    
33     sub __2022__common ($) {
34     my $C = Encode::ISO2022->new_object;
35     $C->{option}->{designate_to}->{C0}->{default} = -1;
36     $C->{option}->{designate_to}->{C1}->{default} = -1;
37     $C->{option}->{designate_to}->{G94}->{default} = -1;
38     $C->{option}->{designate_to}->{G94}->{B} = -1;
39     $C->{option}->{designate_to}->{G94n}->{default} = -1;
40     $C->{option}->{designate_to}->{G96}->{default} = -1;
41     $C->{option}->{designate_to}->{G96n}->{default} = -1;
42     $C->{G1} = $Encode::ISO2022::CHARSET{G94}->{"\x7E"}; ## empty
43     $C->{option}->{reset}->{Gdesignation} = 0;
44     $C->{option}->{reset}->{Ginvoke} = 0;
45     $C;
46     }
47     sub __2022_encode ($) {
48     my $C = shift->__2022__common;
49     $C->{GR} = undef;
50     $C;
51     }
52     sub __2022_decode ($) {
53     my $C = shift->__2022__common;
54     $C;
55     }
56    
57 wakaba 1.4 sub __clone ($) {
58     my $self = shift;
59     bless {%$self}, ref $self;
60     };
61    
62 wakaba 1.1 package Encode::ISO2022::ISO646::ISO646basic1993;
63     use vars qw/@ISA/;
64     push @ISA, 'Encode::ISO2022::ISO646';
65     __PACKAGE__->Define (qw/ISO_646.basic:1983 ref csISO646basic1983/);
66    
67     =item ISO_646.basic:1983
68    
69     A coded character set of
70     basic code table of ISO/IEC 646 (only graphic characters, 02/00-07/14).
71     (Name: ISO_646.basic:1983 (RFC 1345), ref (RFC 1345), csISO646basic1983 (IANA))
72    
73     =cut
74    
75     sub __2022__common ($) {
76     my $C = shift->SUPER::__2022__common;
77     $C->{bit} = 7;
78     $C->{C0} = $Encode::ISO2022::CHARSET{C0}->{"\x7E"}; ## empty
79     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x21\x40"}; ## IR170
80     # 0x7E = undef
81     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x21\x40"}];
82     $C;
83     }
84    
85     package Encode::ISO2022::ISO646::INVARIANT;
86     use vars qw/@ISA/;
87     push @ISA, 'Encode::ISO2022::ISO646';
88     __PACKAGE__->Define (qw!INVARIANT csINVARIANT ISO/IEC646.BCT!);
89    
90     =item INVARIANT
91    
92     A coded character set of
93     basic code table of ISO/IEC 646 (with C0 set of ISO/IEC 6429).
94     (Name: INVARIANT (RFC 1345), csINVARIANT (IANA), ISO/IEC646.BCT)
95    
96     =cut
97    
98     sub __2022__common ($) {
99     my $C = shift->SUPER::__2022__common;
100     $C->{bit} = 7;
101     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x21\x40"}; ## IR170
102     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x21\x40"}];
103     $C;
104     }
105    
106     package Encode::ISO2022::ISO646::ISO646irv;
107     use vars qw/@ISA/;
108     push @ISA, 'Encode::ISO2022::ISO646';
109 wakaba 1.2 __PACKAGE__->Define (qw!ISO_646.irv:1983 iso-ir-2 irv csISO2IntlRefVersion ICS!);
110 wakaba 1.1
111     =item ISO_646.irv:1983
112    
113     International reference version (IRV) of ISO 646:1983.
114     (Name: ISO_646.irv:1983 (RFC 1345), iso-ir-2 (RFC 1345), irv (RFC 1345),
115 wakaba 1.2 csISO2IntlRefVersion (IANA), ICS)
116 wakaba 1.1
117     =cut
118    
119     sub __2022__common ($) {
120     my $C = shift->SUPER::__2022__common;
121     $C->{bit} = 7;
122     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x40"};
123     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
124     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x40"}];
125     $C;
126     }
127    
128     package Encode::ISO2022::ISO646::BS_4730;
129     use vars qw/@ISA/;
130     push @ISA, 'Encode::ISO2022::ISO646';
131     __PACKAGE__->Define (qw!BS_4730 iso-ir-4 ISO646-GB gb uk csISO4UnitedKingdom!);
132    
133     =item BS_4730
134    
135     BS 4730, a United Kingdom version of ISO/IEC 646.
136     (Name: BS_4730 (RFC 1345), iso-ir-4 (RFC 1345), ISO646-GB (RFC 1345),
137     gb (RFC 1345), uk (RFC 1345), csISO4UnitedKingdom (IANA))
138    
139     =cut
140    
141     sub __2022__common ($) {
142     my $C = shift->SUPER::__2022__common;
143     $C->{bit} = 7;
144     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x41"};
145     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
146     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x41"}];
147     $C;
148     }
149    
150     package Encode::ISO2022::ISO646::USASCII;
151     use vars qw/@ISA/;
152     push @ISA, 'Encode::ISO2022::ISO646';
153     #__PACKAGE__->Define (qw!ANSI_X3.4-1968 iso-ir-6 ANSI_X3.4-1986 ISO_646.irv:1991
154 wakaba 1.2 # ASCII ISO646-US US-ASCII us IBM367 cp367 csASCII
155     # 646 ASCII-7 ATF-8 CP20127 US_ASCII!);
156 wakaba 1.1
157     =item ANSI_X3.4-1968
158    
159     ANSI X3.4-1968 or ISO/IEC 646:1991 International reference version (IRV).
160     (Name: ANSI_X3.4-1968 (RFC 1345), iso-ir-6 (RFC 1345), ANSI_X3.4-1986 (RFC 1345),
161     ISO_646.irv:1991 (RFC 1345), ASCII (RFC 1345), ISO646-US (RFC 1345),
162     US-ASCII (RFC 1345), us (RFC 1345), IBM367 (RFC 1345), cp367 (RFC 1345),
163 wakaba 1.2 csASCII (IANA), 646, ASCII-7, ATF-8, CP20127 (M$), US_ASCII)
164 wakaba 1.1
165     Note that this coding system defined in this module is not used,
166     since perl standard Encode module already implement this.
167    
168     =cut
169    
170     sub __2022__common ($) {
171     my $C = shift->SUPER::__2022__common;
172     $C->{bit} = 7;
173     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x41"};
174     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
175     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x41"}];
176     $C;
177     }
178    
179     package Encode::ISO2022::ISO646::SEN_850200_B;
180     use vars qw/@ISA/;
181     push @ISA, 'Encode::ISO2022::ISO646';
182     __PACKAGE__->Define (qw!SEN_850200_B iso-ir-10 FI ISO646-FI ISO646-SE
183     csISO10Swedish!);
184    
185     =item SEN_850200_B
186    
187     SEN 850200 Appendix B, Swedish version of ISO/IEC 646.
188     (Name: SEN_850200_B (RFC 1345), iso-ir-10 (RFC 1345), FI (RFC 1345),
189     ISO646-FI (RFC 1345), ISO646-SE (RFC 1345), se (RFC 1345), csISO10Swedish (IANA))
190    
191     =cut
192    
193     sub __2022__common ($) {
194     my $C = shift->SUPER::__2022__common;
195     $C->{bit} = 7;
196     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x47"};
197     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
198     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x47"}];
199     $C;
200     }
201    
202     package Encode::ISO2022::ISO646::SEN_850200_C;
203     use vars qw/@ISA/;
204     push @ISA, 'Encode::ISO2022::ISO646';
205     __PACKAGE__->Define (qw!SEN_850200_C iso-ir-11 ISO646-SE2
206     csISO11SwedishForNames!);
207    
208     =item SEN_850200_C
209    
210     SEN 850200 Appendix C, Swedish version of ISO/IEC 646 for names.
211     (Name: SEN_850200_C (RFC 1345), iso-ir-11 (RFC 1345), ISO646-SE2 (RFC 1345),
212     csISO11SwedishForNames (IANA))
213    
214     =cut
215    
216     sub __2022__common ($) {
217     my $C = shift->SUPER::__2022__common;
218     $C->{bit} = 7;
219     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x48"};
220     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
221     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x48"}];
222     $C;
223     }
224    
225     package Encode::ISO2022::ISO646::IT;
226     use vars qw/@ISA/;
227     push @ISA, 'Encode::ISO2022::ISO646';
228     __PACKAGE__->Define (qw!IT iso-ir-15 ISO646-IT csISO15Italian!);
229    
230     =item IT
231    
232     Italic version of ISO/IEC 646.
233     (Name: IT (RFC 1345), iso-ir-15 (RFC 1345), ISO646-IT (RFC 1345),
234     csISO15Italian (IANA))
235    
236     =cut
237    
238     sub __2022__common ($) {
239     my $C = shift->SUPER::__2022__common;
240     $C->{bit} = 7;
241     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x59"};
242     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
243     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x59"}];
244     $C;
245     }
246    
247     package Encode::ISO2022::ISO646::PT;
248     use vars qw/@ISA/;
249     push @ISA, 'Encode::ISO2022::ISO646';
250     __PACKAGE__->Define (qw!PT iso-ir-16 ISO646-PT csISO16Portuguese!);
251    
252     =item PT
253    
254     Portuguese version of ISO/IEC 646.
255     (Name: PT (RFC 1345), iso-ir-16 (RFC 1345), ISO646-PT (RFC 1345),
256     csISO16Portuguese (IANA))
257    
258     =cut
259    
260     sub __2022__common ($) {
261     my $C = shift->SUPER::__2022__common;
262     $C->{bit} = 7;
263     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x4C"};
264     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
265     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x4C"}];
266     $C;
267     }
268    
269     package Encode::ISO2022::ISO646::ES;
270     use vars qw/@ISA/;
271     push @ISA, 'Encode::ISO2022::ISO646';
272     __PACKAGE__->Define (qw!ES iso-ir-17 ISO646-ES csISO17Spanish!);
273    
274     =item ES
275    
276     Spanish version of ISO/IEC 646.
277     (Name: ES (RFC 1345), iso-ir-17 (RFC 1345), ISO646-ES (RFC 1345),
278     csISO17Spanish (IANA))
279    
280     =cut
281    
282     sub __2022__common ($) {
283     my $C = shift->SUPER::__2022__common;
284     $C->{bit} = 7;
285     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x5A"};
286     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
287     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x5A"}];
288     $C;
289     }
290    
291     package Encode::ISO2022::ISO646::DIN_66003;
292     use vars qw/@ISA/;
293     push @ISA, 'Encode::ISO2022::ISO646';
294     __PACKAGE__->Define (qw!DIN_66003 iso-ir-21 de ISO646-de csISO21German!);
295    
296     =item DIN_66003
297    
298     DIN 66003, German version of ISO/IEC 646.
299     (Name: DIN_66003 (RFC 1345), iso-ir-21 (RFC 1345), de (RFC 1345),
300     ISO646-de (RFC 1345), csISO21German (IANA))
301    
302     =cut
303    
304     sub __2022__common ($) {
305     my $C = shift->SUPER::__2022__common;
306     $C->{bit} = 7;
307     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x4B"};
308     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
309     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x4B"}];
310     $C;
311     }
312    
313     package Encode::ISO2022::ISO646::DIN_66003;
314     use vars qw/@ISA/;
315     push @ISA, 'Encode::ISO2022::ISO646';
316     __PACKAGE__->Define (qw!NF_Z_62-010_(1973) iso-ir-25 ISO646-FR1 csISO25French!);
317    
318     =item NF_Z_62-010_(1973)
319    
320     NF Z 62-010 1973, French version of ISO/IEC 646.
321     (Name: NF_Z_62-010_(1973) (RFC 1345), iso-ir-25 (RFC 1345),
322     ISO646-FR1 (RFC 1345), csISO25French (IANA))
323    
324     =cut
325    
326     sub __2022__common ($) {
327     my $C = shift->SUPER::__2022__common;
328     $C->{bit} = 7;
329     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x52"};
330     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
331     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x52"}];
332     $C;
333     }
334    
335     package Encode::ISO2022::ISO646::GB_1988;
336     use vars qw/@ISA/;
337     push @ISA, 'Encode::ISO2022::ISO646';
338     __PACKAGE__->Define (qw!GB_1988-80 iso-ir-57 cn ISO646-cn csISO57GB1988!);
339    
340     =item GB_1988-80
341    
342     GB_1988-80, Chinese version of ISO/IEC 646.
343     (Name: GB_1988-80 (RFC 1345), iso-ir-57 (RFC 1345), cn (RFC 1345),
344     ISO646-cn (RFC 1345), csISO57GB1988 (IANA))
345    
346     =cut
347    
348     sub __2022__common ($) {
349     my $C = shift->SUPER::__2022__common;
350     $C->{bit} = 7;
351     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x54"};
352     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
353     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x54"}];
354     $C;
355     }
356    
357 wakaba 1.2 package Encode::ISO2022::ISO646::csISO60DanishNorwegian;
358     use vars qw/@ISA/;
359     push @ISA, 'Encode::ISO2022::ISO646';
360     __PACKAGE__->Define (qw! NS_4551-1 iso-ir-60 ISO646-NO no csISO60DanishNorwegian
361     csISO60Norwegian1!);
362    
363     =item NS_4551-1
364    
365     NS_4551-1, Norwegian version of ISO/IEC 646.
366     (Name: NS_4551-1 (RFC 1345), iso-ir-60 (RFC 1345), ISO646-NO (RFC 1345),
367     no (RFC 1345), csISO60DanishNorwegian (IANA), csISO60Norwegian1 (IANA))
368    
369     =cut
370    
371     sub __2022__common ($) {
372     my $C = shift->SUPER::__2022__common;
373     $C->{bit} = 7;
374     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x60"};
375     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
376     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x60"}];
377     $C;
378     }
379    
380     package Encode::ISO2022::ISO646::csISO61Norwegian2;
381     use vars qw/@ISA/;
382     push @ISA, 'Encode::ISO2022::ISO646';
383     __PACKAGE__->Define (qw! NS_4551-2 iso-ir-61 ISO646-NO2 no2 csISO61Norwegian2!);
384    
385     =item NS_4551-2
386    
387     NS_4551-2, Norwegian version of ISO/IEC 646.
388     (Name: NS_4551-2 (RFC 1345), iso-ir-61 (RFC 1345), ISO646-NO2 (RFC 1345),
389     no2 (RFC 1345), csISO61Norwegian2 (IANA))
390    
391     =cut
392    
393     sub __2022__common ($) {
394     my $C = shift->SUPER::__2022__common;
395     $C->{bit} = 7;
396     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x61"};
397     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
398     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x61"}];
399     $C;
400     }
401    
402     package Encode::ISO2022::ISO646::csISO69French;
403     use vars qw/@ISA/;
404     push @ISA, 'Encode::ISO2022::ISO646';
405     __PACKAGE__->Define (qw!NF_Z_62-010 iso-ir-69 ISO646-FR fr csISO69French!);
406    
407     =item NF_Z_62-010
408    
409     NF Z 62-010, French version of ISO/IEC 646.
410     (Name: NS_4551-2 (RFC 1345), iso-ir-69 (RFC 1345), ISO646-FR (RFC 1345),
411     fr (RFC 1345), csISO69French (IANA))
412    
413     =cut
414    
415     sub __2022__common ($) {
416     my $C = shift->SUPER::__2022__common;
417     $C->{bit} = 7;
418     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x66"};
419     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
420     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x66"}];
421     $C;
422     }
423    
424     package Encode::ISO2022::ISO646::PT2;
425     use vars qw/@ISA/;
426     push @ISA, 'Encode::ISO2022::ISO646';
427     __PACKAGE__->Define (qw!PT2 iso-ir-84 ISO646-PT2 csISO84Portuguese2!);
428    
429     =item PT2
430    
431     Portuguse version of ISO/IEC 646.
432     (Name: PT2 (RFC 1345), iso-ir-84 (RFC 1345), ISO646-PT2 (RFC 1345),
433     csISO84Portuguese2 (IANA))
434    
435     =cut
436    
437     sub __2022__common ($) {
438     my $C = shift->SUPER::__2022__common;
439     $C->{bit} = 7;
440     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x67"};
441     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
442     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x67"}];
443     $C;
444     }
445    
446     package Encode::ISO2022::ISO646::ES2;
447     use vars qw/@ISA/;
448     push @ISA, 'Encode::ISO2022::ISO646';
449     __PACKAGE__->Define (qw!ES2 iso-ir-85 ISO646-ES2 csISO85Spanish2!);
450    
451     =item ES2
452    
453     Spanish version of ISO/IEC 646.
454     (Name: ES2 (RFC 1345), iso-ir-85 (RFC 1345), ISO646-ES2 (RFC 1345),
455     csISO85Spanish2 (IANA))
456    
457     =cut
458    
459     sub __2022__common ($) {
460     my $C = shift->SUPER::__2022__common;
461     $C->{bit} = 7;
462     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x68"};
463     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
464     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x68"}];
465     $C;
466     }
467    
468     package Encode::ISO2022::ISO646::csISO86Hungarian;
469     use vars qw/@ISA/;
470     push @ISA, 'Encode::ISO2022::ISO646';
471     __PACKAGE__->Define (qw!MSZ_7795.3 iso-ir-86 ISO646-HU hu csISO86Hungarian!);
472    
473     =item MSZ_7795.3
474    
475     Hungarian version of ISO/IEC 646.
476     (Name: MSZ_7795.3 (RFC 1345), iso-ir-86 (RFC 1345), ISO646-HU (RFC 1345),
477     hu (RFC 1345), csISO86Hungarian (IANA))
478    
479     =cut
480    
481     sub __2022__common ($) {
482     my $C = shift->SUPER::__2022__common;
483     $C->{bit} = 7;
484     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x69"};
485     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
486     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x69"}];
487     $C;
488     }
489    
490     package Encode::ISO2022::ISO646::csISO121Canadian1;
491     use vars qw/@ISA/;
492     push @ISA, 'Encode::ISO2022::ISO646';
493     __PACKAGE__->Define (qw!CSA_Z243.4-1985-1 iso-ir-121 ISO646-CA csa7-1 ca
494     csISO121Canadian1!);
495    
496     =item CSA_Z243.4-1985-1
497    
498     Canadian version of ISO/IEC 646.
499     (Name: CSA_Z243.4-1985-1 (RFC 1345), iso-ir-121 (RFC 1345), ISO646-CA (RFC 1345),
500     csa7-1 (RFC 1345), ca (RFC 1345), csISO121Canadian1 (IANA))
501    
502     =cut
503    
504     sub __2022__common ($) {
505     my $C = shift->SUPER::__2022__common;
506     $C->{bit} = 7;
507     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x77"};
508     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
509     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x77"}];
510     $C;
511     }
512    
513     package Encode::ISO2022::ISO646::csISO122Canadian2;
514     use vars qw/@ISA/;
515     push @ISA, 'Encode::ISO2022::ISO646';
516     __PACKAGE__->Define (qw!CSA_Z243.4-1985-2 iso-ir-122 ISO646-CA2 csa7-2
517     csISO122Canadian2!);
518    
519     =item CSA_Z243.4-1985-2
520    
521     Canadian version of ISO/IEC 646.
522     (Name: CSA_Z243.4-1985-2 (RFC 1345), iso-ir-122 (RFC 1345), ISO646-CA2 (RFC 1345),
523     csa7-2 (RFC 1345), csISO122Canadian2 (IANA))
524    
525     =cut
526    
527     sub __2022__common ($) {
528     my $C = shift->SUPER::__2022__common;
529     $C->{bit} = 7;
530     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x78"};
531     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
532     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x78"}];
533     $C;
534     }
535    
536     package Encode::ISO2022::ISO646::csISO122Canadian2;
537     use vars qw/@ISA/;
538     push @ISA, 'Encode::ISO2022::ISO646';
539     __PACKAGE__->Define (qw!JUS_I.B1.0022 iso-ir-141 ISO646-YU js yu
540     csISO141JUSIB1002!);
541    
542     =item JUS_I.B1.002
543    
544     Canadian version of ISO/IEC 646.
545     (Name: JUS_I.B1.002 (RFC 1345), iso-ir-141 (RFC 1345), ISO646-YU (RFC 1345),
546     js (RFC 1345), yu (RFC 1345), csISO141JUSIB1002 (IANA))
547    
548     =cut
549    
550     sub __2022__common ($) {
551     my $C = shift->SUPER::__2022__common;
552     $C->{bit} = 7;
553     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x7A"};
554     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
555     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x7A"}];
556     $C;
557     }
558    
559     package Encode::ISO2022::ISO646::csISO151Cuba;
560     use vars qw/@ISA/;
561     push @ISA, 'Encode::ISO2022::ISO646';
562     __PACKAGE__->Define (qw!NC_NC00-10:81 cuba iso-ir-151ISO646-CU
563     csISO151Cuba!);
564    
565     =item NC_NC00-10:81
566    
567     Canadian version of ISO/IEC 646.
568     (Name: NC_NC00-10:81 (RFC 1345), cuba (RFC 1345), iso-ir-151 (RFC 1345),
569     ISO646-CU (RFC 1345), csISO151Cuba (IANA))
570    
571     =cut
572    
573     sub __2022__common ($) {
574     my $C = shift->SUPER::__2022__common;
575     $C->{bit} = 7;
576     $C->{G0} = $Encode::ISO2022::CHARSET{G94}->{"\x21\x41"};
577     $C->{G1} = $C->{G0}; $C->{G2} = $C->{G1}; $C->{G3} = $C->{G1};
578     $C->{option}->{undef_char} = ["\x3F", {type => 'G94', charset => "\x21\x41"}];
579     $C;
580     }
581    
582     # DS_2089 DS2089 ISO646-DK dk csISO646Danish (IANA)
583     ## Not in ISOREG
584     # KSC5636 ISO646-KR csKSC5636 (IANA)
585     ## Not in ISOREG
586 wakaba 1.1
587     1;
588     __END__
589    
590     =back
591    
592 wakaba 1.3 =head1 AUTHORS
593    
594     Nanashi-san
595    
596     Wakaba <w@suika.fam.cx>
597    
598 wakaba 1.1 =head1 LICENSE
599    
600 wakaba 1.3 Copyright 2002 Authors
601 wakaba 1.1
602     This library is free software; you can redistribute it
603     and/or modify it under the same terms as Perl itself.
604    
605     =cut
606    
607 wakaba 1.4 # $Date: 2002/09/23 10:36:03 $
608 wakaba 1.2 ### ISO646.pm ends here

admin@suikawiki.org
ViewVC Help
Powered by ViewVC 1.1.24