line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Data::Localize::Format::Maketext; |
2
|
3
|
|
|
3
|
|
2391
|
use Moo; |
|
3
|
|
|
|
|
42
|
|
|
3
|
|
|
|
|
25
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
extends 'Data::Localize::Format'; |
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
sub format { |
7
|
7
|
|
|
7
|
1
|
133
|
my ($self, $lang, $value, @args) = @_; |
8
|
|
|
|
|
|
|
|
9
|
7
|
|
|
|
|
64
|
$value =~ s|\[([^\]]+)\]| |
10
|
7
|
|
|
|
|
33
|
my @vars = split(/,/, $1); |
11
|
7
|
|
|
|
|
13
|
my $method; |
12
|
7
|
50
|
|
|
|
170
|
if ($vars[0] !~ /^_(-?\d+)$/) { |
13
|
0
|
|
|
|
|
0
|
$method = shift @vars; |
14
|
|
|
|
|
|
|
} |
15
|
|
|
|
|
|
|
|
16
|
0
|
0
|
|
|
|
0
|
($method) ? |
17
|
7
|
50
|
|
|
|
77
|
$self->$method( $lang, map { (/^_(-?\d+)$/) ? $args[$1 - 1] : $_; } @args ) : |
18
|
7
|
50
|
|
|
|
24
|
@args[ map { (/^_(-?\d+)$/ ? $1 : $_) - 1 } @vars ]; |
19
|
|
|
|
|
|
|
|gex; |
20
|
|
|
|
|
|
|
|
21
|
7
|
|
|
|
|
55
|
return $value; |
22
|
|
|
|
|
|
|
} |
23
|
|
|
|
|
|
|
|
24
|
|
|
|
|
|
|
1; |
25
|
|
|
|
|
|
|
|
26
|
|
|
|
|
|
|
__END__ |