line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Lingua::EO::Supersignoj; |
2
|
1
|
|
|
1
|
|
64505
|
use Attribute::Property; |
|
1
|
|
|
|
|
11788
|
|
|
1
|
|
|
|
|
30
|
|
3
|
1
|
|
|
1
|
|
9
|
use strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
22
|
|
4
|
1
|
|
|
1
|
|
963
|
use utf8; |
|
1
|
|
|
|
|
15
|
|
|
1
|
|
|
|
|
5
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
our $VERSION = '0.02'; |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
our %cxapeloj = ( |
9
|
|
|
|
|
|
|
h => [ qw/ Ch ch Gh gh Hh hh Jh jh Sh sh Uw uw / ], |
10
|
|
|
|
|
|
|
H => [ qw/ CH ch GH gh HH hh JH jh SH sh UW uw / ], |
11
|
|
|
|
|
|
|
x => [ qw/ Cx cx Gx gx Hx hx Jx jx Sx sx Ux ux / ], |
12
|
|
|
|
|
|
|
X => [ qw/ CX cx GX gx HX hx JX jx SX sx UX ux / ], |
13
|
|
|
|
|
|
|
poste => [ qw/ C^ c^ G^ g^ H^ h^ J^ j^ S^ s^ U^ u^ / ], |
14
|
|
|
|
|
|
|
fronte => [ qw/ ^C ^c ^G ^g ^H ^h ^J ^j ^S ^s ^U ^u / ], |
15
|
|
|
|
|
|
|
apostrofoj => [ qw/ C' c' G' g' H' h' J' j' S' s' U' u' / ], |
16
|
|
|
|
|
|
|
iso => [ map chr, |
17
|
|
|
|
|
|
|
198, 230, 216, 248, 166, 182, 172, 188, 222, 254, 221, 253 ], |
18
|
|
|
|
|
|
|
unikodo => [ map chr, |
19
|
|
|
|
|
|
|
264, 265, 284, 285, 292, 293, 308, 309, 348, 349, 364, 365 ] |
20
|
|
|
|
|
|
|
); |
21
|
|
|
|
|
|
|
|
22
|
1
|
|
|
1
|
|
169
|
sub nova : New; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
4
|
|
23
|
1
|
|
|
1
|
|
168
|
sub de : Property { exists $cxapeloj{$_} } |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
98
|
|
24
|
1
|
|
|
1
|
|
155
|
sub al : Property { exists $cxapeloj{$_} } |
|
1
|
|
|
|
|
1
|
|
|
1
|
|
|
|
|
3
|
|
|
9
|
|
|
|
|
879
|
|
25
|
1
|
0
|
|
1
|
|
168
|
sub u : Property { $_ = [ $_ ] if not ref $_; ref $_ eq 'ARRAY' or !defined } |
|
1
|
0
|
|
|
|
1
|
|
|
1
|
|
|
|
|
3
|
|
|
0
|
|
|
|
|
0
|
|
|
0
|
|
|
|
|
0
|
|
26
|
1
|
0
|
|
1
|
|
148
|
sub U : Property { $_ = [ $_ ] if not ref $_; ref $_ eq 'ARRAY' or !defined } |
|
1
|
0
|
|
|
|
1
|
|
|
1
|
|
|
|
|
8
|
|
|
0
|
|
|
|
|
0
|
|
|
0
|
|
|
|
|
0
|
|
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
sub transkodigu { |
29
|
9
|
|
|
9
|
1
|
67
|
my ($mem, @tekstoj) = (@_); |
30
|
9
|
|
|
|
|
22
|
my ($de, $al, $u, $U) = ($mem->de, $mem->al, $mem->u, $mem->U); |
31
|
9
|
50
|
33
|
|
|
375
|
$U = [ map uc, @$u ] if $u and not $U; |
32
|
9
|
50
|
33
|
|
|
18
|
$u = [ map lc, @$U ] if $U and not $u; |
33
|
9
|
|
50
|
|
|
15
|
$de ||= 'X'; |
34
|
9
|
|
50
|
|
|
14
|
$al ||= 'unikodo'; |
35
|
0
|
|
|
|
|
0
|
my $modelfolio = join '|', map quotemeta, |
36
|
|
|
|
|
|
|
$u |
37
|
9
|
|
|
|
|
61
|
? (@{ $cxapeloj{$de} }[ 0 .. 9 ], @$u) |
38
|
9
|
50
|
|
|
|
14
|
: @{ $cxapeloj{$de} }; |
39
|
108
|
|
|
|
|
3241
|
my %transkodotabelo = |
40
|
9
|
|
|
|
|
21
|
map { ($cxapeloj{$de}[$_] => $cxapeloj{$al}[$_]) } 0 .. 11; |
41
|
9
|
50
|
|
|
|
27
|
if ($u) { |
42
|
0
|
|
|
|
|
0
|
delete @transkodotabelo{ @{ $cxapeloj{$de} }[10, 11] }; |
|
0
|
|
|
|
|
0
|
|
43
|
0
|
|
|
|
|
0
|
$transkodotabelo{$_} = $cxapeloj{$al}[10] for @$U; |
44
|
0
|
|
|
|
|
0
|
$transkodotabelo{$_} = $cxapeloj{$al}[11] for @$u; |
45
|
|
|
|
|
|
|
} |
46
|
9
|
|
|
|
|
11
|
@tekstoj = map { $_ =~ s/($modelfolio)/$transkodotabelo{$1}/g; $_ } @tekstoj; |
|
9
|
|
|
|
|
192
|
|
|
9
|
|
|
|
|
512
|
|
47
|
9
|
50
|
|
|
|
56
|
return wantarray ? @tekstoj : $tekstoj[-1]; |
48
|
|
|
|
|
|
|
} |
49
|
|
|
|
|
|
|
|
50
|
|
|
|
|
|
|
1; |
51
|
|
|
|
|
|
|
|
52
|
|
|
|
|
|
|
__END__ |