line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package Tie::UrlEncoder; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
6480
|
use 5.006; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
40
|
|
4
|
1
|
|
|
1
|
|
6
|
no warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
124
|
|
5
|
|
|
|
|
|
|
|
6
|
|
|
|
|
|
|
our $VERSION = '0.02'; |
7
|
|
|
|
|
|
|
|
8
|
|
|
|
|
|
|
# sub PACK(){0}; |
9
|
|
|
|
|
|
|
sub KEY(){1}; |
10
|
|
|
|
|
|
|
# sub VALUE(){2}; |
11
|
|
|
|
|
|
|
my $b; |
12
|
1
|
|
|
1
|
|
1619
|
sub TIEHASH{bless \$b} |
13
|
|
|
|
|
|
|
sub FETCH{ |
14
|
1
|
|
|
1
|
|
119
|
my $result = $_[KEY]; |
15
|
1
|
|
|
1
|
|
997
|
use bytes; |
|
1
|
|
|
|
|
14
|
|
|
1
|
|
|
|
|
6
|
|
16
|
1
|
|
|
|
|
8
|
$result =~ s{([^ 0-9a-zA-Z\$\-_\.\!\*\(\)\,])} |
17
|
5
|
|
|
|
|
24
|
{sprintf("%%%02X",ord($1))}ge; |
18
|
1
|
|
|
1
|
|
81
|
no bytes; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
4
|
|
19
|
1
|
|
|
|
|
4
|
$result =~ tr/ /+/; |
20
|
1
|
|
|
|
|
7
|
$result |
21
|
|
|
|
|
|
|
} |
22
|
|
|
|
|
|
|
|
23
|
1
|
|
|
1
|
|
54
|
sub import{ no strict; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
60
|
|
24
|
1
|
|
|
1
|
|
6
|
tie %{caller().'::urlencode'}, __PACKAGE__ |
|
1
|
|
|
|
|
8
|
|
25
|
|
|
|
|
|
|
} |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
1; |
29
|
|
|
|
|
|
|
__END__ |