line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
# automatically generated file, don't edit |
2
|
|
|
|
|
|
|
|
3
|
|
|
|
|
|
|
|
4
|
|
|
|
|
|
|
|
5
|
|
|
|
|
|
|
# Copyright 2023 David Cantrell, derived from data from libphonenumber |
6
|
|
|
|
|
|
|
# http://code.google.com/p/libphonenumber/ |
7
|
|
|
|
|
|
|
# |
8
|
|
|
|
|
|
|
# Licensed under the Apache License, Version 2.0 (the "License"); |
9
|
|
|
|
|
|
|
# you may not use this file except in compliance with the License. |
10
|
|
|
|
|
|
|
# You may obtain a copy of the License at |
11
|
|
|
|
|
|
|
# |
12
|
|
|
|
|
|
|
# http://www.apache.org/licenses/LICENSE-2.0 |
13
|
|
|
|
|
|
|
# |
14
|
|
|
|
|
|
|
# Unless required by applicable law or agreed to in writing, software |
15
|
|
|
|
|
|
|
# distributed under the License is distributed on an "AS IS" BASIS, |
16
|
|
|
|
|
|
|
# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
17
|
|
|
|
|
|
|
# See the License for the specific language governing permissions and |
18
|
|
|
|
|
|
|
# limitations under the License. |
19
|
|
|
|
|
|
|
package Number::Phone::StubCountry::KW; |
20
|
2
|
|
|
2
|
|
1099
|
use base qw(Number::Phone::StubCountry); |
|
2
|
|
|
|
|
5
|
|
|
2
|
|
|
|
|
212
|
|
21
|
|
|
|
|
|
|
|
22
|
2
|
|
|
2
|
|
15
|
use strict; |
|
2
|
|
|
|
|
6
|
|
|
2
|
|
|
|
|
44
|
|
23
|
2
|
|
|
2
|
|
12
|
use warnings; |
|
2
|
|
|
|
|
6
|
|
|
2
|
|
|
|
|
49
|
|
24
|
2
|
|
|
2
|
|
11
|
use utf8; |
|
2
|
|
|
|
|
4
|
|
|
2
|
|
|
|
|
12
|
|
25
|
|
|
|
|
|
|
our $VERSION = 1.20230903131447; |
26
|
|
|
|
|
|
|
|
27
|
|
|
|
|
|
|
my $formatters = [ |
28
|
|
|
|
|
|
|
{ |
29
|
|
|
|
|
|
|
'format' => '$1 $2', |
30
|
|
|
|
|
|
|
'leading_digits' => ' |
31
|
|
|
|
|
|
|
[169]| |
32
|
|
|
|
|
|
|
2(?: |
33
|
|
|
|
|
|
|
[235]| |
34
|
|
|
|
|
|
|
4[1-35-9] |
35
|
|
|
|
|
|
|
)| |
36
|
|
|
|
|
|
|
52 |
37
|
|
|
|
|
|
|
', |
38
|
|
|
|
|
|
|
'pattern' => '(\\d{4})(\\d{3,4})' |
39
|
|
|
|
|
|
|
}, |
40
|
|
|
|
|
|
|
{ |
41
|
|
|
|
|
|
|
'format' => '$1 $2', |
42
|
|
|
|
|
|
|
'leading_digits' => '[245]', |
43
|
|
|
|
|
|
|
'pattern' => '(\\d{3})(\\d{5})' |
44
|
|
|
|
|
|
|
} |
45
|
|
|
|
|
|
|
]; |
46
|
|
|
|
|
|
|
|
47
|
|
|
|
|
|
|
my $validators = { |
48
|
|
|
|
|
|
|
'fixed_line' => ' |
49
|
|
|
|
|
|
|
2(?: |
50
|
|
|
|
|
|
|
[23]\\d\\d| |
51
|
|
|
|
|
|
|
4(?: |
52
|
|
|
|
|
|
|
[1-35-9]\\d| |
53
|
|
|
|
|
|
|
44 |
54
|
|
|
|
|
|
|
)| |
55
|
|
|
|
|
|
|
5(?: |
56
|
|
|
|
|
|
|
0[034]| |
57
|
|
|
|
|
|
|
[2-46]\\d| |
58
|
|
|
|
|
|
|
5[1-3]| |
59
|
|
|
|
|
|
|
7[1-7] |
60
|
|
|
|
|
|
|
) |
61
|
|
|
|
|
|
|
)\\d{4} |
62
|
|
|
|
|
|
|
', |
63
|
|
|
|
|
|
|
'geographic' => ' |
64
|
|
|
|
|
|
|
2(?: |
65
|
|
|
|
|
|
|
[23]\\d\\d| |
66
|
|
|
|
|
|
|
4(?: |
67
|
|
|
|
|
|
|
[1-35-9]\\d| |
68
|
|
|
|
|
|
|
44 |
69
|
|
|
|
|
|
|
)| |
70
|
|
|
|
|
|
|
5(?: |
71
|
|
|
|
|
|
|
0[034]| |
72
|
|
|
|
|
|
|
[2-46]\\d| |
73
|
|
|
|
|
|
|
5[1-3]| |
74
|
|
|
|
|
|
|
7[1-7] |
75
|
|
|
|
|
|
|
) |
76
|
|
|
|
|
|
|
)\\d{4} |
77
|
|
|
|
|
|
|
', |
78
|
|
|
|
|
|
|
'mobile' => ' |
79
|
|
|
|
|
|
|
(?: |
80
|
|
|
|
|
|
|
41\\d\\d| |
81
|
|
|
|
|
|
|
5(?: |
82
|
|
|
|
|
|
|
(?: |
83
|
|
|
|
|
|
|
[05]\\d| |
84
|
|
|
|
|
|
|
1[0-7]| |
85
|
|
|
|
|
|
|
6[56] |
86
|
|
|
|
|
|
|
)\\d| |
87
|
|
|
|
|
|
|
2(?: |
88
|
|
|
|
|
|
|
22| |
89
|
|
|
|
|
|
|
5[25] |
90
|
|
|
|
|
|
|
)| |
91
|
|
|
|
|
|
|
7(?: |
92
|
|
|
|
|
|
|
55| |
93
|
|
|
|
|
|
|
77 |
94
|
|
|
|
|
|
|
)| |
95
|
|
|
|
|
|
|
88[58] |
96
|
|
|
|
|
|
|
)| |
97
|
|
|
|
|
|
|
6(?: |
98
|
|
|
|
|
|
|
(?: |
99
|
|
|
|
|
|
|
0[034679]| |
100
|
|
|
|
|
|
|
5[015-9]| |
101
|
|
|
|
|
|
|
6\\d |
102
|
|
|
|
|
|
|
)\\d| |
103
|
|
|
|
|
|
|
1(?: |
104
|
|
|
|
|
|
|
00| |
105
|
|
|
|
|
|
|
11| |
106
|
|
|
|
|
|
|
66 |
107
|
|
|
|
|
|
|
)| |
108
|
|
|
|
|
|
|
222| |
109
|
|
|
|
|
|
|
3[36]3| |
110
|
|
|
|
|
|
|
444| |
111
|
|
|
|
|
|
|
7(?: |
112
|
|
|
|
|
|
|
0[013-9]| |
113
|
|
|
|
|
|
|
[67]\\d |
114
|
|
|
|
|
|
|
)| |
115
|
|
|
|
|
|
|
888| |
116
|
|
|
|
|
|
|
9(?: |
117
|
|
|
|
|
|
|
[069]\\d| |
118
|
|
|
|
|
|
|
3[039] |
119
|
|
|
|
|
|
|
) |
120
|
|
|
|
|
|
|
)| |
121
|
|
|
|
|
|
|
9(?: |
122
|
|
|
|
|
|
|
(?: |
123
|
|
|
|
|
|
|
0[09]| |
124
|
|
|
|
|
|
|
[4679]\\d| |
125
|
|
|
|
|
|
|
8[057-9] |
126
|
|
|
|
|
|
|
)\\d| |
127
|
|
|
|
|
|
|
1(?: |
128
|
|
|
|
|
|
|
1[01]| |
129
|
|
|
|
|
|
|
99 |
130
|
|
|
|
|
|
|
)| |
131
|
|
|
|
|
|
|
2(?: |
132
|
|
|
|
|
|
|
00| |
133
|
|
|
|
|
|
|
2\\d |
134
|
|
|
|
|
|
|
)| |
135
|
|
|
|
|
|
|
3(?: |
136
|
|
|
|
|
|
|
00| |
137
|
|
|
|
|
|
|
3[03] |
138
|
|
|
|
|
|
|
)| |
139
|
|
|
|
|
|
|
5(?: |
140
|
|
|
|
|
|
|
00| |
141
|
|
|
|
|
|
|
5\\d |
142
|
|
|
|
|
|
|
) |
143
|
|
|
|
|
|
|
) |
144
|
|
|
|
|
|
|
)\\d{4} |
145
|
|
|
|
|
|
|
', |
146
|
|
|
|
|
|
|
'pager' => '', |
147
|
|
|
|
|
|
|
'personal_number' => '', |
148
|
|
|
|
|
|
|
'specialrate' => '', |
149
|
|
|
|
|
|
|
'toll_free' => '18\\d{5}', |
150
|
|
|
|
|
|
|
'voip' => '' |
151
|
|
|
|
|
|
|
}; |
152
|
|
|
|
|
|
|
|
153
|
|
|
|
|
|
|
sub new { |
154
|
10
|
|
|
10
|
1
|
26
|
my $class = shift; |
155
|
10
|
|
|
|
|
21
|
my $number = shift; |
156
|
10
|
|
|
|
|
63
|
$number =~ s/(^\+965|\D)//g; |
157
|
10
|
|
|
|
|
48
|
my $self = bless({ country_code => '965', number => $number, formatters => $formatters, validators => $validators, }, $class); |
158
|
10
|
100
|
|
|
|
50
|
return $self->is_valid() ? $self : undef; |
159
|
|
|
|
|
|
|
} |
160
|
|
|
|
|
|
|
1; |