line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package String::Normal::Type; |
2
|
9
|
|
|
9
|
|
35
|
use strict; |
|
9
|
|
|
|
|
12
|
|
|
9
|
|
|
|
|
198
|
|
3
|
9
|
|
|
9
|
|
29
|
use warnings; |
|
9
|
|
|
|
|
10
|
|
|
9
|
|
|
|
|
168
|
|
4
|
|
|
|
|
|
|
|
5
|
9
|
|
|
9
|
|
3450
|
use String::Normal::Type::Business; |
|
9
|
|
|
|
|
12
|
|
|
9
|
|
|
|
|
220
|
|
6
|
9
|
|
|
9
|
|
3516
|
use String::Normal::Type::Address; |
|
9
|
|
|
|
|
14
|
|
|
9
|
|
|
|
|
215
|
|
7
|
9
|
|
|
9
|
|
3102
|
use String::Normal::Type::Phone; |
|
9
|
|
|
|
|
15
|
|
|
9
|
|
|
|
|
183
|
|
8
|
9
|
|
|
9
|
|
3056
|
use String::Normal::Type::State; |
|
9
|
|
|
|
|
15
|
|
|
9
|
|
|
|
|
174
|
|
9
|
9
|
|
|
9
|
|
3016
|
use String::Normal::Type::City; |
|
9
|
|
|
|
|
14
|
|
|
9
|
|
|
|
|
198
|
|
10
|
9
|
|
|
9
|
|
2994
|
use String::Normal::Type::Zip; |
|
9
|
|
|
|
|
12
|
|
|
9
|
|
|
|
|
187
|
|
11
|
9
|
|
|
9
|
|
3114
|
use String::Normal::Type::Title; |
|
9
|
|
|
|
|
15
|
|
|
9
|
|
|
|
|
785
|
|
12
|
|
|
|
|
|
|
|
13
|
|
|
|
|
|
|
sub _scrub_value { |
14
|
23
|
|
|
23
|
|
29
|
my $value = shift; |
15
|
|
|
|
|
|
|
|
16
|
23
|
|
|
|
|
36
|
$value = _deaccent_value( $value ); |
17
|
23
|
|
|
|
|
24
|
$value =~ tr/'//d; |
18
|
|
|
|
|
|
|
|
19
|
|
|
|
|
|
|
# replace all rejected charactes with space |
20
|
23
|
|
|
|
|
88
|
$value =~ s/[^a-z0-9#]/ /g; |
21
|
|
|
|
|
|
|
|
22
|
23
|
|
|
|
|
51
|
return $value |
23
|
|
|
|
|
|
|
} |
24
|
|
|
|
|
|
|
|
25
|
|
|
|
|
|
|
sub _deaccent_value { |
26
|
23
|
|
|
23
|
|
24
|
my $value = shift; |
27
|
|
|
|
|
|
|
|
28
|
|
|
|
|
|
|
# remove decorations and stem variations of single quotes |
29
|
23
|
|
|
|
|
30
|
$value =~ tr[àáâãäåæçèéêëìíîïñòóôõöøùúûüýÿ’`\x92] |
30
|
|
|
|
|
|
|
[aaaaaaaceeeeiiiinoooooouuuuyy''']; |
31
|
|
|
|
|
|
|
|
32
|
23
|
|
|
|
|
36
|
return $value; |
33
|
|
|
|
|
|
|
} |
34
|
|
|
|
|
|
|
|
35
|
|
|
|
|
|
|
1; |
36
|
|
|
|
|
|
|
|
37
|
|
|
|
|
|
|
__END__ |