a3c4f60810594ce536df3cd538b3a6dddf08a1df
[platform/upstream/libphonenumber.git] / resources / PhoneNumberMetadata.xml
1 <!-- Copyright (C) 2009 The Libphonenumber Authors
2
3      Licensed under the Apache License, Version 2.0 (the "License");
4      you may not use this file except in compliance with the License.
5      You may obtain a copy of the License at
6
7      http://www.apache.org/licenses/LICENSE-2.0
8
9      Unless required by applicable law or agreed to in writing, software
10      distributed under the License is distributed on an "AS IS" BASIS,
11      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12      See the License for the specific language governing permissions and
13      limitations under the License.
14
15      @author: Shaopeng Jia
16
17      Metadata on Phone Number Plan and formatting rules
18      Note: Territories are in alphabetical order by their IDs, which are based on ISO 3166-1
19            two-letter country codes (or are set to "001" for non-geographical entities, which
20            represents "World" in the UN M.49 standard). The country names in the comments are the
21            official short names in English according to ISO 3166-1.
22
23      For more information on what each element represents, see
24      resources/phonemetadata.proto
25
26      Note that if you want to add validation metadata, the generalDesc nationalNumberPattern and
27      possibleNumberPattern must be provided. If this is missing, then the country will be
28      considered to have no more specific phone-number type metadata (fixedLine, mobile etc) and
29      hence only basic validation rules (numbers should be between 3 and 15 digits long) will be
30      applied.
31
32      If adding an element for a non-geographical entity, please add an example number element to the
33      general description.
34
35      Country code, international and national prefix information main source:
36      http://www.itu.int/pub/T-SP-E.164C-2011
37 -->
38
39 <!DOCTYPE phoneNumberMetadata [
40     <!ELEMENT phoneNumberMetadata (territories)>
41     <!ELEMENT territories (territory+)>
42     <!ELEMENT territory (references?, availableFormats?, generalDesc?, noInternationalDialling?,
43         areaCodeOptional?, fixedLine?, mobile?, pager?, tollFree?, premiumRate?,
44         sharedCost?, personalNumber?, voip?, uan?, voicemail?)>
45     <!ELEMENT references (sourceUrl+)>
46     <!ELEMENT generalDesc (nationalNumberPattern, possibleNumberPattern, exampleNumber?)>
47     <!ELEMENT noInternationalDialling (nationalNumberPattern, possibleNumberPattern?,
48         exampleNumber?)>
49     <!ELEMENT areaCodeOptional (nationalNumberPattern, possibleNumberPattern, exampleNumber?)>
50     <!ELEMENT fixedLine (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
51     <!ELEMENT mobile (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
52     <!ELEMENT pager (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
53     <!ELEMENT tollFree (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
54     <!ELEMENT premiumRate (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
55     <!ELEMENT sharedCost (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
56     <!ELEMENT personalNumber (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
57     <!ELEMENT voip (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
58     <!ELEMENT uan (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
59     <!ELEMENT voicemail (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
60     <!ELEMENT sourceUrl (#PCDATA)>
61     <!ELEMENT availableFormats (numberFormat+)>
62     <!ELEMENT nationalNumberPattern (#PCDATA)>
63     <!ELEMENT possibleNumberPattern (#PCDATA)>
64     <!ELEMENT exampleNumber (#PCDATA)>
65     <!ELEMENT numberFormat (leadingDigits*, format, intlFormat*)>
66     <!ELEMENT format (#PCDATA)>
67     <!ELEMENT intlFormat (#PCDATA)>
68     <!ELEMENT leadingDigits (#PCDATA)>
69
70     <!ATTLIST territory id CDATA #REQUIRED>
71     <!ATTLIST territory countryCode CDATA #REQUIRED>
72     <!ATTLIST territory mainCountryForCode (true) #IMPLIED>
73     <!ATTLIST territory leadingDigits CDATA #IMPLIED>
74     <!ATTLIST territory preferredInternationalPrefix CDATA #IMPLIED>
75     <!ATTLIST territory internationalPrefix CDATA #IMPLIED>
76     <!ATTLIST territory nationalPrefix CDATA #IMPLIED>
77     <!ATTLIST territory nationalPrefixForParsing CDATA #IMPLIED>
78     <!ATTLIST territory nationalPrefixTransformRule CDATA #IMPLIED>
79     <!ATTLIST territory preferredExtnPrefix CDATA #IMPLIED>
80     <!ATTLIST territory nationalPrefixFormattingRule CDATA #IMPLIED>
81     <!ATTLIST territory nationalPrefixOptionalWhenFormatting (true) #IMPLIED>
82     <!ATTLIST territory leadingZeroPossible (true) #IMPLIED>
83     <!ATTLIST territory carrierCodeFormattingRule CDATA #IMPLIED>
84     <!ATTLIST territory mobileNumberPortableRegion (true) #IMPLIED>
85     <!ATTLIST numberFormat nationalPrefixFormattingRule CDATA #IMPLIED>
86     <!ATTLIST numberFormat nationalPrefixOptionalWhenFormatting (true) #IMPLIED>
87     <!ATTLIST numberFormat carrierCodeFormattingRule CDATA #IMPLIED>
88     <!ATTLIST numberFormat pattern CDATA #REQUIRED>
89 ]>
90
91 <phoneNumberMetadata>
92   <territories>
93     <!-- Ascension Island -->
94     <territory id="AC" countryCode="247" internationalPrefix="00">
95       <references>
96         <sourceUrl>http://www.itu.int/oth/T02020000AF/en</sourceUrl>
97       </references>
98       <!-- Formatted as a block. -->
99       <generalDesc>
100         <nationalNumberPattern>[2-7]\d{3,5}</nationalNumberPattern>
101         <possibleNumberPattern>\d{4,6}</possibleNumberPattern>
102       </generalDesc>
103       <fixedLine>
104         <nationalNumberPattern>
105           (?:
106             [267]\d|
107             3[0-5]|
108             4[4-69]
109           )\d{2}
110         </nationalNumberPattern>
111         <possibleNumberPattern>\d{4}</possibleNumberPattern>
112         <exampleNumber>6889</exampleNumber>
113       </fixedLine>
114       <mobile>
115         <nationalNumberPattern>5\d{5}</nationalNumberPattern>
116         <possibleNumberPattern>\d{6}</possibleNumberPattern>
117         <exampleNumber>501234</exampleNumber>
118       </mobile>
119     </territory>
120
121     <!-- Andorra -->
122     <territory id="AD" countryCode="376" internationalPrefix="00">
123       <references>
124         <sourceUrl>http://www.itu.int/oth/T0202000005/en</sourceUrl>
125       </references>
126       <availableFormats>
127         <numberFormat pattern="(\d{3})(\d{3})">
128           <leadingDigits>[346-9]</leadingDigits>
129           <format>$1 $2</format>
130         </numberFormat>
131         <numberFormat pattern="(180[02])(\d{4})">
132           <leadingDigits>1</leadingDigits>
133           <format>$1 $2</format>
134         </numberFormat>
135       </availableFormats>
136       <generalDesc>
137         <nationalNumberPattern>
138           (?:
139             [346-9]|
140             180
141           )\d{5}
142         </nationalNumberPattern>
143         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
144       </generalDesc>
145       <fixedLine>
146         <nationalNumberPattern>[78]\d{5}</nationalNumberPattern>
147         <possibleNumberPattern>\d{6}</possibleNumberPattern>
148         <exampleNumber>712345</exampleNumber>
149       </fixedLine>
150       <mobile>
151         <nationalNumberPattern>[346]\d{5}</nationalNumberPattern>
152         <possibleNumberPattern>\d{6}</possibleNumberPattern>
153         <exampleNumber>312345</exampleNumber>
154       </mobile>
155       <tollFree>
156         <!-- Note that the definitions of 1800 and 1802 numbers differ in the plan and on the
157              Andorran http://www.sta.ad website, but we consider both to be freephone here. -->
158         <nationalNumberPattern>180[02]\d{4}</nationalNumberPattern>
159         <possibleNumberPattern>\d{8}</possibleNumberPattern>
160         <exampleNumber>18001234</exampleNumber>
161       </tollFree>
162       <!-- The national numbering plan says that numbers beginning with 9 are reserved for special
163            services, so we assume they are premium rate here, although we cannot find examples
164            online. -->
165       <premiumRate>
166         <nationalNumberPattern>9\d{5}</nationalNumberPattern>
167         <possibleNumberPattern>\d{6}</possibleNumberPattern>
168         <exampleNumber>912345</exampleNumber>
169       </premiumRate>
170     </territory>
171
172     <!-- United Arab Emirates -->
173     <territory id="AE" countryCode="971" internationalPrefix="00"
174                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
175       <references>
176         <sourceUrl>http://www.itu.int/oth/T02020000DC/en</sourceUrl>
177       </references>
178       <availableFormats>
179         <numberFormat pattern="([2-4679])(\d{3})(\d{4})">
180           <leadingDigits>[2-4679][2-8]</leadingDigits>
181           <format>$1 $2 $3</format>
182         </numberFormat>
183         <numberFormat pattern="(5[0256])(\d{3})(\d{4})">
184           <leadingDigits>5</leadingDigits>
185           <format>$1 $2 $3</format>
186         </numberFormat>
187         <numberFormat pattern="([479]00)(\d)(\d{5})" nationalPrefixFormattingRule="$FG">
188           <leadingDigits>[479]0</leadingDigits>
189           <format>$1 $2 $3</format>
190         </numberFormat>
191         <numberFormat pattern="([68]00)(\d{2,9})" nationalPrefixFormattingRule="$FG">
192           <leadingDigits>
193             60|
194             8
195           </leadingDigits>
196           <format>$1 $2</format>
197         </numberFormat>
198       </availableFormats>
199       <generalDesc>
200         <nationalNumberPattern>
201           [2-79]\d{7,8}|
202           800\d{2,9}
203         </nationalNumberPattern>
204         <possibleNumberPattern>\d{5,12}</possibleNumberPattern>
205       </generalDesc>
206       <fixedLine>
207         <nationalNumberPattern>[2-4679][2-8]\d{6}</nationalNumberPattern>
208         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
209         <exampleNumber>22345678</exampleNumber>
210       </fixedLine>
211       <mobile>
212         <nationalNumberPattern>5[0256]\d{7}</nationalNumberPattern>
213         <possibleNumberPattern>\d{9}</possibleNumberPattern>
214         <exampleNumber>501234567</exampleNumber>
215       </mobile>
216       <tollFree>
217         <nationalNumberPattern>
218           400\d{6}|
219           800\d{2,9}
220         </nationalNumberPattern>
221         <possibleNumberPattern>\d{5,12}</possibleNumberPattern>
222         <exampleNumber>800123456</exampleNumber>
223       </tollFree>
224       <premiumRate>
225         <nationalNumberPattern>900[02]\d{5}</nationalNumberPattern>
226         <possibleNumberPattern>\d{9}</possibleNumberPattern>
227         <exampleNumber>900234567</exampleNumber>
228       </premiumRate>
229       <sharedCost>
230         <nationalNumberPattern>700[05]\d{5}</nationalNumberPattern>
231         <possibleNumberPattern>\d{9}</possibleNumberPattern>
232         <exampleNumber>700012345</exampleNumber>
233       </sharedCost>
234       <uan>
235         <nationalNumberPattern>600[25]\d{5}</nationalNumberPattern>
236         <possibleNumberPattern>\d{9}</possibleNumberPattern>
237         <exampleNumber>600212345</exampleNumber>
238       </uan>
239     </territory>
240
241     <!-- Afghanistan -->
242     <territory id="AF" countryCode="93" internationalPrefix="00"
243                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
244       <references>
245         <sourceUrl>http://www.itu.int/oth/T0202000001/en</sourceUrl>
246       </references>
247       <availableFormats>
248         <!-- Formatting based primarily on ITU document. -->
249         <numberFormat pattern="([2-7]\d)(\d{3})(\d{4})">
250           <leadingDigits>
251             [2-7]
252           </leadingDigits>
253           <format>$1 $2 $3</format>
254          </numberFormat>
255       </availableFormats>
256       <generalDesc>
257         <nationalNumberPattern>[2-7]\d{8}</nationalNumberPattern>
258         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
259       </generalDesc>
260       <fixedLine>
261         <nationalNumberPattern>
262           (?:
263             [25][0-8]|
264             [34][0-4]|
265             6[0-5]
266           )[2-9]\d{6}
267         </nationalNumberPattern>
268         <exampleNumber>234567890</exampleNumber>
269       </fixedLine>
270       <mobile>
271         <nationalNumberPattern>
272           7(?:
273             [014-9]\d{7}|
274             2[89]\d{6}
275           )
276         </nationalNumberPattern>
277         <possibleNumberPattern>\d{9}</possibleNumberPattern>
278         <exampleNumber>701234567</exampleNumber>
279       </mobile>
280     </territory>
281
282     <!-- Antigua and Barbuda -->
283     <territory id="AG" countryCode="1" leadingDigits="268" nationalPrefix="1"
284                internationalPrefix="011">
285       <references>
286         <sourceUrl>http://www.itu.int/oth/T0202000008/en</sourceUrl>
287       </references>
288       <generalDesc>
289         <!-- NANPA country - uses US formatting rules -->
290         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
291         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
292       </generalDesc>
293       <fixedLine>
294         <!-- 268 468 is not in the plan, but has been added after numbers with this prefix have been
295              found in online searches. -->
296         <nationalNumberPattern>
297           268(?:
298             4(?:
299               6[0-38]|
300               84
301             )|
302             56[0-2]
303           )\d{4}
304         </nationalNumberPattern>
305         <exampleNumber>2684601234</exampleNumber>
306       </fixedLine>
307       <mobile>
308         <!-- 268 776/778/779 are not in the plan, but have been added after numbers with these
309              prefixes have been found in online searches. Same for 268 780/782/784/786. -->
310         <nationalNumberPattern>
311           268(?:
312             464|
313             7(?:
314               2[0-9]|
315               64|
316               7[0-689]|
317               8[02-68]
318             )
319           )\d{4}
320         </nationalNumberPattern>
321         <possibleNumberPattern>\d{10}</possibleNumberPattern>
322         <exampleNumber>2684641234</exampleNumber>
323       </mobile>
324       <pager>
325         <nationalNumberPattern>26840[69]\d{4}</nationalNumberPattern>
326         <possibleNumberPattern>\d{10}</possibleNumberPattern>
327         <exampleNumber>2684061234</exampleNumber>
328       </pager>
329       <tollFree>
330         <nationalNumberPattern>
331           8(?:
332             00|
333             44|
334             55|
335             66|
336             77|
337             88
338           )[2-9]\d{6}
339         </nationalNumberPattern>
340         <possibleNumberPattern>\d{10}</possibleNumberPattern>
341         <exampleNumber>8002123456</exampleNumber>
342       </tollFree>
343       <premiumRate>
344         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
345         <possibleNumberPattern>\d{10}</possibleNumberPattern>
346         <exampleNumber>9002123456</exampleNumber>
347       </premiumRate>
348       <personalNumber>
349         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
350         <nationalNumberPattern>
351           5(?:
352             00|
353             33|
354             44|
355             66|
356             77
357           )[2-9]\d{6}
358         </nationalNumberPattern>
359         <possibleNumberPattern>\d{10}</possibleNumberPattern>
360         <exampleNumber>5002345678</exampleNumber>
361       </personalNumber>
362       <voip>
363         <!-- This is included as Centrex in the plan. -->
364         <nationalNumberPattern>26848[01]\d{4}</nationalNumberPattern>
365         <possibleNumberPattern>\d{10}</possibleNumberPattern>
366         <exampleNumber>2684801234</exampleNumber>
367       </voip>
368     </territory>
369
370     <!-- Anguilla -->
371     <territory id="AI" countryCode="1" leadingDigits="264" nationalPrefix="1"
372                internationalPrefix="011">
373       <references>
374         <sourceUrl>http://www.itu.int/oth/T0202000007/en</sourceUrl>
375       </references>
376       <generalDesc>
377         <!-- NANPA country - uses US formatting rules -->
378         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
379         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
380       </generalDesc>
381       <fixedLine>
382         <nationalNumberPattern>
383           2644(?:
384             6[12]|
385             9[78]
386           )\d{4}
387         </nationalNumberPattern>
388         <exampleNumber>2644612345</exampleNumber>
389       </fixedLine>
390       <mobile>
391         <nationalNumberPattern>
392           264(?:
393             235|
394             476|
395             5(?:
396               3[6-9]|
397               8[1-4]
398             )|
399             7(?:
400               29|
401               72
402             )
403           )\d{4}
404         </nationalNumberPattern>
405         <possibleNumberPattern>\d{10}</possibleNumberPattern>
406         <exampleNumber>2642351234</exampleNumber>
407       </mobile>
408       <tollFree>
409         <nationalNumberPattern>
410           8(?:
411             00|
412             44|
413             55|
414             66|
415             77|
416             88
417           )[2-9]\d{6}
418         </nationalNumberPattern>
419         <possibleNumberPattern>\d{10}</possibleNumberPattern>
420         <exampleNumber>8002123456</exampleNumber>
421       </tollFree>
422       <premiumRate>
423         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
424         <possibleNumberPattern>\d{10}</possibleNumberPattern>
425         <exampleNumber>9002123456</exampleNumber>
426       </premiumRate>
427       <personalNumber>
428         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
429         <nationalNumberPattern>
430           5(?:
431             00|
432             33|
433             44|
434             66|
435             77
436           )[2-9]\d{6}
437         </nationalNumberPattern>
438         <possibleNumberPattern>\d{10}</possibleNumberPattern>
439         <exampleNumber>5002345678</exampleNumber>
440       </personalNumber>
441     </territory>
442
443     <!-- Albania -->
444     <territory id="AL" countryCode="355" internationalPrefix="00"
445                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
446                mobileNumberPortableRegion="true">
447       <references>
448         <sourceUrl>http://www.itu.int/oth/T0202000002/en</sourceUrl>
449       </references>
450       <availableFormats>
451         <!-- Formats mostly follow http://tirana.usembassy.gov/list_of_doctors.html -->
452         <numberFormat pattern="(4)(\d{3})(\d{4})">
453           <leadingDigits>4[0-6]</leadingDigits>
454           <format>$1 $2 $3</format>
455         </numberFormat>
456         <numberFormat pattern="(6[6-9])(\d{3})(\d{4})">
457           <leadingDigits>6</leadingDigits>
458           <format>$1 $2 $3</format>
459         </numberFormat>
460         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
461           <leadingDigits>
462             [2358][2-5]|
463             4[7-9]
464           </leadingDigits>
465           <format>$1 $2 $3</format>
466         </numberFormat>
467         <numberFormat pattern="(\d{3})(\d{3,5})">
468           <leadingDigits>
469             [235][16-9]|
470             8[016-9]|
471             [79]
472           </leadingDigits>
473           <format>$1 $2</format>
474         </numberFormat>
475       </availableFormats>
476       <generalDesc>
477         <nationalNumberPattern>
478           [2-57]\d{7}|
479           6\d{8}|
480           8\d{5,7}|
481           9\d{5}
482         </nationalNumberPattern>
483         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
484       </generalDesc>
485       <fixedLine>
486         <nationalNumberPattern>
487           (?:
488             2(?:
489               [168][1-9]|
490               [247]\d|
491               9[1-7]
492             )|
493             3(?:
494               1[1-3]|
495               [2-6]\d|
496               [79][1-8]|
497               8[1-9]
498             )|
499             4\d{2}|
500             5(?:
501               1[1-4]|
502               [2-578]\d|
503               6[1-5]|
504               9[1-7]
505             )|
506             8(?:
507               [19][1-5]|
508               [2-6]\d|
509               [78][1-7]
510             )
511           )\d{5}
512         </nationalNumberPattern>
513         <possibleNumberPattern>\d{5,8}</possibleNumberPattern>
514         <exampleNumber>22345678</exampleNumber>
515       </fixedLine>
516       <mobile>
517         <nationalNumberPattern>6[6-9]\d{7}</nationalNumberPattern>
518         <possibleNumberPattern>\d{9}</possibleNumberPattern>
519         <exampleNumber>661234567</exampleNumber>
520       </mobile>
521       <tollFree>
522         <nationalNumberPattern>800\d{4}</nationalNumberPattern>
523         <possibleNumberPattern>\d{7}</possibleNumberPattern>
524         <exampleNumber>8001234</exampleNumber>
525       </tollFree>
526       <premiumRate>
527         <!-- It is named "Shared Revenue Services" in the plan, but as there is a separate "Shared
528              Cost Services", it is highly likely these numbers are premium rate numbers. No
529              information/example is found in the Internet. -->
530         <nationalNumberPattern>900\d{3}</nationalNumberPattern>
531         <possibleNumberPattern>\d{6}</possibleNumberPattern>
532         <exampleNumber>900123</exampleNumber>
533       </premiumRate>
534       <sharedCost>
535         <nationalNumberPattern>808\d{3}</nationalNumberPattern>
536         <possibleNumberPattern>\d{6}</possibleNumberPattern>
537         <exampleNumber>808123</exampleNumber>
538       </sharedCost>
539       <personalNumber>
540         <nationalNumberPattern>700\d{5}</nationalNumberPattern>
541         <possibleNumberPattern>\d{8}</possibleNumberPattern>
542         <exampleNumber>70012345</exampleNumber>
543       </personalNumber>
544     </territory>
545
546     <!-- Armenia -->
547     <!-- We think the national dialling prefix is 0 - it seems this was a change in 2005 (or 2008)
548          along with the new city codes. However, their official document makes no mention of it,
549          websites disagree, and we are not sure if the change has actually been made. -->
550     <territory id="AM" countryCode="374" internationalPrefix="00"
551                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
552                mobileNumberPortableRegion="true" >
553       <references>
554         <sourceUrl>http://www.itu.int/oth/T020200000A/en</sourceUrl>
555         <sourceUrl>http://en.wikipedia.org/wiki/%2B374</sourceUrl>
556         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Nagorno-Karabakh_Republic</sourceUrl>
557       </references>
558       <availableFormats>
559         <numberFormat pattern="(\d{2})(\d{6})">
560           <leadingDigits>
561             1|
562             47
563           </leadingDigits>
564           <format>$1 $2</format>
565         </numberFormat>
566         <numberFormat pattern="(\d{2})(\d{6})" nationalPrefixFormattingRule="$NP$FG">
567           <leadingDigits>
568             4[139]|
569             [5-7]|
570             9[1-9]
571           </leadingDigits>
572           <format>$1 $2</format>
573         </numberFormat>
574         <numberFormat pattern="(\d{3})(\d{5})">
575           <leadingDigits>[23]</leadingDigits>
576           <format>$1 $2</format>
577         </numberFormat>
578         <numberFormat pattern="(\d{3})(\d{2})(\d{3})" nationalPrefixFormattingRule="$NP $FG">
579           <leadingDigits>
580             8|
581             90
582           </leadingDigits>
583           <format>$1 $2 $3</format>
584         </numberFormat>
585       </availableFormats>
586       <generalDesc>
587         <nationalNumberPattern>[1-9]\d{7}</nationalNumberPattern>
588         <possibleNumberPattern>\d{5,8}</possibleNumberPattern>
589       </generalDesc>
590       <fixedLine>
591         <!-- Includes telephone numbers in Nagorno-Karabakh Republic, physically located inside
592              Azerbaijan, which use prefix 47. -->
593         <nationalNumberPattern>
594           (?:
595             1[01]\d|
596             2(?:
597               2[2-46]|
598               3[1-8]|
599               4[2-69]|
600               5[2-7]|
601               6[1-9]|
602               8[1-7]
603             )|
604             3[12]2|
605             47\d
606           )\d{5}
607         </nationalNumberPattern>
608         <exampleNumber>10123456</exampleNumber>
609       </fixedLine>
610       <mobile>
611         <!-- Part of the range 97 is used by Nagorno-Karabakh Republic. -->
612         <nationalNumberPattern>
613           (?:
614             4[139]|
615             55|
616             77|
617             9[1-9]
618           )\d{6}
619         </nationalNumberPattern>
620         <possibleNumberPattern>\d{8}</possibleNumberPattern>
621         <exampleNumber>77123456</exampleNumber>
622       </mobile>
623       <tollFree>
624         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
625         <possibleNumberPattern>\d{8}</possibleNumberPattern>
626         <exampleNumber>80012345</exampleNumber>
627       </tollFree>
628       <premiumRate>
629         <nationalNumberPattern>90[016]\d{5}</nationalNumberPattern>
630         <possibleNumberPattern>\d{8}</possibleNumberPattern>
631         <exampleNumber>90012345</exampleNumber>
632       </premiumRate>
633       <sharedCost>
634         <nationalNumberPattern>80[1-4]\d{5}</nationalNumberPattern>
635         <possibleNumberPattern>\d{8}</possibleNumberPattern>
636         <exampleNumber>80112345</exampleNumber>
637       </sharedCost>
638       <voip>
639         <nationalNumberPattern>60[2-6]\d{5}</nationalNumberPattern>
640         <possibleNumberPattern>\d{8}</possibleNumberPattern>
641         <exampleNumber>60271234</exampleNumber>
642       </voip>
643     </territory>
644
645     <!-- Angola -->
646     <territory id="AO" countryCode="244" internationalPrefix="00">
647       <references>
648         <sourceUrl>http://www.itu.int/oth/T0202000006/en</sourceUrl>
649       </references>
650       <availableFormats>
651         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
652           <format>$1 $2 $3</format>
653         </numberFormat>
654       </availableFormats>
655       <generalDesc>
656         <nationalNumberPattern>[29]\d{8}</nationalNumberPattern>
657         <possibleNumberPattern>\d{9}</possibleNumberPattern>
658       </generalDesc>
659       <fixedLine>
660         <nationalNumberPattern>
661           2\d(?:
662             [26-9]\d|
663             \d[26-9]
664           )\d{5}
665         </nationalNumberPattern>
666         <exampleNumber>222123456</exampleNumber>
667       </fixedLine>
668       <mobile>
669         <!-- Expanded the 92 prefix possibilities to match numbers found online. Unitel
670              apparently launched the prefix 94 on 25th April 2012, and Movicel has 99. -->
671         <nationalNumberPattern>9[1-49]\d{7}</nationalNumberPattern>
672         <exampleNumber>923123456</exampleNumber>
673       </mobile>
674     </territory>
675
676     <!-- Argentina -->
677     <!-- The national prefix for parsing here consists of a 0 (optional), followed by the area code
678          (which is captured, so that it can be retained), followed by 15, which is the mobile token,
679          which will be stripped if present. We expect the following combinations: 0AC15 and AC15
680          (where the 0 and 15 will be stripped, and it will be transformed into 9AC), 0, and 15 (in
681          the latter two cases we just strip the 0 or 15 as appropriate and leave the number as is.)
682          -->
683     <territory id="AR" countryCode="54" internationalPrefix="00" nationalPrefix="0"
684        nationalPrefixForParsing="
685          0?(?:(
686             11|
687             2(?:
688               2(?:
689                 02?|
690                 [13]|
691                 2[13-79]|
692                 4[1-6]|
693                 5[2457]|
694                 6[124-8]|
695                 7[1-4]|
696                 8[13-6]|
697                 9[1267]
698               )|
699               3(?:
700                 02?|
701                 1[467]|
702                 2[03-6]|
703                 3[13-8]|
704                 [49][2-6]|
705                 5[2-8]|
706                 [67]
707               )|
708               4(?:
709                 7[3-578]|
710                 9
711               )|
712               6(?:
713                 [0136]|
714                 2[24-6]|
715                 4[6-8]?|
716                 5[15-8]
717               )|
718               80|
719               9(?:
720                 0[1-3]|
721                 [19]|
722                 2\d|
723                 3[1-6]|
724                 4[02568]?|
725                 5[2-4]|
726                 6[2-46]|
727                 72?|
728                 8[23]?
729               )
730            )|
731            3(?:
732              3(?:
733                2[79]|
734                6|
735                8[2578]
736              )|
737              4(?:
738                0[0-24-9]|
739                [12]|
740                3[5-8]?|
741                4[24-7]|
742                5[4-68]?|
743                6[02-9]|
744                7[126]|
745                8[2379]?|
746                9[1-36-8]
747              )|
748              5(?:
749                1|
750                2[1245]|
751                3[237]?|
752                4[1-46-9]|
753                6[2-4]|
754                7[1-6]|
755                8[2-5]?
756              )|
757              6[24]|
758              7(?:
759                [069]|
760                1[1568]|
761                2[15]|
762                3[145]|
763                4[13]|
764                5[14-8]|
765                7[2-57]|
766                8[126]
767              )|
768              8(?:
769                [01]|
770                2[15-7]|
771                3[2578]?|
772                4[13-6]|
773                5[4-8]?|
774                6[1-357-9]|
775                7[36-8]?|
776                8[5-8]?|
777                9[124]
778              )
779            )
780          )?15)?"
781        nationalPrefixTransformRule="9$1" nationalPrefixFormattingRule="$NP$FG"
782        mobileNumberPortableRegion="true">
783       <references>
784         <sourceUrl>http://www.itu.int/oth/T0202000009/en</sourceUrl>
785         <!-- On the following link, click on Indicativos Interurbanos to access detailed
786              information. -->
787         <sourceUrl>http://www.cnc.gov.ar/infotecnica/numeracion/Index.asp</sourceUrl>
788         <!-- Download XLS spreadsheet from "Númeración Geográfica" link on following page: -->
789         <sourceUrl>http://www.cnc.gob.ar/asignaciones-a-la-fecha_p445</sourceUrl>
790         <sourceUrl>http://en.wikipedia.org/wiki/+54</sourceUrl>
791       </references>
792       <availableFormats>
793         <numberFormat pattern="([68]\d{2})(\d{3})(\d{4})">
794           <leadingDigits>[68]</leadingDigits>
795           <format>$1-$2-$3</format>
796         </numberFormat>
797         <!-- Format local numbers in two groups. The leading digits are 2-9 since the ITU document
798              says that the digit zero and one will not be present at the start of the subscriber
799              number (which starts with an "Exchange characteristic"). -->
800         <numberFormat pattern="(\d{2})(\d{4})" nationalPrefixFormattingRule="$FG">
801           <leadingDigits>[2-9]</leadingDigits>
802           <format>$1-$2</format>
803           <intlFormat>NA</intlFormat>
804         </numberFormat>
805         <numberFormat pattern="(\d{3})(\d{4})" nationalPrefixFormattingRule="$FG">
806           <leadingDigits>[2-9]</leadingDigits>
807           <format>$1-$2</format>
808           <intlFormat>NA</intlFormat>
809         </numberFormat>
810         <numberFormat pattern="(\d{4})(\d{4})" nationalPrefixFormattingRule="$FG">
811           <leadingDigits>[2-9]</leadingDigits>
812           <format>$1-$2</format>
813           <intlFormat>NA</intlFormat>
814         </numberFormat>
815         <numberFormat pattern="(9)(11)(\d{4})(\d{4})">
816           <leadingDigits>911</leadingDigits>
817           <format>$2 15-$3-$4</format>
818           <intlFormat>$1 $2 $3-$4</intlFormat>
819         </numberFormat>
820         <numberFormat pattern="(9)(\d{3})(\d{3})(\d{4})">
821           <!-- The regular expressions below were generated semi-automatically from data extracted
822                from the XLS spreadsheet downloaded from the "Númeración Geográfica" link cited
823                above. Each pattern captures all 3-3-4 prefixes for its length, but may also capture
824                some 4-2-4 cases.
825
826                In cases where a range contains both 3-3-4 and 4-2-4 prefixes, the most commonly used
827                one should be considered the default.
828                * If there are more distinct 4-2-4 prefixes, then the regular expression should
829                  INCLUDE only the explicitly mentioned 3-3-4 prefixes.
830                * If there are more distinct 3-3-4 prefixes, then the regular expression should
831                  EXCLUDE only the explicitly mentioned 4-2-4 prefixes.
832                This should help maximize the chances of new ranges automatically being assigned to
833                the right form.
834
835                In the final (most specific) regular expression, the few remaining ambiguous cases
836                are decided by comparing usage counts. Any manual edits to these expressions not
837                reflected in the XLS spreadsheet must be clearly called out below:
838
839                Added Manually as 3-3-4 format:
840                * 2981 (General Roca, Río Negro) : Numbers found online suggest 3-3-4
841
842                See also:
843                https://github.com/googlei18n/libphonenumber/issues/611
844                https://github.com/googlei18n/libphonenumber/issues/559
845                -->
846           <!-- Do NOT copy this into the section below. Removing the leading '9' will make it match
847                only 2 digits and the first <leadingDigits> section must always match 3 digits. -->
848           <leadingDigits>
849             9(?:
850               2[234689]|
851               3[3-8]
852             )
853           </leadingDigits>
854           <!-- If modified, copy this expression into the section below, minus the leading '9' -->
855           <leadingDigits>
856             9(?:
857               2(?:
858                 2[013]|
859                 3[067]|
860                 49|
861                 6[01346]|
862                 80|
863                 9[147-9]
864               )|
865               3(?:
866                 36|
867                 4[1-358]|
868                 5[138]|
869                 6[24]|
870                 7[069]|
871                 8[013578]
872               )
873             )
874           </leadingDigits>
875           <!-- Note that some patterns appear as both 3 and 4 digit area codes. In these cases
876                (to avoid going to 6 digits of discrimination) we simply pick the one with the
877                most uses. Patterns excluded from this expression will be treated as 4-2-4:
878                - XXXX (usage count as 3-digit code:usage count as 4-digit code)
879                - 2646 (7:15)   - excluded
880                - 3435 (39:63)  - excluded
881                - 3436 (16:54)  - excluded
882                - 3454 (90:48)
883                - 3455 (13:94)  - excluded
884                - 3456 (3:93)   - excluded
885                - 3584 (143:65)
886                - 3585 (21:42)  - excluded
887                - 3854 (115:73)
888                - 3855 (76:40)
889                - 3856 (19:44)  - excluded
890                - 3876 (56:99)  - excluded
891                - 3885 (120:45)
892                - 3886 (3:137)  - excluded
893                -->
894           <!-- If modified, copy this expression into the section below, minus the leading '9' -->
895           <leadingDigits>
896             9(?:
897               2(?:
898                 2(?:
899                   0[013-9]|
900                   [13]
901                 )|
902                 3(?:
903                   0[013-9]|
904                   [67]
905                 )|
906                 49|
907                 6(?:
908                   [0136]|
909                   4[0-59]
910                 )|
911                 8|
912                 9(?:
913                   [19]|
914                   44|
915                   7[013-9]|
916                   8[14]
917                 )
918               )|
919               3(?:
920                 36|
921                 4(?:
922                   [12]|
923                   [358]4
924                 )|
925                 5(?:
926                   1|
927                   3[0-24-689]|
928                   8[46]
929                 )|
930                 6|
931                 7[069]|
932                 8(?:
933                   [01]|
934                   34|
935                   [578][45]
936                 )
937               )
938             )
939           </leadingDigits>
940           <format>$2 15-$3-$4</format>
941           <intlFormat>$1 $2 $3-$4</intlFormat>
942         </numberFormat>
943         <!-- Both 4-3-3 and 4-2-4 have been seen online; we prefer the latter since it matches the
944              Argentinian ITU doc and wikipedia. -->
945         <numberFormat pattern="(9)(\d{4})(\d{2})(\d{4})">
946           <leadingDigits>9[23]</leadingDigits>
947           <format>$2 15-$3-$4</format>
948           <intlFormat>$1 $2 $3-$4</intlFormat>
949         </numberFormat>
950         <numberFormat pattern="(11)(\d{4})(\d{4})" nationalPrefixOptionalWhenFormatting="true">
951           <leadingDigits>1</leadingDigits>
952           <format>$1 $2-$3</format>
953         </numberFormat>
954         <!-- These patterns are a copy of the mobile patterns with the leading 9 removed. -->
955         <numberFormat pattern="(\d{3})(\d{3})(\d{4})" nationalPrefixOptionalWhenFormatting="true">
956           <!-- Never modify this manually, always copy from above and remove leading '9' -->
957           <leadingDigits>
958             2(?:
959               2[013]|
960               3[067]|
961               49|
962               6[01346]|
963               80|
964               9[147-9]
965             )|
966             3(?:
967               36|
968               4[1-358]|
969               5[138]|
970               6[24]|
971               7[069]|
972               8[013578]
973             )
974           </leadingDigits>
975           <!-- Never modify this manually, always copy from above and remove leading '9' -->
976           <leadingDigits>
977             2(?:
978               2(?:
979                 0[013-9]|
980                 [13]
981               )|
982               3(?:
983                 0[013-9]|
984                 [67]
985               )|
986               49|
987               6(?:
988                 [0136]|
989                 4[0-59]
990               )|
991               8|
992               9(?:
993                 [19]|
994                 44|
995                 7[013-9]|
996                 8[14]
997               )
998             )|
999             3(?:
1000               36|
1001               4(?:
1002                 [12]|
1003                 [358]4
1004               )|
1005               5(?:
1006                 1|
1007                 3[0-24-689]|
1008                 8[46]
1009               )|
1010               6|
1011               7[069]|
1012               8(?:
1013                 [01]|
1014                 34|
1015                 [578][45]
1016               )
1017             )
1018           </leadingDigits>
1019           <format>$1 $2-$3</format>
1020         </numberFormat>
1021         <numberFormat pattern="(\d{4})(\d{2})(\d{4})" nationalPrefixOptionalWhenFormatting="true">
1022           <leadingDigits>[23]</leadingDigits>
1023           <format>$1 $2-$3</format>
1024         </numberFormat>
1025         <!-- Format short numbers as a block. -->
1026         <numberFormat pattern="(\d{3})" nationalPrefixFormattingRule="$FG">
1027           <leadingDigits>
1028             1[012]|
1029             911
1030           </leadingDigits>
1031           <format>$1</format>
1032           <intlFormat>NA</intlFormat>
1033         </numberFormat>
1034       </availableFormats>
1035       <generalDesc>
1036         <!-- We restrict the second digit after 1 here so we can recognise and strip the 15 mobile
1037            carrier prefix when we see it. -->
1038         <nationalNumberPattern>
1039           11\d{8}|
1040           [2368]\d{9}|
1041           9\d{10}
1042         </nationalNumberPattern>
1043         <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
1044       </generalDesc>
1045       <noInternationalDialling>
1046         <nationalNumberPattern>810\d{7}</nationalNumberPattern>
1047         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1048         <exampleNumber>8101234567</exampleNumber>
1049       </noInternationalDialling>
1050       <fixedLine>
1051         <!-- Also covering fixed satellite service numbers (670). -->
1052         <nationalNumberPattern>
1053           11\d{8}|
1054           (?:
1055             2(?:
1056               2(?:
1057                 [013]\d|
1058                 2[13-79]|
1059                 4[1-6]|
1060                 5[2457]|
1061                 6[124-8]|
1062                 7[1-4]|
1063                 8[13-6]|
1064                 9[1267]
1065               )|
1066               3(?:
1067                 1[467]|
1068                 2[03-6]|
1069                 3[13-8]|
1070                 [49][2-6]|
1071                 5[2-8]|
1072                 [067]\d
1073               )|
1074               4(?:
1075                 7[3-8]|
1076                 9\d
1077               )|
1078               6(?:
1079                 [01346]\d|
1080                 2[24-6]|
1081                 5[15-8]
1082               )|
1083               80\d|
1084               9(?:
1085                 [0124789]\d|
1086                 3[1-6]|
1087                 5[234]|
1088                 6[2-46]
1089               )
1090             )|
1091             3(?:
1092               3(?:
1093                 2[79]|
1094                 6\d|
1095                 8[2578]
1096               )|
1097               4(?:
1098                 [78]\d|
1099                 0[0124-9]|
1100                 [1-35]\d|
1101                 4[24-7]|
1102                 6[02-9]|
1103                 9[123678]
1104               )|
1105               5(?:
1106                 [138]\d|
1107                 2[1245]|
1108                 4[1-9]|
1109                 6[2-4]|
1110                 7[1-6]
1111               )|
1112               6[24]\d|
1113               7(?:
1114                 [0469]\d|
1115                 1[1568]|
1116                 2[013-9]|
1117                 3[145]|
1118                 5[14-8]|
1119                 7[2-57]|
1120                 8[0-24-9]
1121               )|
1122               8(?:
1123                 [013578]\d|
1124                 2[15-7]|
1125                 4[13-6]|
1126                 6[1-357-9]|
1127                 9[124]
1128               )
1129             )|
1130             670\d
1131           )\d{6}
1132         </nationalNumberPattern>
1133         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
1134         <exampleNumber>1123456789</exampleNumber>
1135       </fixedLine>
1136       <mobile>
1137         <!-- Also covers mobile satellite services (675 numbers). -->
1138         <!-- 4-digit area codes are not covered here in detail - we only check the digit after the
1139              area code is in the range 2-9. The four-digit area-code checking is done in detail if
1140              we attempt to strip the caller-pays token (15) from the number. -->
1141         <nationalNumberPattern>
1142           675\d{7}|
1143           9(?:
1144             11[2-9]\d{7}|
1145             (?:
1146               2(?:
1147                 2[013]|
1148                 3[067]|
1149                 49|
1150                 6[01346]|
1151                 80|
1152                 9[147-9]
1153               )|
1154               3(?:
1155                 36|
1156                 4[12358]|
1157                 5[138]|
1158                 6[24]|
1159                 7[069]|
1160                 8[013578]
1161               )
1162             )[2-9]\d{6}|
1163             \d{4}[2-9]\d{5}
1164           )
1165         </nationalNumberPattern>
1166         <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
1167         <exampleNumber>91123456789</exampleNumber>
1168       </mobile>
1169       <tollFree>
1170         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
1171         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1172         <exampleNumber>8001234567</exampleNumber>
1173       </tollFree>
1174       <premiumRate>
1175         <nationalNumberPattern>60[04579]\d{7}</nationalNumberPattern>
1176         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1177         <exampleNumber>6001234567</exampleNumber>
1178       </premiumRate>
1179       <uan>
1180         <nationalNumberPattern>810\d{7}</nationalNumberPattern>
1181         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1182         <exampleNumber>8101234567</exampleNumber>
1183       </uan>
1184     </territory>
1185
1186     <!-- American Samoa -->
1187     <territory id="AS" countryCode="1" leadingDigits="684" nationalPrefix="1"
1188                internationalPrefix="011">
1189       <references>
1190         <sourceUrl>http://www.itu.int/oth/T0202000004/en</sourceUrl>
1191       </references>
1192       <generalDesc>
1193         <!-- NANPA country - uses US formatting rules -->
1194         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
1195         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
1196       </generalDesc>
1197       <fixedLine>
1198         <nationalNumberPattern>
1199           6846(?:
1200             22|
1201             33|
1202             44|
1203             55|
1204             77|
1205             88|
1206             9[19]
1207           )\d{4}
1208         </nationalNumberPattern>
1209         <exampleNumber>6846221234</exampleNumber>
1210       </fixedLine>
1211       <mobile>
1212         <!-- Added 25[246] and 272, operated by Blue Sky. Added 731, 770, operated by ASTCA. -->
1213         <nationalNumberPattern>
1214           684(?:
1215             2(?:
1216               5[2468]|
1217               72
1218             )|
1219             7(?:
1220               3[13]|
1221               70
1222             )
1223           )\d{4}
1224         </nationalNumberPattern>
1225         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1226         <exampleNumber>6847331234</exampleNumber>
1227       </mobile>
1228       <tollFree>
1229         <nationalNumberPattern>
1230           8(?:
1231             00|
1232             44|
1233             55|
1234             66|
1235             77|
1236             88
1237           )[2-9]\d{6}
1238         </nationalNumberPattern>
1239         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1240         <exampleNumber>8002123456</exampleNumber>
1241       </tollFree>
1242       <premiumRate>
1243         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
1244         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1245         <exampleNumber>9002123456</exampleNumber>
1246       </premiumRate>
1247       <personalNumber>
1248         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
1249         <nationalNumberPattern>
1250           5(?:
1251             00|
1252             33|
1253             44|
1254             66|
1255             77
1256           )[2-9]\d{6}
1257         </nationalNumberPattern>
1258         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1259         <exampleNumber>5002345678</exampleNumber>
1260       </personalNumber>
1261     </territory>
1262
1263     <!-- Austria -->
1264     <territory id="AT" countryCode="43" internationalPrefix="00"
1265                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
1266                mobileNumberPortableRegion="true">
1267       <references>
1268         <sourceUrl>http://www.rtr.at/en/tk/E129</sourceUrl>
1269       </references>
1270       <availableFormats>
1271         <numberFormat pattern="(1)(\d{3,12})">
1272           <leadingDigits>1</leadingDigits>
1273           <format>$1 $2</format>
1274         </numberFormat>
1275         <!-- The following three patterns are the most common for prefixes 050, 057 and 059, as
1276              found on Austrian web pages. -->
1277         <numberFormat pattern="(5\d)(\d{3,5})">
1278           <leadingDigits>5[079]</leadingDigits>
1279           <format>$1 $2</format>
1280         </numberFormat>
1281         <numberFormat pattern="(5\d)(\d{3})(\d{3,4})">
1282           <leadingDigits>5[079]</leadingDigits>
1283           <format>$1 $2 $3</format>
1284         </numberFormat>
1285         <numberFormat pattern="(5\d)(\d{4})(\d{4,7})">
1286           <leadingDigits>5[079]</leadingDigits>
1287           <format>$1 $2 $3</format>
1288         </numberFormat>
1289         <numberFormat pattern="(\d{3})(\d{3,10})">
1290           <leadingDigits>
1291             316|
1292             46|
1293             51|
1294             732|
1295             6(?:
1296               44|
1297               5[0-3579]|
1298               [6-9]
1299             )|
1300             7(?:
1301               1|
1302               [28]0
1303             )|
1304             [89]
1305           </leadingDigits>
1306           <format>$1 $2</format>
1307         </numberFormat>
1308         <numberFormat pattern="(\d{4})(\d{3,9})">
1309           <leadingDigits>
1310             2|
1311             3(?:
1312               1[1-578]|
1313               [3-8]
1314             )|
1315             4[2378]|
1316             5[2-6]|
1317             6(?:
1318               [12]|
1319               4[1-35-9]|
1320               5[468]
1321             )|
1322             7(?:
1323               2[1-8]|
1324               35|
1325               4[1-8]|
1326               [5-79]
1327             )
1328           </leadingDigits>
1329             <format>$1 $2</format>
1330           </numberFormat>
1331       </availableFormats>
1332       <generalDesc>
1333         <nationalNumberPattern>[1-9]\d{3,12}</nationalNumberPattern>
1334         <possibleNumberPattern>\d{3,13}</possibleNumberPattern>
1335       </generalDesc>
1336       <fixedLine>
1337         <!-- Note that the full area code is not validated - just the first 3 digits. This also
1338              means that even though for most Austrian numbers the minimum length is 7, we allow 6
1339              since we don't differentiate below between 3 and 4 digit area codes for reasons of
1340              efficiency. -->
1341         <nationalNumberPattern>
1342           1\d{3,12}|
1343           (?:
1344             2(?:
1345               1[467]|
1346               2[13-8]|
1347               5[2357]|
1348               6[1-46-8]|
1349               7[1-8]|
1350               8[124-7]|
1351               9[1458]
1352             )|
1353             3(?:
1354               1[1-8]|
1355               3[23568]|
1356               4[5-7]|
1357               5[1378]|
1358               6[1-38]|
1359               8[3-68]
1360             )|
1361             4(?:
1362               2[1-8]|
1363               35|
1364               63|
1365               7[1368]|
1366               8[2457]
1367             )|
1368             5(?:
1369               12|
1370               2[1-8]|
1371               3[357]|
1372               4[147]|
1373               5[12578]|
1374               6[37]
1375             )|
1376             6(?:
1377               13|
1378               2[1-47]|
1379               4[1-35-8]|
1380               5[468]|
1381               62
1382             )|
1383             7(?:
1384               2[1-8]|
1385               3[25]|
1386               4[13478]|
1387               5[68]|
1388               6[16-8]|
1389               7[1-6]|
1390               9[45]
1391             )
1392           )\d{3,10}
1393         </nationalNumberPattern>
1394         <exampleNumber>1234567890</exampleNumber>
1395       </fixedLine>
1396       <mobile>
1397         <nationalNumberPattern>
1398           6(?:
1399             44|
1400             5[0-3579]|
1401             6[013-9]|
1402             [7-9]\d
1403           )\d{4,10}
1404         </nationalNumberPattern>
1405         <possibleNumberPattern>\d{7,13}</possibleNumberPattern>
1406         <exampleNumber>644123456</exampleNumber>
1407       </mobile>
1408       <tollFree>
1409         <nationalNumberPattern>80[02]\d{6,10}</nationalNumberPattern>
1410         <possibleNumberPattern>\d{9,13}</possibleNumberPattern>
1411         <exampleNumber>800123456</exampleNumber>
1412       </tollFree>
1413       <premiumRate>
1414         <nationalNumberPattern>
1415           (?:
1416             711|
1417             9(?:
1418               0[01]|
1419               3[019]
1420             )
1421           )\d{6,10}
1422         </nationalNumberPattern>
1423         <possibleNumberPattern>\d{9,13}</possibleNumberPattern>
1424         <exampleNumber>900123456</exampleNumber>
1425       </premiumRate>
1426       <sharedCost>
1427         <nationalNumberPattern>
1428           8(?:
1429             10|
1430             2[018]
1431           )\d{6,10}
1432         </nationalNumberPattern>
1433         <possibleNumberPattern>\d{9,13}</possibleNumberPattern>
1434         <exampleNumber>810123456</exampleNumber>
1435       </sharedCost>
1436       <voip>
1437         <nationalNumberPattern>780\d{6,10}</nationalNumberPattern>
1438         <possibleNumberPattern>\d{9,13}</possibleNumberPattern>
1439         <exampleNumber>780123456</exampleNumber>
1440       </voip>
1441       <uan>
1442         <nationalNumberPattern>
1443           5(?:
1444             (?:
1445               0[1-9]|
1446               17
1447             )\d{2,10}|
1448             [79]\d{3,11}
1449           )|
1450           720\d{6,10}
1451         </nationalNumberPattern>
1452         <possibleNumberPattern>\d{5,13}</possibleNumberPattern>
1453         <exampleNumber>50123</exampleNumber>
1454       </uan>
1455     </territory>
1456
1457     <!-- Australia -->
1458     <!-- Metadata shared with Cocos Islands (CC) and Christmas Islands (CX) -->
1459     <territory id="AU" countryCode="61" mainCountryForCode="true"
1460                internationalPrefix="(?:14(?:1[14]|34|4[17]|[56]6|7[47]|88))?001[14-689]"
1461                preferredInternationalPrefix="0011" nationalPrefix="0"
1462                mobileNumberPortableRegion="true">
1463       <references>
1464         <sourceUrl>http://www.itu.int/oth/T020200000D/en</sourceUrl>
1465         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia</sourceUrl>
1466       </references>
1467       <availableFormats>
1468         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
1469           pattern="([2378])(\d{4})(\d{4})">
1470           <leadingDigits>[2378]</leadingDigits>
1471           <format>$1 $2 $3</format>
1472         </numberFormat>
1473         <numberFormat nationalPrefixFormattingRule="$NP$FG"
1474           pattern="(\d{3})(\d{3})(\d{3})">
1475           <leadingDigits>
1476             [45]|
1477             14
1478           </leadingDigits>
1479           <format>$1 $2 $3</format>
1480         </numberFormat>
1481         <numberFormat nationalPrefixFormattingRule="$NP$FG"
1482           pattern="(16)(\d{3})(\d{2,4})">
1483           <leadingDigits>16</leadingDigits>
1484           <format>$1 $2 $3</format>
1485         </numberFormat>
1486         <numberFormat nationalPrefixFormattingRule="$FG"
1487           pattern="(1[389]\d{2})(\d{3})(\d{3})">
1488           <leadingDigits>
1489             1(?:
1490               [38]0|
1491               90
1492             )
1493           </leadingDigits>
1494           <leadingDigits>
1495             1(?:
1496               [38]00|
1497               90
1498             )
1499           </leadingDigits>
1500           <format>$1 $2 $3</format>
1501         </numberFormat>
1502         <numberFormat nationalPrefixFormattingRule="$FG"
1503           pattern="(180)(2\d{3})">
1504           <leadingDigits>180</leadingDigits>
1505           <leadingDigits>1802</leadingDigits>
1506           <format>$1 $2</format>
1507         </numberFormat>
1508         <numberFormat nationalPrefixFormattingRule="$FG"
1509           pattern="(19\d)(\d{3})">
1510           <leadingDigits>19[13]</leadingDigits>
1511           <format>$1 $2</format>
1512         </numberFormat>
1513         <numberFormat nationalPrefixFormattingRule="$FG"
1514           pattern="(19\d{2})(\d{4})">
1515           <leadingDigits>19[67]</leadingDigits>
1516           <format>$1 $2</format>
1517         </numberFormat>
1518         <numberFormat nationalPrefixFormattingRule="$FG"
1519           pattern="(13)(\d{2})(\d{2})">
1520           <leadingDigits>13[1-9]</leadingDigits>
1521           <format>$1 $2 $3</format>
1522         </numberFormat>
1523       </availableFormats>
1524       <generalDesc>
1525         <nationalNumberPattern>[1-578]\d{5,9}</nationalNumberPattern>
1526         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
1527       </generalDesc>
1528       <noInternationalDialling>
1529         <nationalNumberPattern>
1530           1(?:
1531             3(?:
1532               \d{4}|
1533               00\d{6}
1534             )|
1535             80(?:
1536               0\d{6}|
1537               2\d{3}
1538             )
1539           )
1540         </nationalNumberPattern>
1541         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
1542         <exampleNumber>1300123456</exampleNumber>
1543       </noInternationalDialling>
1544       <fixedLine>
1545         <!-- Excludes prefixes used by Cocos Islands and Christmas Islands -->
1546         <nationalNumberPattern>
1547           [237]\d{8}|
1548           8(?:
1549             [68]\d{3}|
1550             7[0-69]\d{2}|
1551             9(?:
1552               [02-9]\d{2}|
1553               1(?:
1554                 [0-57-9]\d|
1555                 6[0135-9]
1556               )
1557             )
1558           )\d{4}
1559         </nationalNumberPattern>
1560         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
1561         <exampleNumber>212345678</exampleNumber>
1562       </fixedLine>
1563       <mobile>
1564         <!-- Includes MobileSat and Thuraya satellite services. According to the wikipedia page,
1565              other ranges 14[1-3] are not currently used. Note CC and CX should be updated as well
1566              if this pattern changes. -->
1567         <nationalNumberPattern>
1568           14(?:
1569             5\d|
1570             71
1571           )\d{5}|
1572           4(?:
1573             [0-2]\d|
1574             3[0-57-9]|
1575             4[47-9]|
1576             5[0-25-9]|
1577             6[6-9]|
1578             7[03-9]|
1579             8[17-9]|
1580             9[017-9]
1581           )\d{6}
1582         </nationalNumberPattern>
1583         <possibleNumberPattern>\d{9}</possibleNumberPattern>
1584         <exampleNumber>412345678</exampleNumber>
1585       </mobile>
1586       <pager>
1587         <nationalNumberPattern>16\d{3,7}</nationalNumberPattern>
1588         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
1589         <exampleNumber>1612345</exampleNumber>
1590       </pager>
1591       <tollFree>
1592         <nationalNumberPattern>
1593           180(?:
1594             0\d{3}|
1595             2
1596           )\d{3}
1597         </nationalNumberPattern>
1598         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
1599         <exampleNumber>1800123456</exampleNumber>
1600       </tollFree>
1601       <premiumRate>
1602         <nationalNumberPattern>190[0126]\d{6}</nationalNumberPattern>
1603         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1604         <exampleNumber>1900123456</exampleNumber>
1605       </premiumRate>
1606       <sharedCost>
1607       <!-- Local-rate (SmartNumbers) are put here because they are a reverse-charge network,
1608            although they charge a small local call connect fee (around 25c). These start with 13
1609            or 1300. -->
1610         <nationalNumberPattern>
1611           13(?:
1612             00\d{2}
1613           )?\d{4}
1614         </nationalNumberPattern>
1615         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
1616         <exampleNumber>1300123456</exampleNumber>
1617       </sharedCost>
1618       <!-- Wikipedia was the source for these types of numbers, and number allocation search here
1619            http://web.acma.gov.au/numb/openAccess/inquiry/allocationSearch.do confirms this. (Search
1620            from 0500000000 to 0590000000) -->
1621       <personalNumber>
1622         <nationalNumberPattern>500\d{6}</nationalNumberPattern>
1623         <possibleNumberPattern>\d{9}</possibleNumberPattern>
1624         <exampleNumber>500123456</exampleNumber>
1625       </personalNumber>
1626       <voip>
1627         <nationalNumberPattern>550\d{6}</nationalNumberPattern>
1628         <possibleNumberPattern>\d{9}</possibleNumberPattern>
1629         <exampleNumber>550123456</exampleNumber>
1630       </voip>
1631     </territory>
1632
1633     <!-- Aruba -->
1634     <territory id="AW" countryCode="297" internationalPrefix="00">
1635       <references>
1636         <sourceUrl>http://www.itu.int/oth/T020200000B/en</sourceUrl>
1637       </references>
1638       <availableFormats>
1639         <numberFormat pattern="(\d{3})(\d{4})">
1640           <format>$1 $2</format>
1641         </numberFormat>
1642       </availableFormats>
1643       <generalDesc>
1644         <nationalNumberPattern>[25-9]\d{6}</nationalNumberPattern>
1645         <possibleNumberPattern>\d{7}</possibleNumberPattern>
1646       </generalDesc>
1647       <fixedLine>
1648         <nationalNumberPattern>
1649           5(?:
1650             2\d|
1651             8[1-9]
1652           )\d{4}
1653         </nationalNumberPattern>
1654         <exampleNumber>5212345</exampleNumber>
1655       </fixedLine>
1656       <mobile>
1657         <!-- The prefixes 662, 994 & 96[45], while not in the plan, seem to be used in mobile
1658              numbers found online. -->
1659         <nationalNumberPattern>
1660           (?:
1661             5(?:
1662               6\d|
1663               9[2-478]
1664             )|
1665             6(?:
1666               [039]0|
1667               22|
1668               4[01]|
1669               6[0-2]
1670             )|
1671             7[34]\d|
1672             9(?:
1673               6[45]|
1674               9[4-8]
1675             )
1676           )\d{4}
1677         </nationalNumberPattern>
1678         <exampleNumber>5601234</exampleNumber>
1679       </mobile>
1680       <tollFree>
1681         <nationalNumberPattern>800\d{4}</nationalNumberPattern>
1682         <exampleNumber>8001234</exampleNumber>
1683       </tollFree>
1684       <premiumRate>
1685         <nationalNumberPattern>900\d{4}</nationalNumberPattern>
1686         <exampleNumber>9001234</exampleNumber>
1687       </premiumRate>
1688       <voip>
1689         <nationalNumberPattern>
1690           28\d{5}|
1691           501\d{4}
1692         </nationalNumberPattern>
1693         <exampleNumber>5011234</exampleNumber>
1694       </voip>
1695     </territory>
1696
1697     <!-- Ã…land Islands. -->
1698     <!-- Metadata shared with Finland. -->
1699     <territory id="AX" countryCode="358" internationalPrefix="00|99[049]" nationalPrefix="0"
1700                nationalPrefixFormattingRule="$NP$FG">
1701       <references>
1702         <sourceUrl>https://www.viestintavirasto.fi/internetpuhelin/puhelinverkonnumerointi.html</sourceUrl>
1703       </references>
1704       <!-- The general desc and fixed line are numbers different from Finland metadata. -->
1705       <generalDesc>
1706         <nationalNumberPattern>
1707           [135]\d{5,9}|
1708           [27]\d{4,9}|
1709           4\d{5,10}|
1710           6\d{7,8}|
1711           8\d{6,9}
1712         </nationalNumberPattern>
1713         <possibleNumberPattern>\d{5,12}</possibleNumberPattern>
1714       </generalDesc>
1715       <noInternationalDialling>
1716         <!-- According to the national numbering plan, service numbers are in general not accessible
1717              from abroad, although 600/700/800 numbers may be. -->
1718         <nationalNumberPattern>
1719           [13]00\d{3,7}|
1720           2(?:
1721             0(?:
1722               0\d{3,7}|
1723               2[023]\d{1,6}|
1724               9[89]\d{1,6}
1725             )
1726           )|
1727           60(?:
1728             [12]\d{5,6}|
1729             6\d{7}
1730           )|
1731           7(?:
1732             1\d{7}|
1733             3\d{8}|
1734             5[03-9]\d{2,7}
1735           )
1736         </nationalNumberPattern>
1737         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
1738         <exampleNumber>100123</exampleNumber>
1739       </noInternationalDialling>
1740       <fixedLine>
1741         <nationalNumberPattern>18[1-8]\d{3,9}</nationalNumberPattern>
1742         <possibleNumberPattern>\d{6,12}</possibleNumberPattern>
1743         <exampleNumber>1812345678</exampleNumber>
1744       </fixedLine>
1745       <!-- The mobile, toll free, premium rate and UAN numbers copied from Finland. -->
1746       <mobile>
1747         <nationalNumberPattern>
1748           4\d{5,10}|
1749           50\d{4,8}
1750         </nationalNumberPattern>
1751         <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
1752         <exampleNumber>412345678</exampleNumber>
1753       </mobile>
1754       <tollFree>
1755         <nationalNumberPattern>800\d{4,7}</nationalNumberPattern>
1756         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
1757         <exampleNumber>8001234567</exampleNumber>
1758       </tollFree>
1759       <premiumRate>
1760         <nationalNumberPattern>[67]00\d{5,6}</nationalNumberPattern>
1761         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
1762         <exampleNumber>600123456</exampleNumber>
1763       </premiumRate>
1764       <uan>
1765         <!-- Covers nationwide non-geographic numbers, and nationwide "service numbers", typically
1766              assigned to institutions such as universities, the national post, etc, where they are
1767              not otherwise classified as toll-free or premium-rate numbers. -->
1768         <nationalNumberPattern>
1769           [13]0\d{4,8}|
1770           2(?:
1771             0(?:
1772               [016-8]\d{3,7}|
1773               [2-59]\d{2,7}
1774             )|
1775             9\d{4,8}
1776           )|
1777           60(?:
1778             [12]\d{5,6}|
1779             6\d{7}
1780           )|
1781           7(?:
1782             1\d{7}|
1783             3\d{8}|
1784             5[03-9]\d{2,7}
1785           )
1786         </nationalNumberPattern>
1787         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
1788         <exampleNumber>10112345</exampleNumber>
1789       </uan>
1790     </territory>
1791
1792     <!-- Azerbaijan -->
1793     <territory id="AZ" countryCode="994" internationalPrefix="00" nationalPrefix="0"
1794                nationalPrefixFormattingRule="($NP$FG)" mobileNumberPortableRegion="true">
1795       <references>
1796         <sourceUrl>http://www.itu.int/oth/T020200000F/en</sourceUrl>
1797       </references>
1798       <availableFormats>
1799         <numberFormat pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
1800           <leadingDigits>
1801             (?:
1802               1[28]|
1803               2(?:
1804                 [45]2|
1805                 [0-36]
1806               )|
1807               365
1808             )
1809           </leadingDigits>
1810           <format>$1 $2 $3 $4</format>
1811         </numberFormat>
1812         <numberFormat pattern="(\d{2})(\d{3})(\d{2})(\d{2})" nationalPrefixFormattingRule="$NP$FG">
1813           <leadingDigits>[4-8]</leadingDigits>
1814           <format>$1 $2 $3 $4</format>
1815         </numberFormat>
1816         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})"
1817           nationalPrefixFormattingRule="$NP$FG">
1818           <leadingDigits>9</leadingDigits>
1819           <format>$1 $2 $3 $4</format>
1820         </numberFormat>
1821       </availableFormats>
1822       <generalDesc>
1823         <nationalNumberPattern>[1-9]\d{8}</nationalNumberPattern>
1824         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
1825       </generalDesc>
1826       <fixedLine>
1827         <nationalNumberPattern>
1828           (?:
1829             1[28]\d|
1830             2(?:
1831               02|
1832               1[24]|
1833               2[2-4]|
1834               33|
1835               [45]2|
1836               6[23]
1837             )|
1838             365
1839           )\d{6}
1840         </nationalNumberPattern>
1841         <exampleNumber>123123456</exampleNumber>
1842       </fixedLine>
1843       <mobile>
1844         <nationalNumberPattern>
1845           (?:
1846             4[04]|
1847             5[015]|
1848             60|
1849             7[07]
1850           )\d{7}
1851         </nationalNumberPattern>
1852         <possibleNumberPattern>\d{9}</possibleNumberPattern>
1853         <exampleNumber>401234567</exampleNumber>
1854       </mobile>
1855       <tollFree>
1856         <!-- 88 is listed as fixed-line for Baku in the ITU document, but online numbers seem to
1857              suggest they are in fact national toll-free numbers. -->
1858         <nationalNumberPattern>88\d{7}</nationalNumberPattern>
1859         <possibleNumberPattern>\d{9}</possibleNumberPattern>
1860         <exampleNumber>881234567</exampleNumber>
1861       </tollFree>
1862       <premiumRate>
1863         <!-- These are marked as Interactive Calls in the ITU document. -->
1864         <nationalNumberPattern>900200\d{3}</nationalNumberPattern>
1865         <possibleNumberPattern>\d{9}</possibleNumberPattern>
1866         <exampleNumber>900200123</exampleNumber>
1867       </premiumRate>
1868     </territory>
1869
1870     <!-- Bosnia and Herzegovina -->
1871     <territory id="BA" countryCode="387" internationalPrefix="00"
1872                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
1873                mobileNumberPortableRegion="true">
1874       <references>
1875         <!-- accessible from http://www.cra.ba/en/telecom/numbering/ -->
1876         <sourceUrl>http://www.rak.ba/eng/index.php?uid=1272016657</sourceUrl>
1877         <sourceUrl>http://en.wikipedia.org/wiki/+387</sourceUrl>
1878       </references>
1879       <availableFormats>
1880         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
1881           <leadingDigits>[3-5]</leadingDigits>
1882           <format>$1 $2-$3</format>
1883         </numberFormat>
1884         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
1885           <leadingDigits>
1886             6[1-356]|
1887             [7-9]
1888           </leadingDigits>
1889           <format>$1 $2 $3</format>
1890         </numberFormat>
1891         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{3})">
1892           <leadingDigits>6[047]</leadingDigits>
1893           <format>$1 $2 $3 $4</format>
1894         </numberFormat>
1895       </availableFormats>
1896       <generalDesc>
1897         <nationalNumberPattern>[3-9]\d{7,8}</nationalNumberPattern>
1898         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
1899       </generalDesc>
1900       <fixedLine>
1901         <nationalNumberPattern>
1902           (?:
1903             [35]\d|
1904             49
1905           )\d{6}
1906         </nationalNumberPattern>
1907         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
1908         <exampleNumber>30123456</exampleNumber>
1909       </fixedLine>
1910       <mobile>
1911         <nationalNumberPattern>
1912           6(?:
1913             03|
1914             44|
1915             71|
1916             [1-356]
1917           )\d{6}
1918         </nationalNumberPattern>
1919         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
1920         <exampleNumber>61123456</exampleNumber>
1921       </mobile>
1922       <tollFree>
1923         <nationalNumberPattern>8[08]\d{6}</nationalNumberPattern>
1924         <possibleNumberPattern>\d{8}</possibleNumberPattern>
1925         <exampleNumber>80123456</exampleNumber>
1926       </tollFree>
1927       <premiumRate>
1928         <nationalNumberPattern>9[0246]\d{6}</nationalNumberPattern>
1929         <possibleNumberPattern>\d{8}</possibleNumberPattern>
1930         <exampleNumber>90123456</exampleNumber>
1931       </premiumRate>
1932       <sharedCost>
1933         <!-- Using this category to model national tariff numbers - these are under Shared Cost in
1934              the plan. -->
1935         <nationalNumberPattern>8[12]\d{6}</nationalNumberPattern>
1936         <possibleNumberPattern>\d{8}</possibleNumberPattern>
1937         <exampleNumber>82123456</exampleNumber>
1938       </sharedCost>
1939       <uan>
1940         <!-- Using this to classify nomad numbers. -->
1941         <nationalNumberPattern>70[23]\d{5}</nationalNumberPattern>
1942         <possibleNumberPattern>\d{8}</possibleNumberPattern>
1943         <exampleNumber>70223456</exampleNumber>
1944       </uan>
1945     </territory>
1946
1947     <!-- Barbados -->
1948     <territory id="BB" countryCode="1" leadingDigits="246" nationalPrefix="1"
1949                internationalPrefix="011">
1950       <references>
1951         <sourceUrl>http://www.itu.int/oth/T0202000013/en</sourceUrl>
1952       </references>
1953       <generalDesc>
1954         <!-- NANPA country - uses US formatting rules -->
1955         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
1956         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
1957       </generalDesc>
1958       <fixedLine>
1959         <nationalNumberPattern>246[2-9]\d{6}</nationalNumberPattern>
1960         <exampleNumber>2462345678</exampleNumber>
1961       </fixedLine>
1962       <mobile>
1963         <nationalNumberPattern>
1964           246(?:
1965             (?:
1966               2[346]|
1967               45|
1968               82
1969             )\d|
1970             25[0-4]
1971           )\d{4}
1972         </nationalNumberPattern>
1973         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1974         <exampleNumber>2462501234</exampleNumber>
1975       </mobile>
1976       <tollFree>
1977         <nationalNumberPattern>
1978           8(?:
1979             00|
1980             44|
1981             55|
1982             66|
1983             77|
1984             88
1985           )[2-9]\d{6}
1986         </nationalNumberPattern>
1987         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1988         <exampleNumber>8002123456</exampleNumber>
1989       </tollFree>
1990       <premiumRate>
1991         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
1992         <possibleNumberPattern>\d{10}</possibleNumberPattern>
1993         <exampleNumber>9002123456</exampleNumber>
1994       </premiumRate>
1995       <personalNumber>
1996         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
1997         <nationalNumberPattern>
1998           5(?:
1999             00|
2000             33|
2001             44|
2002             66|
2003             77
2004           )[2-9]\d{6}
2005         </nationalNumberPattern>
2006         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2007         <exampleNumber>5002345678</exampleNumber>
2008       </personalNumber>
2009     </territory>
2010
2011     <!-- Bangladesh -->
2012     <territory id="BD" countryCode="880" internationalPrefix="00[12]?"
2013                preferredInternationalPrefix="00"
2014                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
2015       <references>
2016         <sourceUrl>http://www.itu.int/oth/T0202000012/en</sourceUrl>
2017         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Bangladesh</sourceUrl>
2018         <sourceUrl>http://www.btrc.gov.bd/sites/default/files/national_numbering_plan_2005_0.pdf</sourceUrl>
2019       </references>
2020       <availableFormats>
2021         <numberFormat pattern="(2)(\d{7})">
2022           <leadingDigits>2</leadingDigits>
2023           <format>$1-$2</format>
2024         </numberFormat>
2025         <numberFormat pattern="(\d{2})(\d{4,6})">
2026           <leadingDigits>[3-79]1</leadingDigits>
2027           <format>$1-$2</format>
2028         </numberFormat>
2029         <!-- Mobile numbers, VOIP, and four-digit fixed-line area codes. -->
2030         <numberFormat pattern="(\d{4})(\d{3,6})">
2031           <leadingDigits>
2032             1|
2033             3(?:
2034               0|
2035               [2-58]2
2036             )|
2037             4(?:
2038               0|
2039               [25]2|
2040               3[23]|
2041               [4689][25]
2042             )|
2043             5(?:
2044               [02-578]2|
2045               6[25]
2046             )|
2047             6(?:
2048               [0347-9]2|
2049               [26][25]
2050             )|
2051             7[02-9]2|
2052             8(?:
2053               [023][23]|
2054               [4-7]2
2055             )|
2056             9(?:
2057               [02][23]|
2058               [458]2|
2059               6[016]
2060             )
2061           </leadingDigits>
2062           <format>$1-$2</format>
2063         </numberFormat>
2064         <numberFormat pattern="(\d{3})(\d{3,7})">
2065           <leadingDigits>
2066             [3-79][2-9]|
2067             8
2068           </leadingDigits>
2069           <format>$1-$2</format>
2070         </numberFormat>
2071       </availableFormats>
2072       <generalDesc>
2073       <!-- This is quite complex so we can define that numbers beginning with 88 are not part of the
2074            plan, so the country code can be accurately stripped off. -->
2075         <nationalNumberPattern>
2076           [2-79]\d{5,9}|
2077           1\d{9}|
2078           8[0-7]\d{4,8}
2079         </nationalNumberPattern>
2080         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
2081       </generalDesc>
2082       <fixedLine>
2083         <!-- There was a plan to move to 10 digit fixed-line numbers, but this does not seem to have
2084              been realised, judging by online numbers and wikipedia. These patterns are grouped
2085              first by leading digit, then within by number of digits. Several Dhaka prefixes (02 731,
2086              02 910, etc.) are included despite not being mentioned on Wikipedia / ITU due to
2087              online evidence. Another oddity is Chittagong - some numbers have a leading 2, others
2088              do not - both are allowed for now. For some area codes, the subscriber number length
2089              described in our source documentation doesn't match numbers online (e.g. 05222) so we
2090              allow both for now. (This applies to 0431, 04329, 04623, 05327 as well). We have
2091              also added 04452 and 04923 from numbers found online. -->
2092         <nationalNumberPattern>
2093           2(?:
2094             7(?:
2095               1[0-267]|
2096               2[0-289]|
2097               3[0-29]|
2098               [46][01]|
2099               5[1-3]|
2100               7[017]|
2101               91
2102             )|
2103             8(?:
2104               0[125]|
2105               [139][1-6]|
2106               2[0157-9]|
2107               6[1-35]|
2108               7[1-5]|
2109               8[1-8]
2110             )|
2111             9(?:
2112               0[0-2]|
2113               1[0-4]|
2114               2[568]|
2115               3[3-6]|
2116               5[5-7]|
2117               6[0167]|
2118               7[15]|
2119               8[0146-8]
2120             )
2121           )\d{4}|
2122           3(?:
2123             12?[5-7]\d{2}|
2124             0(?:
2125               2(?:
2126                 [025-79]\d|
2127                 [348]\d{1,2}
2128               )|
2129               3(?:
2130                 [2-4]\d|
2131                 [56]\d?
2132               )
2133             )|
2134             2(?:
2135               1\d{2}|
2136               2(?:
2137                 [12]\d|
2138                 [35]\d{1,2}|
2139                 4\d?
2140               )
2141             )|
2142             3(?:
2143               1\d{2}|
2144               2(?:
2145                 [2356]\d|
2146                 4\d{1,2}
2147               )
2148             )|
2149             4(?:
2150               1\d{2}|
2151               2(?:
2152                 2\d{1,2}|
2153                 [47]|
2154                 5\d{2}
2155               )
2156             )|
2157             5(?:
2158               1\d{2}|
2159               29
2160             )|
2161             [67]1\d{2}|
2162             8(?:
2163               1\d{2}|
2164               2(?:
2165                 2\d{2}|
2166                 3|
2167                 4\d
2168               )
2169             )
2170           )\d{3}|
2171           4(?:
2172             0(?:
2173               2(?:
2174                 [09]\d|
2175                 7
2176               )|
2177               33\d{2}
2178             )|
2179             1\d{3}|
2180             2(?:
2181               1\d{2}|
2182               2(?:
2183                 [25]\d?|
2184                 [348]\d|
2185                 [67]\d{1,2}
2186               )
2187             )|
2188             3(?:
2189               1\d{2}(?:\d{2})?|
2190               2(?:
2191                 [045]\d|
2192                 [236-9]\d{1,2}
2193               )|
2194               32\d{2}
2195             )|
2196             4(?:
2197               [18]\d{2}|
2198               2(?:
2199                 [2-46]\d{2}|
2200                 3
2201               )|
2202               5[25]\d{2}
2203             )|
2204             5(?:
2205               1\d{2}|
2206               2(?:
2207                 3\d|
2208                 5
2209               )
2210             )|
2211             6(?:
2212               [18]\d{2}|
2213               2(?:
2214                 3(?:\d{2})?|
2215                 [46]\d{1,2}|
2216                 5\d{2}|
2217                 7\d
2218               )|
2219               5(?:
2220                 3\d?|
2221                 4\d|
2222                 [57]\d{1,2}|
2223                 6\d{2}|
2224                 8
2225               )
2226             )|
2227             71\d{2}|
2228             8(?:
2229               [18]\d{2}|
2230               23\d{2}|
2231               54\d{2}
2232             )|
2233             9(?:
2234               [18]\d{2}|
2235               2[2-5]\d{2}|
2236               53\d{1,2}
2237             )
2238           )\d{3}|
2239           5(?:
2240             02[03489]\d{2}|
2241             1\d{2}|
2242             2(?:
2243               1\d{2}|
2244               2(?:
2245                 2(?:\d{2})?|
2246                 [457]\d{2}
2247               )
2248             )|
2249             3(?:
2250               1\d{2}|
2251               2(?:
2252                 [37](?:\d{2})?|
2253                 [569]\d{2}
2254               )
2255             )|
2256             4(?:
2257               1\d{2}|
2258               2[46]\d{2}
2259             )|
2260             5(?:
2261               1\d{2}|
2262               26\d{1,2}
2263             )|
2264             6(?:
2265               [18]\d{2}|
2266               2|
2267               53\d{2}
2268             )|
2269             7(?:
2270               1|
2271               24
2272             )\d{2}|
2273             8(?:
2274               1|
2275               26
2276             )\d{2}|
2277             91\d{2}
2278           )\d{3}|
2279           6(?:
2280             0(?:
2281               1\d{2}|
2282               2(?:
2283                 3\d{2}|
2284                 4\d{1,2}
2285               )
2286             )|
2287             2(?:
2288               2[2-5]\d{2}|
2289               5(?:
2290                 [3-5]\d{2}|
2291                 7
2292               )|
2293               8\d{2}
2294             )|
2295             3(?:
2296               1|
2297               2[3478]
2298             )\d{2}|
2299             4(?:
2300               1|
2301               2[34]
2302             )\d{2}|
2303             5(?:
2304               1|
2305               2[47]
2306             )\d{2}|
2307             6(?:
2308               [18]\d{2}|
2309               6(?:
2310                 2(?:
2311                   2\d|
2312                   [34]\d{2}
2313                 )|
2314                 5(?:
2315                   [24]\d{2}|
2316                   3\d|
2317                   5\d{1,2}
2318                 )
2319               )
2320             )|
2321             72[2-5]\d{2}|
2322             8(?:
2323               1\d{2}|
2324               2[2-5]\d{2}
2325             )|
2326             9(?:
2327               1\d{2}|
2328               2[2-6]\d{2}
2329             )
2330           )\d{3}|
2331           7(?:
2332             (?:
2333               02|
2334               [3-589]1|
2335               6[12]|
2336               72[24]
2337             )\d{2}|
2338             21\d{3}|
2339             32
2340           )\d{3}|
2341           8(?:
2342             (?:
2343               4[12]|
2344               [5-7]2|
2345               1\d?
2346             )|
2347             (?:
2348               0|
2349               3[12]|
2350               [5-7]1|
2351               217
2352             )\d
2353           )\d{4}|
2354           9(?:
2355             [35]1|
2356             (?:
2357               [024]2|
2358               81
2359             )\d|
2360             (?:
2361               1|
2362               [24]1
2363             )\d{2}
2364           )\d{3}
2365         </nationalNumberPattern>
2366         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
2367         <exampleNumber>27111234</exampleNumber>
2368       </fixedLine>
2369       <mobile>
2370         <!-- Presuming that mobile numbers with the prefixes 66, 37, 44 and 38 must be followed by
2371              numbers [02-9] or they would clash with fixed-line codes. According to the plan, mobile
2372              numbers should be moving to 1[13-9] anyway. -->
2373         <nationalNumberPattern>
2374           (?:
2375             1[13-9]\d|
2376             (?:
2377               3[78]|
2378               44
2379             )[02-9]|
2380             6(?:
2381               44|
2382               6[02-9]
2383             )
2384           )\d{7}
2385         </nationalNumberPattern>
2386         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2387         <exampleNumber>1812345678</exampleNumber>
2388       </mobile>
2389       <tollFree>
2390         <!-- Note: Including Tele-voting numbers here as they are free of charge. -->
2391         <nationalNumberPattern>80[03]\d{7}</nationalNumberPattern>
2392         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2393         <exampleNumber>8001234567</exampleNumber>
2394       </tollFree>
2395       <voip>
2396         <nationalNumberPattern>
2397           96(?:
2398             0[49]|
2399             1[0-4]|
2400             6[69]
2401           )\d{6}
2402         </nationalNumberPattern>
2403         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2404         <exampleNumber>9604123456</exampleNumber>
2405       </voip>
2406     </territory>
2407
2408     <!-- Belgium -->
2409     <territory id="BE" countryCode="32" internationalPrefix="00"
2410                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
2411                mobileNumberPortableRegion="true">
2412       <references>
2413         <sourceUrl>http://www.bipt.be/en/operators/telecommunication/Numbering/Database</sourceUrl>
2414         <sourceUrl>http://www.bipt.be/public/files/en/474/20140829153659_Belgian_numbering_plan</sourceUrl>
2415         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Belgium</sourceUrl>
2416       </references>
2417       <availableFormats>
2418         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
2419           <leadingDigits>4[6-9]</leadingDigits>
2420           <format>$1 $2 $3 $4</format>
2421         </numberFormat>
2422         <numberFormat pattern="(\d)(\d{3})(\d{2})(\d{2})">
2423           <leadingDigits>
2424             [23]|
2425             4[23]|
2426             9[2-4]
2427           </leadingDigits>
2428           <format>$1 $2 $3 $4</format>
2429         </numberFormat>
2430         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
2431           <leadingDigits>
2432             [156]|
2433             7[018]|
2434             8(?:
2435               0[1-9]|
2436               [1-79]
2437             )
2438           </leadingDigits>
2439           <format>$1 $2 $3 $4</format>
2440         </numberFormat>
2441         <numberFormat pattern="(\d{3})(\d{2})(\d{3})">
2442           <leadingDigits>
2443             (?:
2444               80|
2445               9
2446             )0
2447           </leadingDigits>
2448           <format>$1 $2 $3</format>
2449         </numberFormat>
2450       </availableFormats>
2451       <generalDesc>
2452         <nationalNumberPattern>[1-9]\d{7,8}</nationalNumberPattern>
2453         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
2454       </generalDesc>
2455       <fixedLine>
2456         <nationalNumberPattern>
2457           (?:
2458             1[0-69]|
2459             [23][2-8]|
2460             4[23]|
2461             5\d|
2462             6[013-57-9]|
2463             71|
2464             8[1-79]|
2465             9[2-4]
2466           )\d{6}|
2467           80[2-8]\d{5}
2468         </nationalNumberPattern>
2469         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2470         <exampleNumber>12345678</exampleNumber>
2471       </fixedLine>
2472       <mobile>
2473         <nationalNumberPattern>
2474           4(?:
2475             6[0135-8]|
2476             [79]\d|
2477             8[3-9]
2478           )\d{6}
2479         </nationalNumberPattern>
2480         <possibleNumberPattern>\d{9}</possibleNumberPattern>
2481         <exampleNumber>470123456</exampleNumber>
2482       </mobile>
2483       <tollFree>
2484         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
2485         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2486         <exampleNumber>80012345</exampleNumber>
2487       </tollFree>
2488       <premiumRate>
2489         <nationalNumberPattern>
2490           (?:
2491             70[2-467]|
2492             90[0-79]
2493           )\d{5}
2494         </nationalNumberPattern>
2495         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2496         <exampleNumber>90123456</exampleNumber>
2497       </premiumRate>
2498       <uan>
2499         <!-- Using this for National Rate Services, since
2500              http://www.voipgate.com/site/news/newsflash/new-numbers-available-the-netherlands-and-austria.html
2501              says it will be priced the same as any other national calls. -->
2502         <nationalNumberPattern>78\d{6}</nationalNumberPattern>
2503         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2504         <exampleNumber>78123456</exampleNumber>
2505       </uan>
2506     </territory>
2507
2508     <!-- Burkina Faso -->
2509     <territory id="BF" countryCode="226" internationalPrefix="00">
2510       <references>
2511         <sourceUrl>http://www.itu.int/oth/T0202000021/en</sourceUrl>
2512         <sourceUrl>http://www.onatel.bf/onatelsa/plandenumerotation_burkina.pdf</sourceUrl>
2513       </references>
2514       <availableFormats>
2515         <!-- The national numbering plan from ITU suggests grouping of 2, 2 and 4, but we have
2516              chosen to use the standard from numbers found on the internet instead. -->
2517         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
2518           <format>$1 $2 $3 $4</format>
2519         </numberFormat>
2520       </availableFormats>
2521       <generalDesc>
2522         <nationalNumberPattern>[24-7]\d{7}</nationalNumberPattern>
2523         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2524       </generalDesc>
2525       <fixedLine>
2526         <nationalNumberPattern>
2527           (?:
2528             20(?:
2529               49|
2530               5[23]|
2531               9[016-9]
2532             )|
2533             40(?:
2534               4[569]|
2535               5[4-6]|
2536               7[0179]
2537             )|
2538             50(?:
2539               [34]\d|
2540               50
2541             )
2542           )\d{4}
2543         </nationalNumberPattern>
2544         <exampleNumber>20491234</exampleNumber>
2545       </fixedLine>
2546       <mobile>
2547         <nationalNumberPattern>
2548           6(?:
2549             [0-689]\d|
2550             7[0-5]
2551           )\d{5}|
2552           7\d{7}
2553         </nationalNumberPattern>
2554         <exampleNumber>70123456</exampleNumber>
2555       </mobile>
2556     </territory>
2557
2558     <!-- Bulgaria -->
2559     <territory id="BG" countryCode="359" internationalPrefix="00"
2560                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
2561                mobileNumberPortableRegion="true">
2562       <references>
2563         <sourceUrl>http://www.itu.int/oth/T0202000020/en</sourceUrl>
2564       </references>
2565       <availableFormats>
2566         <!-- Formatting rules follow the conventions seen in web-search results. A space has been
2567              used to separate the area code from the rest of the number, based on sites like
2568              http://www.goldenpages.bg. -->
2569         <numberFormat pattern="(2)(\d{5})">
2570           <leadingDigits>29</leadingDigits>
2571           <format>$1 $2</format>
2572         </numberFormat>
2573         <numberFormat pattern="(2)(\d{3})(\d{3,4})">
2574           <leadingDigits>2</leadingDigits>
2575           <format>$1 $2 $3</format>
2576         </numberFormat>
2577         <numberFormat pattern="(\d{3})(\d{4})">
2578           <leadingDigits>
2579             43[124-7]|
2580             70[1-9]
2581           </leadingDigits>
2582           <format>$1 $2</format>
2583         </numberFormat>
2584         <numberFormat pattern="(\d{3})(\d{3})(\d{2})">
2585           <leadingDigits>
2586             43[124-7]|
2587             70[1-9]
2588           </leadingDigits>
2589           <format>$1 $2 $3</format>
2590         </numberFormat>
2591         <numberFormat pattern="(\d{3})(\d{2})(\d{3})">
2592           <leadingDigits>[78]00</leadingDigits>
2593           <format>$1 $2 $3</format>
2594         </numberFormat>
2595         <numberFormat pattern="(\d{2})(\d{3})(\d{2,3})">
2596           <leadingDigits>
2597             [356]|
2598             4[124-7]|
2599             7[1-9]|
2600             8[1-6]|
2601             9[1-7]
2602           </leadingDigits>
2603           <format>$1 $2 $3</format>
2604         </numberFormat>
2605         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})">
2606           <leadingDigits>
2607             48|
2608             8[7-9]|
2609             9[08]
2610           </leadingDigits>
2611           <format>$1 $2 $3</format>
2612         </numberFormat>
2613       </availableFormats>
2614       <generalDesc>
2615         <nationalNumberPattern>
2616           [23567]\d{5,7}|
2617           [489]\d{6,8}
2618         </nationalNumberPattern>
2619         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
2620       </generalDesc>
2621       <fixedLine>
2622         <!-- 29xxxx numbers have been added because they can be found online, and are typically
2623              used by taxi companies. -->
2624         <nationalNumberPattern>
2625           2(?:
2626             [0-8]\d{5,6}|
2627             9\d{4,6}
2628           )|
2629           (?:
2630             [36]\d|
2631             5[1-9]|
2632             8[1-6]|
2633             9[1-7]
2634           )\d{5,6}|
2635           (?:
2636             4(?:
2637               [124-7]\d|
2638               3[1-6]
2639             )|
2640             7(?:
2641               0[1-9]|
2642               [1-9]\d
2643             )
2644           )\d{4,5}
2645         </nationalNumberPattern>
2646         <possibleNumberPattern>\d{5,8}</possibleNumberPattern>
2647         <exampleNumber>2123456</exampleNumber>
2648       </fixedLine>
2649       <mobile>
2650         <nationalNumberPattern>
2651           (?:
2652             8[7-9]|
2653             98
2654           )\d{7}|
2655           4(?:
2656             3[0789]|
2657             8\d
2658           )\d{5}
2659         </nationalNumberPattern>
2660         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
2661         <exampleNumber>48123456</exampleNumber>
2662       </mobile>
2663       <tollFree>
2664         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
2665         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2666         <exampleNumber>80012345</exampleNumber>
2667       </tollFree>
2668       <premiumRate>
2669         <nationalNumberPattern>90\d{6}</nationalNumberPattern>
2670         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2671         <exampleNumber>90123456</exampleNumber>
2672       </premiumRate>
2673       <personalNumber>
2674         <nationalNumberPattern>700\d{5}</nationalNumberPattern>
2675         <exampleNumber>70012345</exampleNumber>
2676       </personalNumber>
2677     </territory>
2678
2679     <!-- Bahrain -->
2680     <territory id="BH" countryCode="973" internationalPrefix="00" mobileNumberPortableRegion="true">
2681       <references>
2682         <sourceUrl>http://www.itu.int/oth/T0202000011/en</sourceUrl>
2683         <sourceUrl>http://www.tra.org.bh/en/marketNumbering.aspx</sourceUrl>
2684         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Bahrain</sourceUrl>
2685       </references>
2686       <availableFormats>
2687         <numberFormat pattern="(\d{4})(\d{4})">
2688           <format>$1 $2</format>
2689         </numberFormat>
2690       </availableFormats>
2691       <generalDesc>
2692         <nationalNumberPattern>[136-9]\d{7}</nationalNumberPattern>
2693         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2694       </generalDesc>
2695       <!-- Some ranges were previously described as "universal", but in subsequent versions of the
2696            ITU doc they have been specified to be mobile or fixed-line. We follow the ITU
2697            designations, even though some publications still refer to them as universal. -->
2698       <!-- According to http://en.wikipedia.org/wiki/Telephone_numbers_in_Bahrain, the ranges
2699            "6966-6969, 6996, 6999" are assigned to Rapid. However this contradicts the ITU doc
2700            which lists "6966, 6969, 6996, 6999". We follow ITU here. -->
2701       <fixedLine>
2702         <nationalNumberPattern>
2703           (?:
2704             1(?:
2705               3[1356]|
2706               6[0156]|
2707               7\d
2708             )\d|
2709             6(?:
2710               1[16]\d|
2711               500|
2712               6(?:
2713                 0\d|
2714                 3[12]|
2715                 44|
2716                 7[7-9]
2717               )|
2718               9[69][69]
2719             )|
2720             7(?:
2721               1(?:
2722                 11|
2723                 78
2724               )|
2725               7\d{2}
2726             )
2727           )\d{4}
2728         </nationalNumberPattern>
2729         <exampleNumber>17001234</exampleNumber>
2730       </fixedLine>
2731       <!-- 31 is assigned to Royal Court, as per documents on Bahrain's own telecom site, even
2732            though it is omitted from the ITU document. -->
2733       <mobile>
2734         <nationalNumberPattern>
2735           (?:
2736             3(?:
2737               [1-4679]\d|
2738               5[013569]|
2739               8[0-47-9]
2740             )\d|
2741             6(?:
2742               3(?:
2743                 00|
2744                 33|
2745                 6[16]
2746               )|
2747               6(?:
2748                 [69]\d|
2749                 3[03-9]|
2750                 7[0-6]
2751               )
2752             )
2753           )\d{4}
2754         </nationalNumberPattern>
2755         <exampleNumber>36001234</exampleNumber>
2756       </mobile>
2757       <tollFree>
2758         <nationalNumberPattern>80\d{6}</nationalNumberPattern>
2759         <exampleNumber>80123456</exampleNumber>
2760       </tollFree>
2761       <!-- 87 numbers are "wholly paid by the caller", so they are slotted under premium-rate for
2762            now. -->
2763       <premiumRate>
2764         <nationalNumberPattern>
2765           (?:
2766             87|
2767             9[014578]
2768           )\d{6}
2769         </nationalNumberPattern>
2770         <exampleNumber>90123456</exampleNumber>
2771       </premiumRate>
2772       <sharedCost>
2773         <nationalNumberPattern>84\d{6}</nationalNumberPattern>
2774         <exampleNumber>84123456</exampleNumber>
2775       </sharedCost>
2776     </territory>
2777
2778     <!-- Burundi -->
2779     <territory id="BI" countryCode="257" internationalPrefix="00">
2780       <references>
2781         <sourceUrl>http://www.itu.int/oth/T0202000022/en</sourceUrl>
2782       </references>
2783       <availableFormats>
2784         <numberFormat
2785           pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
2786           <format>$1 $2 $3 $4</format>
2787         </numberFormat>
2788       </availableFormats>
2789       <generalDesc>
2790         <nationalNumberPattern>[267]\d{7}</nationalNumberPattern>
2791         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2792       </generalDesc>
2793       <fixedLine>
2794         <nationalNumberPattern>
2795           22(?:
2796             2[0-7]|
2797             [3-5]0
2798           )\d{4}
2799         </nationalNumberPattern>
2800         <exampleNumber>22201234</exampleNumber>
2801       </fixedLine>
2802       <mobile>
2803         <!-- Extra online mobile number prefixes found: 74.
2804              The 29 prefix is listed as a mobile prefix, but many people list it as their fixed home
2805              number. We will keep it as mobile for now, but it may actually be a prefix for fixed
2806              satellite phones. -->
2807         <nationalNumberPattern>
2808           (?:
2809             [26]9|
2810             7[14-9]
2811           )\d{6}
2812         </nationalNumberPattern>
2813         <exampleNumber>79561234</exampleNumber>
2814       </mobile>
2815     </territory>
2816
2817     <!-- Benin -->
2818     <territory id="BJ" countryCode="229" internationalPrefix="00">
2819       <references>
2820         <sourceUrl>http://www.itu.int/oth/T0202000017/en</sourceUrl>
2821       </references>
2822       <availableFormats>
2823         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
2824           <format>$1 $2 $3 $4</format>
2825         </numberFormat>
2826         <!-- Numbers beginning with 7 should be formatted as a block. -->
2827       </availableFormats>
2828       <generalDesc>
2829         <nationalNumberPattern>
2830           [2689]\d{7}|
2831           7\d{3}
2832         </nationalNumberPattern>
2833         <possibleNumberPattern>\d{4,8}</possibleNumberPattern>
2834       </generalDesc>
2835       <fixedLine>
2836         <!-- These come from the national numbering plan, but have been widened to include other
2837              prefixes found in the yellow pages - specifically 21 0. -->
2838         <nationalNumberPattern>
2839           2(?:
2840             02|
2841             1[037]|
2842             2[45]|
2843             3[68]
2844           )\d{5}
2845         </nationalNumberPattern>
2846         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2847         <exampleNumber>20211234</exampleNumber>
2848       </fixedLine>
2849       <mobile>
2850         <!-- We have restricted the pattern here to the first two digits, as beyond this the data
2851              seems to be no longer accurate. The prefixes 9[46] have also been added, along with
2852              6[167] (seemingly prefixes for Mobile MTN), and 64 for BeninCell. Glo Mobile has been
2853              reported as having prefixes 68 and 9[89]. -->
2854         <nationalNumberPattern>
2855           (?:
2856             6[146-8]|
2857             9[03-9]
2858           )\d{6}
2859         </nationalNumberPattern>
2860         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2861         <exampleNumber>90011234</exampleNumber>
2862       </mobile>
2863       <tollFree>
2864         <nationalNumberPattern>7[3-5]\d{2}</nationalNumberPattern>
2865         <possibleNumberPattern>\d{4}</possibleNumberPattern>
2866         <exampleNumber>7312</exampleNumber>
2867       </tollFree>
2868       <voip>
2869         <nationalNumberPattern>857[58]\d{4}</nationalNumberPattern>
2870         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2871         <exampleNumber>85751234</exampleNumber>
2872       </voip>
2873       <!-- Numbers beginning with 81 are reserved for _either_ free phone or shared-cost (same cost
2874            as a local-call.) We model these as UAN since we have no more detailed information. -->
2875       <uan>
2876         <nationalNumberPattern>81\d{6}</nationalNumberPattern>
2877         <possibleNumberPattern>\d{8}</possibleNumberPattern>
2878         <exampleNumber>81123456</exampleNumber>
2879       </uan>
2880     </territory>
2881
2882     <!-- Saint Barthélemy, French Antilles -->
2883     <!-- There seems to be some overlap with phone numbers from Saint Martin and Guadeloupe. The
2884          national numbering plan does not specify any St Barthélemy-specific numbering prefixes, but
2885          it appears from searches in online white and yellow pages that a subset of the prefixes
2886          available in these regions are used. In these cases, if getRegionCodeForNumber is used, one
2887          of these region codes will be returned, although numbers will be valid for both regions.
2888          -->
2889     <territory id="BL" countryCode="590" internationalPrefix="00" nationalPrefix="0">
2890       <references>
2891         <sourceUrl>http://www.itu.int/oth/T0202000058/en</sourceUrl>
2892       </references>
2893       <!-- Formatting rules borrowed from Guadeloupe. -->
2894       <generalDesc>
2895         <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
2896         <possibleNumberPattern>\d{9}</possibleNumberPattern>
2897       </generalDesc>
2898       <fixedLine>
2899         <nationalNumberPattern>
2900           590(?:
2901             2[7-9]|
2902             5[12]|
2903             87
2904           )\d{4}
2905         </nationalNumberPattern>
2906         <exampleNumber>590271234</exampleNumber>
2907       </fixedLine>
2908       <mobile>
2909         <!-- Any ranges assigned from
2910              http://www.arcep.fr/index.php?id=interactivenumeros have been listed as belonging to
2911              Guadeloupe, St Martin and St Barthélemy, since we can't reliably distinguish between
2912              them. -->
2913         <nationalNumberPattern>
2914           690(?:
2915             0[0-7]|
2916             [1-9]\d
2917           )\d{4}
2918         </nationalNumberPattern>
2919         <exampleNumber>690301234</exampleNumber>
2920       </mobile>
2921     </territory>
2922
2923     <!-- Bermuda -->
2924     <territory id="BM" countryCode="1" leadingDigits="441" nationalPrefix="1"
2925                internationalPrefix="011">
2926       <references>
2927         <sourceUrl>http://www.itu.int/oth/T0202000018/en</sourceUrl>
2928       </references>
2929       <generalDesc>
2930         <!-- NANPA country - uses US formatting rules -->
2931         <nationalNumberPattern>[4589]\d{9}</nationalNumberPattern>
2932         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
2933       </generalDesc>
2934       <fixedLine>
2935         <nationalNumberPattern>
2936           441(?:
2937             2(?:
2938               02|
2939               23|
2940               61|
2941               [3479]\d
2942             )|
2943             [46]\d{2}|
2944             5(?:
2945               4\d|
2946               60|
2947               89
2948             )|
2949             824
2950           )\d{4}
2951         </nationalNumberPattern>
2952         <exampleNumber>4412345678</exampleNumber>
2953       </fixedLine>
2954       <mobile>
2955         <nationalNumberPattern>
2956           441(?:
2957             [37]\d|
2958             5[0-39]
2959           )\d{5}
2960         </nationalNumberPattern>
2961         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2962         <exampleNumber>4413701234</exampleNumber>
2963       </mobile>
2964       <tollFree>
2965         <nationalNumberPattern>
2966           8(?:
2967             00|
2968             44|
2969             55|
2970             66|
2971             77|
2972             88
2973           )[2-9]\d{6}
2974         </nationalNumberPattern>
2975         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2976         <exampleNumber>8002123456</exampleNumber>
2977       </tollFree>
2978       <premiumRate>
2979         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
2980         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2981         <exampleNumber>9002123456</exampleNumber>
2982       </premiumRate>
2983       <personalNumber>
2984         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
2985         <nationalNumberPattern>
2986           5(?:
2987             00|
2988             33|
2989             44|
2990             66|
2991             77
2992           )[2-9]\d{6}
2993         </nationalNumberPattern>
2994         <possibleNumberPattern>\d{10}</possibleNumberPattern>
2995         <exampleNumber>5002345678</exampleNumber>
2996       </personalNumber>
2997     </territory>
2998
2999     <!-- Brunei Darussalam -->
3000     <territory id="BN" countryCode="673" internationalPrefix="00">
3001       <references>
3002         <sourceUrl>http://www.itu.int/oth/T020200001F/en</sourceUrl>
3003       </references>
3004       <!-- Format is from http://aiti.gov.bn/contact.html -->
3005       <availableFormats>
3006         <numberFormat pattern="([2-578]\d{2})(\d{4})">
3007           <format>$1 $2</format>
3008         </numberFormat>
3009       </availableFormats>
3010       <generalDesc>
3011         <nationalNumberPattern>[2-578]\d{6}</nationalNumberPattern>
3012         <possibleNumberPattern>\d{7}</possibleNumberPattern>
3013       </generalDesc>
3014       <fixedLine>
3015         <nationalNumberPattern>
3016           2(?:
3017             [013-9]\d|
3018             2[0-7]
3019           )\d{4}|
3020           [3-5]\d{6}
3021         </nationalNumberPattern>
3022         <exampleNumber>2345678</exampleNumber>
3023       </fixedLine>
3024       <mobile>
3025         <nationalNumberPattern>
3026           22[89]\d{4}|
3027           [78]\d{6}
3028         </nationalNumberPattern>
3029         <exampleNumber>7123456</exampleNumber>
3030       </mobile>
3031     </territory>
3032
3033     <!-- Bolivia -->
3034     <territory id="BO" countryCode="591" internationalPrefix="00(1\d)?" nationalPrefix="0"
3035                nationalPrefixForParsing="0(1\d)?" carrierCodeFormattingRule="$NP$CC $FG">
3036       <references>
3037         <sourceUrl>http://www.itu.int/oth/T020200001A/en</sourceUrl>
3038         <sourceUrl>http://www.bolivia.com/Servicios/Plandenumeracion.pdf</sourceUrl>
3039       </references>
3040       <availableFormats>
3041         <numberFormat pattern="([234])(\d{7})">
3042           <leadingDigits>[234]</leadingDigits>
3043           <format>$1 $2</format>
3044         </numberFormat>
3045         <numberFormat pattern="([67]\d{7})">
3046           <leadingDigits>[67]</leadingDigits>
3047           <format>$1</format>
3048         </numberFormat>
3049       </availableFormats>
3050       <generalDesc>
3051         <nationalNumberPattern>[23467]\d{7}</nationalNumberPattern>
3052         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
3053       </generalDesc>
3054       <fixedLine>
3055         <nationalNumberPattern>
3056           (?:
3057             2(?:
3058               2\d{2}|
3059               5(?:11|[258]\d|9[67])|
3060               6(?:12|2\d|9[34])|
3061               8(?:2[34]|39|62)
3062             )|
3063             3(?:
3064               3\d{2}|
3065               4(?:6\d|8[24])|
3066               8(?:25|42|5[257]|86|9[25])|
3067               9(?:2\d|3[234]|4[248]|5[24]|6[2-6]|7\d)
3068             )|
3069             4(?:
3070               4\d{2}|
3071               6(?:11|[24689]\d|72)
3072             )
3073           )\d{4}
3074         </nationalNumberPattern>
3075         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
3076         <exampleNumber>22123456</exampleNumber>
3077       </fixedLine>
3078       <mobile>
3079         <nationalNumberPattern>[67]\d{7}</nationalNumberPattern>
3080         <possibleNumberPattern>\d{8}</possibleNumberPattern>
3081         <exampleNumber>71234567</exampleNumber>
3082       </mobile>
3083     </territory>
3084
3085     <!-- Bonaire, Sint Eustatius and Saba -->
3086     <territory id="BQ" countryCode="599" internationalPrefix="00">
3087       <references>
3088         <sourceUrl>http://www.itu.int/oth/T02020000F8/en</sourceUrl>
3089       </references>
3090       <!-- Shares formatting patterns with CW. -->
3091       <generalDesc>
3092         <nationalNumberPattern>[347]\d{6}</nationalNumberPattern>
3093         <possibleNumberPattern>\d{7}</possibleNumberPattern>
3094       </generalDesc>
3095       <fixedLine>
3096         <nationalNumberPattern>
3097           (?:
3098             318[023]|
3099             416[023]|
3100             7(?:
3101               1[578]|
3102               50
3103             )\d
3104           )\d{3}
3105         </nationalNumberPattern>
3106         <exampleNumber>7151234</exampleNumber>
3107       </fixedLine>
3108       <mobile>
3109         <nationalNumberPattern>
3110           (?:
3111             318[14-68]|
3112             416[15-9]|
3113             7(?:
3114               0[01]|
3115               7[07]|
3116               [89]\d
3117             )\d
3118           )\d{3}
3119         </nationalNumberPattern>
3120         <exampleNumber>3181234</exampleNumber>
3121       </mobile>
3122     </territory>
3123
3124     <!-- Brazil -->
3125     <territory id="BR" countryCode="55"
3126                internationalPrefix="00(?:1[45]|2[135]|31|4[13])"
3127                nationalPrefix="0"
3128                nationalPrefixForParsing="0(?:(1[245]|2[135]|31|4[13])(\d{10,11}))?"
3129                nationalPrefixTransformRule="$2" mobileNumberPortableRegion="true">
3130       <references>
3131         <sourceUrl>http://en.wikipedia.org/wiki/%2B55</sourceUrl>
3132         <sourceUrl>http://www.itu.int/oth/T020200001D/en</sourceUrl>
3133       </references>
3134       <!-- The national prefix for parsing here also contains a capturing group for the main number,
3135            since the carrier codes here may also be area codes, so we want to check the length of
3136            the number after capturing. We also need a nationalTransformRule to repopulate with the
3137            number without the carrier code. -->
3138       <availableFormats>
3139         <!-- Numbers can be dialled without an area code on mobile phones in Brazil. The first two
3140              rules here handle this case. The leading digits pattern must be specific enough such
3141              that it doesn't match X00 numbers (e.g. toll-free). -->
3142         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{4})">
3143           <leadingDigits>
3144             [2-9](?:
3145               [1-9]|
3146               0[1-9]
3147             )
3148           </leadingDigits>
3149           <format>$1-$2</format>
3150           <intlFormat>NA</intlFormat>
3151         </numberFormat>
3152         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{5})(\d{4})">
3153           <leadingDigits>
3154             9(?:
3155               [1-9]|
3156               0[1-9]
3157             )
3158           </leadingDigits>
3159           <format>$1-$2</format>
3160           <intlFormat>NA</intlFormat>
3161         </numberFormat>
3162         <!-- Format short numbers as a block. -->
3163         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{3,5})">
3164           <leadingDigits>1[125689]</leadingDigits>
3165           <format>$1</format>
3166           <intlFormat>NA</intlFormat>
3167         </numberFormat>
3168         <numberFormat nationalPrefixFormattingRule="($FG)"
3169             pattern="(\d{2})(\d{5})(\d{4})"
3170             carrierCodeFormattingRule="$NP $CC ($FG)">
3171           <leadingDigits>
3172             (?:
3173               1[1-9]|
3174               2[12478]|
3175               9[1-9]
3176             )9
3177           </leadingDigits>
3178           <format>$1 $2-$3</format>
3179         </numberFormat>
3180         <numberFormat nationalPrefixFormattingRule="($FG)"
3181             pattern="(\d{2})(\d{4})(\d{4})"
3182             carrierCodeFormattingRule="$NP $CC ($FG)">
3183           <leadingDigits>[1-9][1-9]</leadingDigits>
3184           <format>$1 $2-$3</format>
3185         </numberFormat>
3186         <numberFormat pattern="([34]00\d)(\d{4})">
3187           <leadingDigits>[34]00</leadingDigits>
3188           <format>$1-$2</format>
3189         </numberFormat>
3190         <numberFormat nationalPrefixFormattingRule="$NP$FG"
3191             pattern="([3589]00)(\d{2,3})(\d{4})">
3192           <leadingDigits>[3589]00</leadingDigits>
3193           <format>$1 $2 $3</format>
3194         </numberFormat>
3195       </availableFormats>
3196       <generalDesc>
3197         <nationalNumberPattern>
3198           [1-46-9]\d{7,10}|
3199           5\d{8,9}
3200         </nationalNumberPattern>
3201         <possibleNumberPattern>\d{8,11}</possibleNumberPattern>
3202       </generalDesc>
3203       <noInternationalDialling>
3204         <nationalNumberPattern>[34]00\d{5}</nationalNumberPattern>
3205         <possibleNumberPattern>\d{8}</possibleNumberPattern>
3206         <exampleNumber>40041234</exampleNumber>
3207       </noInternationalDialling>
3208       <fixedLine>
3209         <!-- According to this publication, the prefixes 11 53, 11 54 and 11 57 are to be used for
3210              mobile phones prior to the introduction of a ninth digit. It is not clear whether they
3211              are still valid as fixed-line numbers, so we are leaving them here in the meantime:
3212              http://www.anatel.gov.br/Portal/exibirPortalNoticias.do?acao=carregaNoticia&codigo=22406
3213              -->
3214         <nationalNumberPattern>
3215           1[1-9][2-5]\d{7}|
3216           (?:
3217             [4689][1-9]|
3218             2[12478]|
3219             3[1-578]|
3220             5[13-5]|
3221             7[13-579]
3222           )[2-5]\d{7}
3223         </nationalNumberPattern>
3224         <exampleNumber>1123456789</exampleNumber>
3225       </fixedLine>
3226       <mobile>
3227         <!-- Since 2012, Brazil has been migrating from 10 to 11 digits by inserting a 9 before the
3228              last 8 digits. The following pattern is divided into 3 sections: ranges for which the
3229              migration has been completed, ranges which are in transition, and ranges which are
3230              still in the old format. (Ranges which were supposed to have been deprecated in
3231              Oct. 2013 are still working as of Jan. 2014.) Note that mobile radio services are
3232              still 10 digits, with the subscriber number (the last 8 digits) beginning with 7. -->
3233         <nationalNumberPattern>
3234           1[1-9](?:
3235             7|
3236             9\d
3237           )\d{7}|
3238           (?:
3239             2[12478]|
3240             9[1-9]
3241           )9?[6-9]\d{7}|
3242           (?:
3243             3[1-578]|
3244             [468][1-9]|
3245             5[13-5]|
3246             7[13-579]
3247           )[6-9]\d{7}
3248         </nationalNumberPattern>
3249         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
3250         <exampleNumber>11961234567</exampleNumber>
3251       </mobile>
3252       <tollFree>
3253         <nationalNumberPattern>800\d{6,7}</nationalNumberPattern>
3254         <exampleNumber>800123456</exampleNumber>
3255       </tollFree>
3256       <premiumRate>
3257         <nationalNumberPattern>[359]00\d{6,7}</nationalNumberPattern>
3258         <exampleNumber>300123456</exampleNumber>
3259       </premiumRate>
3260       <sharedCost>
3261         <nationalNumberPattern>[34]00\d{5}</nationalNumberPattern>
3262         <possibleNumberPattern>\d{8}</possibleNumberPattern>
3263         <exampleNumber>40041234</exampleNumber>
3264       </sharedCost>
3265     </territory>
3266
3267     <!-- Bahamas -->
3268     <territory id="BS" countryCode="1" leadingDigits="242" nationalPrefix="1"
3269                internationalPrefix="011">
3270       <references>
3271         <sourceUrl>http://www.itu.int/oth/T0202000010/en</sourceUrl>
3272       </references>
3273       <generalDesc>
3274         <!-- NANPA country - uses US formatting rules -->
3275         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
3276         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
3277       </generalDesc>
3278       <fixedLine>
3279         <nationalNumberPattern>
3280           242(?:
3281             3(?:
3282               02|
3283               [236][1-9]|
3284               4[0-24-9]|
3285               5[0-68]|
3286               7[3467]|
3287               8[0-4]|
3288               9[2-467]
3289             )|
3290             461|
3291             502|
3292             6(?:
3293               0[12]|
3294               12|
3295               7[67]|
3296               8[78]|
3297               9[89]
3298             )|
3299             702
3300           )\d{4}
3301         </nationalNumberPattern>
3302         <exampleNumber>2423456789</exampleNumber>
3303       </fixedLine>
3304       <mobile>
3305         <nationalNumberPattern>
3306           242(?:
3307             3(?:
3308               5[79]|
3309               [79]5
3310             )|
3311             4(?:
3312               [2-4][1-9]|
3313               5[1-8]|
3314               6[2-8]|
3315               7\d|
3316               81
3317             )|
3318             5(?:
3319               2[45]|
3320               3[35]|
3321               44|
3322               5[1-9]|
3323               65|
3324               77
3325             )|
3326             6[34]6|
3327             727
3328           )\d{4}
3329         </nationalNumberPattern>
3330         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3331         <exampleNumber>2423591234</exampleNumber>
3332       </mobile>
3333       <tollFree>
3334         <!-- 242 300 is a Domestic Toll Free service. -->
3335         <nationalNumberPattern>
3336           242300\d{4}|
3337           8(?:
3338             00|
3339             44|
3340             55|
3341             66|
3342             77|
3343             88
3344           )[2-9]\d{6}
3345         </nationalNumberPattern>
3346         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3347         <exampleNumber>8002123456</exampleNumber>
3348       </tollFree>
3349       <premiumRate>
3350         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
3351         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3352         <exampleNumber>9002123456</exampleNumber>
3353       </premiumRate>
3354       <personalNumber>
3355         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
3356         <nationalNumberPattern>
3357           5(?:
3358             00|
3359             33|
3360             44|
3361             66|
3362             77
3363           )[2-9]\d{6}
3364         </nationalNumberPattern>
3365         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3366         <exampleNumber>5002345678</exampleNumber>
3367       </personalNumber>
3368     </territory>
3369
3370     <!-- Bhutan -->
3371     <territory id="BT" countryCode="975" internationalPrefix="00">
3372       <references>
3373         <sourceUrl>http://www.itu.int/oth/T0202000019/en</sourceUrl>
3374       </references>
3375       <availableFormats>
3376         <!-- Format is from
3377              http://www.tourism.gov.bt/tour-operators/bhutan-abbot-tours-and-travels.html -->
3378         <numberFormat pattern="([17]7)(\d{2})(\d{2})(\d{2})">
3379           <leadingDigits>
3380             1|
3381             77
3382           </leadingDigits>
3383           <format>$1 $2 $3 $4</format>
3384         </numberFormat>
3385         <numberFormat pattern="([2-8])(\d{3})(\d{3})">
3386           <leadingDigits>
3387             [2-68]|
3388             7[246]
3389           </leadingDigits>
3390           <format>$1 $2 $3</format>
3391         </numberFormat>
3392       </availableFormats>
3393       <generalDesc>
3394         <nationalNumberPattern>[1-8]\d{6,7}</nationalNumberPattern>
3395         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
3396       </generalDesc>
3397       <fixedLine>
3398         <nationalNumberPattern>
3399           (?:
3400             2[3-6]|
3401             [34][5-7]|
3402             5[236]|
3403             6[2-46]|
3404             7[246]|
3405             8[2-4]
3406           )\d{5}
3407         </nationalNumberPattern>
3408         <possibleNumberPattern>\d{6,7}</possibleNumberPattern>
3409         <exampleNumber>2345678</exampleNumber>
3410       </fixedLine>
3411       <mobile>
3412         <!-- The 77 prefix is not yet in the ITU document but numbers online indicate this prefix
3413              is in use. -->
3414         <nationalNumberPattern>[17]7\d{6}</nationalNumberPattern>
3415         <possibleNumberPattern>\d{8}</possibleNumberPattern>
3416         <exampleNumber>17123456</exampleNumber>
3417       </mobile>
3418       <!-- No information on other types of phone numbers for Bhutan has been found. -->
3419     </territory>
3420
3421     <!-- Botswana -->
3422     <territory id="BW" countryCode="267" internationalPrefix="00">
3423       <references>
3424         <sourceUrl>http://www.itu.int/oth/T020200001C/en</sourceUrl>
3425       </references>
3426       <availableFormats>
3427         <numberFormat pattern="(\d{3})(\d{4})">
3428           <leadingDigits>[2-6]</leadingDigits>
3429           <format>$1 $2</format>
3430         </numberFormat>
3431         <numberFormat pattern="(7\d)(\d{3})(\d{3})">
3432           <leadingDigits>7</leadingDigits>
3433           <format>$1 $2 $3</format>
3434         </numberFormat>
3435         <numberFormat pattern="(90)(\d{5})">
3436           <leadingDigits>9</leadingDigits>
3437           <format>$1 $2</format>
3438         </numberFormat>
3439       </availableFormats>
3440       <generalDesc>
3441         <nationalNumberPattern>[2-79]\d{6,7}</nationalNumberPattern>
3442         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
3443       </generalDesc>
3444       <fixedLine>
3445         <nationalNumberPattern>
3446           (?:
3447             2(?:
3448               4[0-48]|
3449               6[0-24]|
3450               9[0578]
3451             )|
3452             3(?:
3453               1[0235-9]|
3454               55|
3455               6\d|
3456               7[01]|
3457               9[0-57]
3458             )|
3459             4(?:
3460               6[03]|
3461               7[1267]|
3462               9[0-5]
3463             )|
3464             5(?:
3465               3[0389]|
3466               4[0489]|
3467               7[1-47]|
3468               88|
3469               9[0-49]
3470             )|
3471             6(?:
3472               2[1-35]|
3473               5[149]|
3474               8[067]
3475             )
3476           )\d{4}
3477         </nationalNumberPattern>
3478         <possibleNumberPattern>\d{7}</possibleNumberPattern>
3479         <exampleNumber>2401234</exampleNumber>
3480       </fixedLine>
3481       <mobile>
3482         <nationalNumberPattern>
3483           7(?:
3484             [1-356]\d|
3485             4[0-7]|
3486             7[014-7]
3487           )\d{5}
3488         </nationalNumberPattern>
3489         <possibleNumberPattern>\d{8}</possibleNumberPattern>
3490         <exampleNumber>71123456</exampleNumber>
3491       </mobile>
3492       <!-- No reliable information about toll-free numbers can be found; many are written on the
3493            internet like 0800 123 456, but this is not supported by any documentation and no
3494            numbers can be found that actually work. -->
3495       <premiumRate>
3496         <nationalNumberPattern>90\d{5}</nationalNumberPattern>
3497         <possibleNumberPattern>\d{7}</possibleNumberPattern>
3498         <exampleNumber>9012345</exampleNumber>
3499       </premiumRate>
3500       <voip>
3501         <nationalNumberPattern>79[12][01]\d{4}</nationalNumberPattern>
3502         <possibleNumberPattern>\d{8}</possibleNumberPattern>
3503         <exampleNumber>79101234</exampleNumber>
3504       </voip>
3505     </territory>
3506
3507     <!-- Belarus -->
3508     <!-- Information on national prefix provided by a Belarussian person. -->
3509     <territory id="BY" countryCode="375" preferredInternationalPrefix="8~10"
3510                internationalPrefix="810" nationalPrefixForParsing="8?0?"
3511                nationalPrefix="8" mobileNumberPortableRegion="true">
3512       <references>
3513         <sourceUrl>http://www.eng.beltelecom.by/en/subscribers/phone-codes</sourceUrl>
3514       </references>
3515       <availableFormats>
3516         <numberFormat nationalPrefixFormattingRule="$NP 0$FG"
3517           pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
3518           <leadingDigits>
3519             17[0-3589]|
3520             2[4-9]|
3521             [34]
3522           </leadingDigits>
3523           <leadingDigits>
3524             17(?:
3525               [02358]|
3526               1[0-2]|
3527               9[0189]
3528             )|
3529             2[4-9]|
3530             [34]
3531           </leadingDigits>
3532           <format>$1 $2-$3-$4</format>
3533         </numberFormat>
3534         <numberFormat nationalPrefixFormattingRule="$NP 0$FG"
3535           pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
3536           <leadingDigits>
3537             1(?:
3538               5[24]|
3539               6[235]|
3540               7[467]
3541             )|
3542             2(?:
3543               1[246]|
3544               2[25]|
3545               3[26]
3546             )
3547           </leadingDigits>
3548           <leadingDigits>
3549             1(?:
3550               5[24]|
3551               6(?:
3552                 2|
3553                 3[04-9]|
3554                 5[0346-9]
3555               )|
3556               7(?:
3557                 [46]|
3558                 7[37-9]
3559               )
3560             )|
3561             2(?:
3562               1[246]|
3563               2[25]|
3564               3[26]
3565             )
3566           </leadingDigits>
3567           <format>$1 $2-$3-$4</format>
3568         </numberFormat>
3569         <numberFormat nationalPrefixFormattingRule="$NP 0$FG"
3570           pattern="(\d{4})(\d{2})(\d{3})">
3571           <leadingDigits>
3572             1(?:
3573               5[169]|
3574               6[3-5]|
3575               7[179]
3576             )|
3577             2(?:
3578               1[35]|
3579               2[34]|
3580               3[3-5]
3581             )
3582           </leadingDigits>
3583           <leadingDigits>
3584             1(?:
3585               5[169]|
3586               6(?:
3587                 3[1-3]|
3588                 4|
3589                 5[125]
3590               )|
3591               7(?:
3592                 1[3-9]|
3593                 7[0-24-6]|
3594                 9[2-7]
3595               )
3596             )|
3597             2(?:
3598               1[35]|
3599               2[34]|
3600               3[3-5]
3601             )
3602           </leadingDigits>
3603           <format>$1 $2-$3</format>
3604         </numberFormat>
3605         <numberFormat nationalPrefixFormattingRule="$NP $FG"
3606           pattern="([89]\d{2})(\d{3})(\d{4})">
3607           <leadingDigits>
3608             8[01]|
3609             9
3610           </leadingDigits>
3611           <format>$1 $2 $3</format>
3612         </numberFormat>
3613         <numberFormat nationalPrefixFormattingRule="$NP $FG"
3614           pattern="(8\d{2})(\d{4})(\d{4})">
3615           <leadingDigits>82</leadingDigits>
3616           <format>$1 $2 $3</format>
3617         </numberFormat>
3618       </availableFormats>
3619       <generalDesc>
3620         <nationalNumberPattern>
3621           [1-4]\d{8}|
3622           [89]\d{9,10}
3623         </nationalNumberPattern>
3624         <!-- Numbers are often written without the city code. -->
3625         <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
3626       </generalDesc>
3627       <!-- Toll-free and premium rate numbers are not available from abroad. -->
3628       <noInternationalDialling>
3629         <nationalNumberPattern>
3630           8(?:
3631             [013]|
3632             [12]0
3633           )\d{8}|
3634           902\d{7}
3635         </nationalNumberPattern>
3636         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
3637         <exampleNumber>82012345678</exampleNumber>
3638       </noInternationalDialling>
3639       <fixedLine>
3640         <nationalNumberPattern>
3641           (?:
3642             1(?:
3643               5(?:
3644                 1[1-5]|
3645                 [24]\d|
3646                 6[2-4]|
3647                 9[1-7]
3648               )|
3649               6(?:
3650                 [235]\d|
3651                 4[1-7]
3652               )|
3653               7\d{2}
3654             )|
3655             2(?:
3656               1(?:
3657                 [246]\d|
3658                 3[0-35-9]|
3659                 5[1-9]
3660               )|
3661               2(?:
3662                 [235]\d|
3663                 4[0-8]
3664               )|
3665               3(?:
3666                 [26]\d|
3667                 3[02-79]|
3668                 4[024-7]|
3669                 5[03-7]
3670               )
3671             )
3672           )\d{5}
3673         </nationalNumberPattern>
3674         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
3675         <!-- Using test number for Grodno from the plan. -->
3676         <exampleNumber>152450911</exampleNumber>
3677       </fixedLine>
3678       <mobile>
3679         <nationalNumberPattern>
3680           (?:
3681             2(?:
3682               5[5679]|
3683               9[1-9]
3684             )|
3685             33\d|
3686             44\d
3687           )\d{6}
3688         </nationalNumberPattern>
3689         <possibleNumberPattern>\d{9}</possibleNumberPattern>
3690         <!-- Using test number for BelCel from the plan. -->
3691         <exampleNumber>294911911</exampleNumber>
3692       </mobile>
3693       <tollFree>
3694         <!-- Putting Interactive Polling Service (free) here too. -->
3695         <nationalNumberPattern>
3696           8(?:
3697             0[13]|
3698             20\d
3699           )\d{7}
3700         </nationalNumberPattern>
3701         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
3702         <exampleNumber>8011234567</exampleNumber>
3703       </tollFree>
3704       <premiumRate>
3705         <!-- Putting Interactive Polling Service (paid) here too. -->
3706         <nationalNumberPattern>
3707           (?:
3708             810|
3709             902
3710           )\d{7}
3711         </nationalNumberPattern>
3712         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3713         <exampleNumber>9021234567</exampleNumber>
3714       </premiumRate>
3715       <voip>
3716         <!-- 249 prefix for Beltelcom's Maxiphone added based on online info. -->
3717         <nationalNumberPattern>249\d{6}</nationalNumberPattern>
3718         <possibleNumberPattern>\d{9}</possibleNumberPattern>
3719         <exampleNumber>249123456</exampleNumber>
3720       </voip>
3721     </territory>
3722
3723     <!-- Belize -->
3724     <!-- The trunk prefix, formally 0, was dropped in the last reorganisation of the numbering plan.
3725          -->
3726     <territory id="BZ" countryCode="501" internationalPrefix="00" leadingZeroPossible="true">
3727       <references>
3728         <sourceUrl>http://www.itu.int/oth/T0202000016/en</sourceUrl>
3729       </references>
3730       <availableFormats>
3731         <numberFormat pattern="(\d{3})(\d{4})">
3732           <leadingDigits>[2-8]</leadingDigits>
3733           <!-- Adding hyphen following the Belize Telemedia formatting rules. -->
3734           <format>$1-$2</format>
3735         </numberFormat>
3736         <numberFormat pattern="(0)(800)(\d{4})(\d{3})">
3737           <leadingDigits>0</leadingDigits>
3738           <format>$1-$2-$3-$4</format>
3739         </numberFormat>
3740       </availableFormats>
3741       <generalDesc>
3742         <nationalNumberPattern>
3743           [2-8]\d{6}|
3744           0\d{10}
3745         </nationalNumberPattern>
3746         <possibleNumberPattern>\d{7}(?:\d{4})?</possibleNumberPattern>
3747       </generalDesc>
3748       <fixedLine>
3749         <nationalNumberPattern>[234578][02]\d{5}</nationalNumberPattern>
3750         <possibleNumberPattern>\d{7}</possibleNumberPattern>
3751         <exampleNumber>2221234</exampleNumber>
3752       </fixedLine>
3753       <mobile>
3754         <!-- 62[6-9], 63X and 6[67][2-9] were added as we have been able to successfully send SMSs
3755              to these numbers or many numbers have been found online. -->
3756         <nationalNumberPattern>6[0-367]\d{5}</nationalNumberPattern>
3757         <possibleNumberPattern>\d{7}</possibleNumberPattern>
3758         <exampleNumber>6221234</exampleNumber>
3759       </mobile>
3760       <!-- We don't know how these would be dialled internationally - it is possible that they can't
3761            be dialled internationally at all - so we represent the leading 0 as part of the number.
3762            Information from http://www.belizetelemedia.net. -->
3763       <tollFree>
3764         <nationalNumberPattern>0800\d{7}</nationalNumberPattern>
3765         <possibleNumberPattern>\d{11}</possibleNumberPattern>
3766         <exampleNumber>08001234123</exampleNumber>
3767       </tollFree>
3768     </territory>
3769
3770     <!-- Canada -->
3771     <territory id="CA" countryCode="1" internationalPrefix="011" nationalPrefix="1"
3772                mobileNumberPortableRegion="true">
3773       <references>
3774         <sourceUrl>http://www.cnac.ca/canadian_dial_plan/canadian_dial_plan.htm</sourceUrl>
3775       </references>
3776       <generalDesc>
3777         <!-- NANPA country - uses US formatting rules -->
3778         <nationalNumberPattern>
3779           [2-9]\d{9}|
3780           3\d{6}
3781         </nationalNumberPattern>
3782         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
3783       </generalDesc>
3784       <fixedLine>
3785         <nationalNumberPattern>
3786           (?:
3787             2(?:
3788               04|
3789               [23]6|
3790               [48]9|
3791               50
3792             )|
3793             3(?:
3794               06|
3795               43|
3796               65
3797             )|
3798             4(?:
3799               03|
3800               1[68]|
3801               3[178]|
3802               50
3803             )|
3804             5(?:
3805               06|
3806               1[49]|
3807               48|
3808               79|
3809               8[17]
3810             )|
3811             6(?:
3812               0[04]|
3813               13|
3814               22|
3815               39|
3816               47
3817             )|
3818             7(?:
3819               0[59]|
3820               78|
3821               8[02]
3822             )|
3823             8(?:
3824               [06]7|
3825               19|
3826               73
3827             )|
3828             90[25]
3829           )[2-9]\d{6}|
3830           310\d{4}
3831         </nationalNumberPattern>
3832         <exampleNumber>2042345678</exampleNumber>
3833       </fixedLine>
3834       <mobile>
3835         <nationalNumberPattern>
3836           (?:
3837             2(?:
3838               04|
3839               [23]6|
3840               [48]9|
3841               50
3842             )|
3843             3(?:
3844               06|
3845               43|
3846               65
3847             )|
3848             4(?:
3849               03|
3850               1[68]|
3851               3[178]|
3852               50
3853             )|
3854             5(?:
3855               06|
3856               1[49]|
3857               48|
3858               79|
3859               8[17]
3860             )|
3861             6(?:
3862               0[04]|
3863               13|
3864               22|
3865               39|
3866               47
3867             )|
3868             7(?:
3869               0[59]|
3870               78|
3871               8[02]
3872             )|
3873             8(?:
3874               [06]7|
3875               19|
3876               73
3877             )|
3878             90[25]
3879           )[2-9]\d{6}
3880         </nationalNumberPattern>
3881         <exampleNumber>2042345678</exampleNumber>
3882       </mobile>
3883       <tollFree>
3884         <nationalNumberPattern>
3885           8(?:
3886             00|
3887             44|
3888             55|
3889             66|
3890             77|
3891             88
3892           )[2-9]\d{6}|
3893           310\d{4}
3894         </nationalNumberPattern>
3895         <exampleNumber>8002123456</exampleNumber>
3896       </tollFree>
3897       <premiumRate>
3898         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
3899         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3900         <exampleNumber>9002123456</exampleNumber>
3901       </premiumRate>
3902       <personalNumber>
3903         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
3904         <nationalNumberPattern>
3905           5(?:
3906             00|
3907             33|
3908             44|
3909             66|
3910             77
3911           )[2-9]\d{6}
3912         </nationalNumberPattern>
3913         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3914         <exampleNumber>5002345678</exampleNumber>
3915       </personalNumber>
3916     </territory>
3917
3918     <!-- Cocos Islands -->
3919     <!-- Metadata shared with Australia. -->
3920     <!-- References state Cocos Islands have fixed line numbers starting +61 8 9162. -->
3921     <territory id="CC" countryCode="61" preferredInternationalPrefix="0011"
3922                internationalPrefix="(?:14(?:1[14]|34|4[17]|[56]6|7[47]|88))?001[14-689]"
3923                nationalPrefix="0">
3924       <references>
3925         <sourceUrl>http://en.wikipedia.org/wiki/List_of_country_calling_codes</sourceUrl>
3926         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia</sourceUrl>
3927       </references>
3928       <!-- Uses AU formatting rules. -->
3929       <!-- General desc and fixed line rules different from Australia. -->
3930       <generalDesc>
3931         <nationalNumberPattern>[1458]\d{5,9}</nationalNumberPattern>
3932         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
3933       </generalDesc>
3934       <fixedLine>
3935         <nationalNumberPattern>89162\d{4}</nationalNumberPattern>
3936         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
3937         <exampleNumber>891621234</exampleNumber>
3938       </fixedLine>
3939       <!-- Mobile, toll free, premium rate, personal number and VOIP copied from Australia. -->
3940       <mobile>
3941         <nationalNumberPattern>
3942           14(?:
3943             5\d|
3944             71
3945           )\d{5}|
3946           4(?:
3947             [0-2]\d|
3948             3[0-57-9]|
3949             4[47-9]|
3950             5[0-25-9]|
3951             6[6-9]|
3952             7[03-9]|
3953             8[17-9]|
3954             9[017-9]
3955           )\d{6}
3956         </nationalNumberPattern>
3957         <possibleNumberPattern>\d{9}</possibleNumberPattern>
3958         <exampleNumber>412345678</exampleNumber>
3959       </mobile>
3960       <tollFree>
3961         <nationalNumberPattern>
3962           1(?:
3963             80(?:
3964               0\d{2}
3965             )?|
3966             3(?:
3967               00\d{2}
3968             )?
3969           )\d{4}
3970         </nationalNumberPattern>
3971         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
3972         <exampleNumber>1800123456</exampleNumber>
3973       </tollFree>
3974       <premiumRate>
3975         <nationalNumberPattern>190[0126]\d{6}</nationalNumberPattern>
3976         <possibleNumberPattern>\d{10}</possibleNumberPattern>
3977         <exampleNumber>1900123456</exampleNumber>
3978       </premiumRate>
3979       <personalNumber>
3980         <nationalNumberPattern>500\d{6}</nationalNumberPattern>
3981         <possibleNumberPattern>\d{9}</possibleNumberPattern>
3982         <exampleNumber>500123456</exampleNumber>
3983       </personalNumber>
3984       <voip>
3985         <nationalNumberPattern>550\d{6}</nationalNumberPattern>
3986         <possibleNumberPattern>\d{9}</possibleNumberPattern>
3987         <exampleNumber>550123456</exampleNumber>
3988       </voip>
3989     </territory>
3990
3991     <!-- Congo, Dem. Rep. of the (formerly Zaire) -->
3992     <territory id="CD" countryCode="243" internationalPrefix="00"
3993                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
3994       <references>
3995         <sourceUrl>http://www.itu.int/oth/T0202000037/en</sourceUrl>
3996       </references>
3997       <availableFormats>
3998         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
3999           <leadingDigits>12</leadingDigits>
4000           <format>$1 $2 $3</format>
4001         </numberFormat>
4002         <numberFormat pattern="([89]\d{2})(\d{3})(\d{3})">
4003           <leadingDigits>
4004             8[0-2459]|
4005             9
4006           </leadingDigits>
4007           <format>$1 $2 $3</format>
4008         </numberFormat>
4009         <numberFormat pattern="(\d{2})(\d{2})(\d{3})">
4010           <leadingDigits>88</leadingDigits>
4011           <format>$1 $2 $3</format>
4012         </numberFormat>
4013         <numberFormat pattern="(\d{2})(\d{5})">
4014           <leadingDigits>[1-6]</leadingDigits>
4015           <format>$1 $2</format>
4016         </numberFormat>
4017       </availableFormats>
4018       <generalDesc>
4019         <nationalNumberPattern>
4020           [2-6]\d{6}|
4021           [18]\d{6,8}|
4022           9\d{8}
4023         </nationalNumberPattern>
4024         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
4025       </generalDesc>
4026       <fixedLine>
4027         <nationalNumberPattern>
4028           1(?:
4029             2\d{7}|
4030             \d{6}
4031           )|
4032           [2-6]\d{6}
4033         </nationalNumberPattern>
4034         <exampleNumber>1234567</exampleNumber>
4035       </fixedLine>
4036       <mobile>
4037         <!-- As of May'13 the 88 range looks as if it is defunct. The ITU document lists "Yozma
4038              Timeturns" as the operator, but their website (http://www.ytt.cd) is offline and the
4039              holdings company http://www.timeturnsholdings.com/products does not show a link for
4040              DRC. While there are still numbers of the form "88\d{5}" online, none of the ones
4041              tried were valid. If the holdings company does not respond to requests about this
4042              range and unless we receive further information, we will remove this range. -->
4043         <nationalNumberPattern>
4044           8(?:
4045             [0-2459]\d{2}|
4046             8
4047           )\d{5}|
4048           9[7-9]\d{7}
4049         </nationalNumberPattern>
4050         <exampleNumber>991234567</exampleNumber>
4051       </mobile>
4052     </territory>
4053
4054     <!-- Central African Republic -->
4055     <territory id="CF" countryCode="236" internationalPrefix="00">
4056       <references>
4057         <sourceUrl>http://www.itu.int/oth/T0202000028/en</sourceUrl>
4058       </references>
4059       <availableFormats>
4060         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
4061           <format>$1 $2 $3 $4</format>
4062         </numberFormat>
4063       </availableFormats>
4064       <generalDesc>
4065         <nationalNumberPattern>[278]\d{7}</nationalNumberPattern>
4066         <possibleNumberPattern>\d{8}</possibleNumberPattern>
4067       </generalDesc>
4068       <fixedLine>
4069         <nationalNumberPattern>2[12]\d{6}</nationalNumberPattern>
4070         <exampleNumber>21612345</exampleNumber>
4071       </fixedLine>
4072       <mobile>
4073         <nationalNumberPattern>7[0257]\d{6}</nationalNumberPattern>
4074         <exampleNumber>70012345</exampleNumber>
4075       </mobile>
4076       <premiumRate>
4077         <nationalNumberPattern>8776\d{4}</nationalNumberPattern>
4078         <exampleNumber>87761234</exampleNumber>
4079       </premiumRate>
4080     </territory>
4081
4082     <!-- Congo (Rep. of the) (Brazzaville) -->
4083     <territory id="CG" countryCode="242" internationalPrefix="00" leadingZeroPossible="true">
4084       <references>
4085         <sourceUrl>http://www.itu.int/oth/T020200002E/en</sourceUrl>
4086       </references>
4087       <availableFormats>
4088         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
4089           <leadingDigits>[02]</leadingDigits>
4090           <format>$1 $2 $3</format>
4091         </numberFormat>
4092         <numberFormat pattern="(\d)(\d{4})(\d{4})">
4093           <leadingDigits>8</leadingDigits>
4094           <format>$1 $2 $3</format>
4095         </numberFormat>
4096       </availableFormats>
4097       <generalDesc>
4098         <nationalNumberPattern>[028]\d{8}</nationalNumberPattern>
4099         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4100       </generalDesc>
4101       <fixedLine>
4102         <nationalNumberPattern>222[1-589]\d{5}</nationalNumberPattern>
4103         <exampleNumber>222123456</exampleNumber>
4104       </fixedLine>
4105       <mobile>
4106         <nationalNumberPattern>0[14-6]\d{7}</nationalNumberPattern>
4107         <exampleNumber>061234567</exampleNumber>
4108       </mobile>
4109       <!-- Referred to as a "Green number" in the telephone plan. -->
4110       <tollFree>
4111         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
4112         <exampleNumber>800123456</exampleNumber>
4113       </tollFree>
4114     </territory>
4115
4116     <!-- Switzerland -->
4117     <territory id="CH" countryCode="41" internationalPrefix="00"
4118                nationalPrefix="0"  nationalPrefixFormattingRule="$NP$FG"
4119                mobileNumberPortableRegion="true">
4120       <references>
4121         <!-- Under Technical prescriptions: Numbering plan for international carriers. -->
4122         <sourceUrl>http://www.bakom.admin.ch/themen/telekom/00479/00604/index.html?lang=en</sourceUrl>
4123       </references>
4124       <availableFormats>
4125         <numberFormat pattern="([2-9]\d)(\d{3})(\d{2})(\d{2})">
4126           <leadingDigits>
4127             [2-7]|
4128             [89]1
4129           </leadingDigits>
4130           <format>$1 $2 $3 $4</format>
4131         </numberFormat>
4132         <numberFormat pattern="([89]\d{2})(\d{3})(\d{3})">
4133           <leadingDigits>
4134             8[047]|
4135             90
4136           </leadingDigits>
4137           <format>$1 $2 $3</format>
4138         </numberFormat>
4139         <numberFormat pattern="(\d{3})(\d{2})(\d{3})(\d{2})(\d{2})">
4140           <leadingDigits>860</leadingDigits>
4141           <format>$1 $2 $3 $4 $5</format>
4142         </numberFormat>
4143       </availableFormats>
4144       <generalDesc>
4145         <nationalNumberPattern>
4146           [2-9]\d{8}|
4147           860\d{9}
4148         </nationalNumberPattern>
4149         <possibleNumberPattern>\d{9}(?:\d{3})?</possibleNumberPattern>
4150       </generalDesc>
4151       <fixedLine>
4152         <nationalNumberPattern>
4153           (?:
4154             2[12467]|
4155             3[1-4]|
4156             4[134]|
4157             5[256]|
4158             6[12]|
4159             [7-9]1
4160           )\d{7}
4161         </nationalNumberPattern>
4162         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4163         <exampleNumber>212345678</exampleNumber>
4164       </fixedLine>
4165       <mobile>
4166         <nationalNumberPattern>7[5-9]\d{7}</nationalNumberPattern>
4167         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4168         <exampleNumber>781234567</exampleNumber>
4169       </mobile>
4170       <pager>
4171         <!-- https://www.eofcom.admin.ch/eofcom/public/listEofcom_e164Allocated.do -->
4172         <nationalNumberPattern>74[0248]\d{6}</nationalNumberPattern>
4173         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4174         <exampleNumber>740123456</exampleNumber>
4175       </pager>
4176       <tollFree>
4177         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
4178         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4179         <exampleNumber>800123456</exampleNumber>
4180       </tollFree>
4181       <premiumRate>
4182         <nationalNumberPattern>90[016]\d{6}</nationalNumberPattern>
4183         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4184         <exampleNumber>900123456</exampleNumber>
4185       </premiumRate>
4186       <sharedCost>
4187         <nationalNumberPattern>84[0248]\d{6}</nationalNumberPattern>
4188         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4189         <exampleNumber>840123456</exampleNumber>
4190       </sharedCost>
4191       <personalNumber>
4192         <nationalNumberPattern>878\d{6}</nationalNumberPattern>
4193         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4194         <exampleNumber>878123456</exampleNumber>
4195       </personalNumber>
4196       <uan>
4197         <!-- Used for corporate networks. -->
4198         <nationalNumberPattern>5[18]\d{7}</nationalNumberPattern>
4199         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4200         <exampleNumber>581234567</exampleNumber>
4201       </uan>
4202       <voicemail>
4203         <nationalNumberPattern>860\d{9}</nationalNumberPattern>
4204         <possibleNumberPattern>\d{12}</possibleNumberPattern>
4205         <exampleNumber>860123456789</exampleNumber>
4206       </voicemail>
4207     </territory>
4208
4209     <!-- Côte d'Ivoire -->
4210     <territory id="CI" countryCode="225" internationalPrefix="00" leadingZeroPossible="true">
4211       <references>
4212         <sourceUrl>http://www.itu.int/oth/T0202000031/en</sourceUrl>
4213       </references>
4214       <availableFormats>
4215         <!-- Using format from online yellow pages over format implied in national numbering plan.
4216              -->
4217         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
4218           <format>$1 $2 $3 $4</format>
4219         </numberFormat>
4220       </availableFormats>
4221       <generalDesc>
4222         <nationalNumberPattern>[02-7]\d{7}</nationalNumberPattern>
4223         <possibleNumberPattern>\d{8}</possibleNumberPattern>
4224       </generalDesc>
4225       <fixedLine>
4226         <nationalNumberPattern>
4227           (?:
4228             2(?:
4229               0[023]|
4230               1[02357]|
4231               [23][045]|
4232               4[03-5]
4233             )|
4234             3(?:
4235               0[06]|
4236               1[069]|
4237               [2-4][07]|
4238               5[09]|
4239               6[08]
4240             )
4241           )\d{5}
4242         </nationalNumberPattern>
4243         <exampleNumber>21234567</exampleNumber>
4244       </fixedLine>
4245       <mobile>
4246         <!-- Added the prefixes 4[0-2] (Moov), 5[5-9] & 6[15] because SMS messages have been
4247              successfully delivered. Supported by numbers found on the internet. Also added 43
4248              (Moov) based on numbers found online. The prefix 56 was assigned to MTN in July 2013:
4249              http://www.atci.ci/images/stories/pdf/decisions-dg/decision_002.pdf
4250              The prefix 75 is from an open-source bug report.
4251              50 has been removed since Warid seems to have stopped operation in Côte d'Ivoire. -->
4252           <nationalNumberPattern>
4253           (?:
4254             0[1-9]|
4255             4\d|
4256             5[4-9]|
4257             6[015-79]|
4258             7[578]
4259           )\d{6}
4260         </nationalNumberPattern>
4261         <exampleNumber>01234567</exampleNumber>
4262       </mobile>
4263     </territory>
4264
4265     <!-- Cook Islands -->
4266     <territory id="CK" countryCode="682" internationalPrefix="00">
4267       <references>
4268         <sourceUrl>http://www.itu.int/oth/T020200002F/en</sourceUrl>
4269       </references>
4270       <availableFormats>
4271         <numberFormat pattern="(\d{2})(\d{3})">
4272           <format>$1 $2</format>
4273         </numberFormat>
4274       </availableFormats>
4275       <generalDesc>
4276         <nationalNumberPattern>[2-57]\d{4}</nationalNumberPattern>
4277         <possibleNumberPattern>\d{5}</possibleNumberPattern>
4278       </generalDesc>
4279       <fixedLine>
4280         <nationalNumberPattern>
4281           (?:
4282             2\d|
4283             3[13-7]|
4284             4[1-5]
4285           )\d{3}
4286         </nationalNumberPattern>
4287         <exampleNumber>21234</exampleNumber>
4288       </fixedLine>
4289       <mobile>
4290         <nationalNumberPattern>
4291           (?:
4292             5[0-68]|
4293             7\d
4294           )\d{3}
4295         </nationalNumberPattern>
4296         <exampleNumber>71234</exampleNumber>
4297       </mobile>
4298     </territory>
4299
4300     <!-- Chile -->
4301     <!-- Carriers listed here: http://www.turismochile.com/datos/carrier.php -->
4302     <territory id="CL" countryCode="56"
4303                internationalPrefix="(?:0|1(?:1[0-69]|2[0-57]|5[13-58]|69|7[0167]|8[018]))0"
4304                nationalPrefix="0"
4305                nationalPrefixForParsing="0|(1(?:1[0-69]|2[0-57]|5[13-58]|69|7[0167]|8[018]))"
4306                nationalPrefixFormattingRule="$NP$FG" mobileNumberPortableRegion="true">
4307       <references>
4308         <sourceUrl>http://www.itu.int/oth/T020200002A/en</sourceUrl>
4309         <sourceUrl>http://en.wikipedia.org/wiki/%2B56</sourceUrl>
4310         <sourceUrl>http://www.subtel.gob.cl/base_numeracion/tabla_numeracion_ido_idd.xlsx</sourceUrl>
4311       </references>
4312       <!-- When dialling mobile numbers from landlines, or vice versa, you need a prefix of 0, which
4313            we strip here. National destinations may be dialled with a carrier if they are not local
4314            so we extract these carrier codes as well. -->
4315       <availableFormats>
4316         <numberFormat pattern="(\d)(\d{4})(\d{4})"
4317           nationalPrefixFormattingRule="($FG)"
4318           carrierCodeFormattingRule="$CC ($FG)">
4319           <leadingDigits>22</leadingDigits>
4320           <format>$1 $2 $3</format>
4321         </numberFormat>
4322         <numberFormat pattern="(\d{2})(\d{3})(\d{4})"
4323           nationalPrefixFormattingRule="($FG)"
4324           carrierCodeFormattingRule="$CC ($FG)">
4325           <leadingDigits>
4326             [357]|
4327             4[1-35]|
4328             6[13-57]
4329           </leadingDigits>
4330           <format>$1 $2 $3</format>
4331         </numberFormat>
4332         <numberFormat pattern="(9)(\d{4})(\d{4})">
4333           <leadingDigits>9</leadingDigits>
4334           <format>$1 $2 $3</format>
4335         </numberFormat>
4336         <numberFormat pattern="(44)(\d{3})(\d{4})">
4337           <leadingDigits>44</leadingDigits>
4338           <format>$1 $2 $3</format>
4339         </numberFormat>
4340         <numberFormat nationalPrefixFormattingRule="$FG"
4341           pattern="([68]00)(\d{3})(\d{3,4})">
4342           <leadingDigits>
4343             60|
4344             8
4345           </leadingDigits>
4346           <format>$1 $2 $3</format>
4347         </numberFormat>
4348         <numberFormat nationalPrefixFormattingRule="$FG"
4349           pattern="(600)(\d{3})(\d{2})(\d{3})">
4350           <leadingDigits>60</leadingDigits>
4351           <format>$1 $2 $3 $4</format>
4352         </numberFormat>
4353         <numberFormat nationalPrefixFormattingRule="$FG"
4354           pattern="(1230)(\d{3})(\d{4})">
4355           <leadingDigits>1</leadingDigits>
4356           <format>$1 $2 $3</format>
4357         </numberFormat>
4358         <numberFormat pattern="(\d{5})(\d{4})"
4359           nationalPrefixFormattingRule="($FG)"
4360           carrierCodeFormattingRule="$CC ($FG)">
4361           <leadingDigits>219</leadingDigits>
4362           <format>$1 $2</format>
4363         </numberFormat>
4364         <!-- Format some short numbers as a block. -->
4365         <numberFormat nationalPrefixFormattingRule="$FG"
4366           pattern="(\d{4,5})">
4367           <leadingDigits>[1-9]</leadingDigits>
4368           <format>$1</format>
4369           <intlFormat>NA</intlFormat>
4370         </numberFormat>
4371       </availableFormats>
4372       <generalDesc>
4373         <nationalNumberPattern>
4374           (?:
4375             [2-9]|
4376             600|
4377             123
4378           )\d{7,8}
4379         </nationalNumberPattern>
4380         <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
4381       </generalDesc>
4382       <noInternationalDialling>
4383         <nationalNumberPattern>600\d{7,8}</nationalNumberPattern>
4384         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
4385         <exampleNumber>6001234567</exampleNumber>
4386       </noInternationalDialling>
4387       <fixedLine>
4388         <!-- In mid-2013, Chile switched from 8 digits to 9 digits for fixed-line numbers, by
4389              inserting a '2' after the area code (which are 2 digits, with the exception of '2').
4390              As of Aug. 2014, all of the prefixes have been switched over to the new plan.
4391              IMPORTANT: The fact that Santiago numbers have a prefix of "22", and that numbers in
4392              other areas have '2' as their third digit, is likely to change in the future. At some
4393              stage, Santiago numbers will probably switch to prefix "2\d", and the third digit in
4394              other areas will probably be allowed to take on other values.
4395              See: http://www.gob.cl/especiales/informate-de-la-nueva-forma-de-marcar/
4396                   http://www.subtel.cl/index.php?option=com_content&view=article&id=3081:&catid=3:noticias
4397              -->
4398         <nationalNumberPattern>
4399           2(?:
4400             2\d{7}|
4401             1962\d{4}
4402           )|
4403           (?:
4404             3[2-5]|
4405             [47][1-35]|
4406             5[1-3578]|
4407             6[13-57]
4408           )\d{7}
4409         </nationalNumberPattern>
4410         <!-- Area codes do not need to be dialled when dialling within the same area, so the
4411              smallest possible number is length 7. -->
4412         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
4413         <exampleNumber>221234567</exampleNumber>
4414       </fixedLine>
4415       <mobile>
4416         <nationalNumberPattern>9[4-9]\d{7}</nationalNumberPattern>
4417         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
4418         <exampleNumber>961234567</exampleNumber>
4419       </mobile>
4420       <!-- Toll free patterns have been collected by looking at numbers on the internet, rather than
4421            from a definitive source. -->
4422       <tollFree>
4423         <!-- 1230 numbers are used by Visa/Mastercard helplines in Chile -->
4424         <nationalNumberPattern>
4425           800\d{6}|
4426           1230\d{7}
4427         </nationalNumberPattern>
4428         <possibleNumberPattern>\d{9,11}</possibleNumberPattern>
4429         <exampleNumber>800123456</exampleNumber>
4430       </tollFree>
4431       <sharedCost>
4432         <!-- http://empresa.movistar.cl/nuestros_productos/soluciones_telefonia_ip/servicios/servicio_600.php -->
4433         <nationalNumberPattern>600\d{7,8}</nationalNumberPattern>
4434         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
4435         <exampleNumber>6001234567</exampleNumber>
4436       </sharedCost>
4437       <voip>
4438         <nationalNumberPattern>44\d{7}</nationalNumberPattern>
4439         <possibleNumberPattern>\d{9}</possibleNumberPattern>
4440         <exampleNumber>441234567</exampleNumber>
4441       </voip>
4442     </territory>
4443
4444     <!-- Cameroon -->
4445     <territory id="CM" countryCode="237" internationalPrefix="00">
4446       <references>
4447         <sourceUrl>http://www.itu.int/oth/T0202000024/en</sourceUrl>
4448         <sourceUrl>http://www.itu.int/dms_pub/itu-t/opb/sp/T-SP-OB.1063-2014-OAS-PDF-E.pdf</sourceUrl>
4449       </references>
4450       <availableFormats>
4451         <!-- Formatting in the ITU update document aligns with formatting online (all 2 digit
4452              groups). For the new number format with 9 digits the first digit has it's own group.
4453              -->
4454         <numberFormat pattern="([26])(\d{2})(\d{2})(\d{2})(\d{2})">
4455           <leadingDigits>[26]</leadingDigits>
4456           <format>$1 $2 $3 $4 $5</format>
4457         </numberFormat>
4458         <numberFormat pattern="([2357-9]\d)(\d{2})(\d{2})(\d{2})">
4459           <leadingDigits>
4460             [23579]|
4461             88
4462           </leadingDigits>
4463           <format>$1 $2 $3 $4</format>
4464         </numberFormat>
4465         <numberFormat pattern="(800)(\d{2})(\d{3})">
4466           <leadingDigits>80</leadingDigits>
4467           <format>$1 $2 $3</format>
4468         </numberFormat>
4469       </availableFormats>
4470       <generalDesc>
4471         <nationalNumberPattern>[235-9]\d{7,8}</nationalNumberPattern>
4472         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
4473       </generalDesc>
4474       <fixedLine>
4475         <!-- Temporarily allow both old (22|33) and new 2(22|33) format. -->
4476         <!-- CDMA numbers are described in a subcategory to fixed line numbers in the ITU update
4477              document, so those prefixes are added to fixed line (24[23]). -->
4478         <nationalNumberPattern>
4479           2(?:
4480              22|
4481              33|
4482              4[23]
4483           )\d{6}|
4484           (?:
4485             22|
4486             33
4487           )\d{6}
4488         </nationalNumberPattern>
4489         <exampleNumber>222123456</exampleNumber>
4490       </fixedLine>
4491       <mobile>
4492         <!-- Temporarily allow both old [579]\d{7} and new 6[5-79]\d{7} format. -->
4493         <nationalNumberPattern>
4494           6[5-79]\d{7}|
4495           [579]\d{7}
4496         </nationalNumberPattern>
4497         <exampleNumber>671234567</exampleNumber>
4498       </mobile>
4499       <tollFree>
4500         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
4501         <possibleNumberPattern>\d{8}</possibleNumberPattern>
4502         <exampleNumber>80012345</exampleNumber>
4503       </tollFree>
4504       <premiumRate>
4505         <!-- These numbers are listed as value-added in the guide, and in practice seem to begin
4506              with 88 (usually 880). No information can be found as to whether these are premium rate
4507              or shared cost. -->
4508         <nationalNumberPattern>88\d{6}</nationalNumberPattern>
4509         <possibleNumberPattern>\d{8}</possibleNumberPattern>
4510         <exampleNumber>88012345</exampleNumber>
4511       </premiumRate>
4512     </territory>
4513
4514     <!-- China -->
4515     <!-- The international/national prefix patterns must not collide with valid prefixes such
4516          as 170, 176, 177 and 178. 179XX00 is a valid calling prefix, see: www.chahaoba.com/179 -->
4517     <territory id="CN" countryCode="86" internationalPrefix="(1(?:[129]\d{3}|79\d{2}))?00"
4518                preferredInternationalPrefix="00" nationalPrefix="0"
4519                nationalPrefixForParsing="(1(?:[129]\d{3}|79\d{2}))|0">
4520       <references>
4521         <sourceUrl>http://www.itu.int/oth/T020200002B/en</sourceUrl>
4522       </references>
4523       <availableFormats>
4524         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(80\d{2})(\d{4})"
4525                       nationalPrefixOptionalWhenFormatting="true"
4526                       carrierCodeFormattingRule="$CC $FG">
4527           <leadingDigits>80[2678]</leadingDigits>
4528           <format>$1 $2</format>
4529         </numberFormat>
4530         <numberFormat pattern="([48]00)(\d{3})(\d{4})">
4531           <leadingDigits>[48]00</leadingDigits>
4532           <format>$1 $2 $3</format>
4533         </numberFormat>
4534         <!-- 100xx and 95xxx(x) short numbers without area codes. Without this rule, these short
4535              numbers will be formatted incorrectly by the AsYouTypeFormatter because they overlap
4536              with area codes 010, 095x. These numbers are defined in ShortNumberMetadata.xml but
4537              must be accounted for here. Note although ITU says the format is more like 95 xxx, in
4538              reality no space is used when writing such numbers in China. -->
4539         <numberFormat pattern="(\d{5,6})">
4540           <leadingDigits>
4541             100|
4542             95
4543           </leadingDigits>
4544           <format>$1</format>
4545           <intlFormat>NA</intlFormat>
4546         </numberFormat>
4547         <!-- 100xx and 95xxx(x) numbers with area codes (these numbers without an area code are now
4548              dealt with by ShortNumberMetadata.xml) and 96xxx(x) numbers with area codes (we don't
4549              support these as short numbers because they are only unique within a province, not
4550              within a country). -->
4551         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(\d{2})(\d{5,6})"
4552                       carrierCodeFormattingRule="$CC $FG">
4553           <leadingDigits>
4554             (?:
4555               10|
4556               2\d
4557             )[19]
4558           </leadingDigits>
4559           <leadingDigits>
4560             (?:
4561               10|
4562               2\d
4563             )(?:
4564               10|
4565               9[56]
4566             )
4567           </leadingDigits>
4568           <leadingDigits>
4569             (?:
4570               10|
4571               2\d
4572             )(?:
4573               100|
4574               9[56]
4575             )
4576           </leadingDigits>
4577           <format>$1 $2</format>
4578         </numberFormat>
4579         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(\d{3})(\d{5,6})"
4580                       carrierCodeFormattingRule="$CC $FG">
4581           <leadingDigits>[3-9]</leadingDigits>
4582           <leadingDigits>[3-9]\d{2}[19]</leadingDigits>
4583           <leadingDigits>
4584             [3-9]\d{2}(?:
4585               10|
4586               9[56]
4587             )
4588           </leadingDigits>
4589           <format>$1 $2</format>
4590         </numberFormat>
4591         <!-- Local numbers -->
4592         <!-- Chinese fixed-line numbers can be dialed from a cell phone without area code and they
4593              can be 7 to 8 digits. This rule is here to make formatting work with such numbers, as
4594              people frequently store them in their cellphones. It has to stay before formatting
4595              rules for fixed-line numbers to make AsYouTypeFormatter work with these numbers. The
4596              leadingDigits prefix makes sure it doesn't clash with mobile numbers. -->
4597         <numberFormat pattern="(\d{3,4})(\d{4})">
4598           <leadingDigits>[2-9]</leadingDigits>
4599           <format>$1 $2</format>
4600           <intlFormat>NA</intlFormat>
4601         </numberFormat>
4602         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(21)(\d{4})(\d{4,6})"
4603                       nationalPrefixOptionalWhenFormatting="true"
4604                       carrierCodeFormattingRule="$CC $FG">
4605           <leadingDigits>21</leadingDigits>
4606           <format>$1 $2 $3</format>
4607         </numberFormat>
4608         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="([12]\d)(\d{4})(\d{4})"
4609                       nationalPrefixOptionalWhenFormatting="true"
4610                       carrierCodeFormattingRule="$CC $FG">
4611           <leadingDigits>
4612             10[1-9]|
4613             2[02-9]
4614           </leadingDigits>
4615           <!-- Note the leadingDigitsPattern for 4 digits is the same as 3 digits, -->
4616           <leadingDigits>
4617             10[1-9]|
4618             2[02-9]
4619           </leadingDigits>
4620           <leadingDigits>
4621             10(?:
4622               [1-79]|
4623               8(?:
4624                 [1-9]|
4625                 0[1-9]
4626               )
4627             )|
4628             2[02-9]
4629           </leadingDigits>
4630           <format>$1 $2 $3</format>
4631         </numberFormat>
4632         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(\d{3})(\d{4})(\d{4})"
4633                       nationalPrefixOptionalWhenFormatting="true"
4634                       carrierCodeFormattingRule="$CC $FG">
4635           <leadingDigits>
4636             3(?:
4637               11|
4638               7[179]
4639             )|
4640             4(?:
4641               [15]1|
4642               3[12]
4643             )|
4644             5(?:
4645               1|
4646               2[37]|
4647               3[12]|
4648               51|
4649               7[13-79]|
4650               9[15]
4651             )|
4652             7(?:
4653               31|
4654               5[457]|
4655               6[09]|
4656               91
4657             )|
4658             8(?:
4659               [57]1|
4660               98
4661             )
4662           </leadingDigits>
4663           <format>$1 $2 $3</format>
4664         </numberFormat>
4665         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(\d{3})(\d{3})(\d{4})"
4666                       nationalPrefixOptionalWhenFormatting="true"
4667                       carrierCodeFormattingRule="$CC $FG">
4668           <leadingDigits>
4669             3(?:
4670               1[02-9]|
4671               35|
4672               49|
4673               5|
4674               7[02-68]|
4675               9[1-68]
4676             )|
4677             4(?:
4678               1[02-9]|
4679               2[179]|
4680               [35][2-9]|
4681               6[4789]|
4682               7\d|
4683               8[23]
4684             )|
4685             5(?:
4686               3[03-9]|
4687               4[36]|
4688               5[02-9]|
4689               6[1-46]|
4690               7[028]|
4691               80|
4692               9[2-46-9]
4693             )|
4694             6(?:
4695               3[1-5]|
4696               6[0238]|
4697               9[12]
4698             )|
4699             7(?:
4700               01|
4701               [1579]|
4702               2[248]|
4703               3[04-9]|
4704               4[3-6]|
4705               6[2368]
4706             )|
4707             8(?:
4708               1[236-8]|
4709               2[5-7]|
4710               3|
4711               5[4-9]|
4712               7[02-9]|
4713               8[3678]|
4714               9[1-7]
4715             )|
4716             9(?:
4717               0[1-3689]|
4718               1[1-79]|
4719               [379]|
4720               4[13]|
4721               5[1-5]
4722             )
4723           </leadingDigits>
4724           <format>$1 $2 $3</format>
4725         </numberFormat>
4726         <numberFormat pattern="(\d{3})(\d{4})(\d{4})" carrierCodeFormattingRule="$CC $FG">
4727           <leadingDigits>1[3-578]</leadingDigits>
4728           <format>$1 $2 $3</format>
4729         </numberFormat>
4730         <numberFormat pattern="(10800)(\d{3})(\d{4})">
4731           <leadingDigits>108</leadingDigits>
4732           <leadingDigits>1080</leadingDigits>
4733           <leadingDigits>10800</leadingDigits>
4734           <format>$1 $2 $3</format>
4735         </numberFormat>
4736         <numberFormat pattern="(\d{3})(\d{7,8})">
4737           <leadingDigits>950</leadingDigits>
4738           <format>$1 $2</format>
4739         </numberFormat>
4740       </availableFormats>
4741       <generalDesc>
4742         <nationalNumberPattern>
4743           [1-7]\d{6,11}|
4744           8[0-357-9]\d{6,9}|
4745           9\d{7,10}
4746         </nationalNumberPattern>
4747         <possibleNumberPattern>\d{4,12}</possibleNumberPattern>
4748       </generalDesc>
4749       <noInternationalDialling>
4750         <nationalNumberPattern>
4751           (?:
4752             4|
4753             (?:
4754               10
4755             )?8
4756           )00\d{7}|
4757           950\d{7,8}
4758         </nationalNumberPattern>
4759         <possibleNumberPattern>\d{10,12}</possibleNumberPattern>
4760         <exampleNumber>4001234567</exampleNumber>
4761       </noInternationalDialling>
4762       <fixedLine>
4763         <!-- 0432 increased to 8 digits on October 24, 2009. 0791 increased to 8 digits on August
4764              28, 2011. 0551 increased to 8 digits and 0565 was cancelled on Dec 8, 2012. 0871
4765              increased to 8 digits on December 16, 2012. 0475 is the prefix for Tongliao but is not
4766              in the ITU data.
4767              10xxx and 95xxx(x) numbers with area codes are also included here, as they behave
4768              exactly like fixed-line numbers. We don't support them for 4-digit area codes though,
4769              as they don't seem to be used there based on making actual phone calls.
4770          -->
4771         <nationalNumberPattern>
4772           21(?:
4773             100\d{2}|
4774             95\d{3,4}|
4775             \d{8,10}
4776           )|
4777           (?:
4778             10|
4779             2[02-57-9]|
4780             3(?:
4781               11|
4782               7[179]
4783             )|
4784             4(?:
4785               [15]1|
4786               3[12]
4787             )|
4788             5(?:
4789               1\d|
4790               2[37]|
4791               3[12]|
4792               51|
4793               7[13-79]|
4794               9[15]
4795             )|
4796             7(?:
4797               31|
4798               5[457]|
4799               6[09]|
4800               91
4801             )|
4802             8(?:
4803               [57]1|
4804               98
4805             )
4806           )(?:
4807             100\d{2}|
4808             95\d{3,4}|
4809             \d{8}
4810           )|
4811           (?:
4812             3(?:
4813               1[02-9]|
4814               35|
4815               49|
4816               5\d|
4817               7[02-68]|
4818               9[1-68]
4819             )|
4820             4(?:
4821               1[02-9]|
4822               2[179]|
4823               3[3-9]|
4824               5[2-9]|
4825               6[4789]|
4826               7\d|
4827               8[23]
4828             )|
4829             5(?:
4830               3[03-9]|
4831               4[36]|
4832               5[02-9]|
4833               6[1-46]|
4834               7[028]|
4835               80|
4836               9[2-46-9]
4837             )|
4838             6(?:
4839               3[1-5]|
4840               6[0238]|
4841               9[12]
4842             )|
4843             7(?:
4844               01|
4845               [17]\d|
4846               2[248]|
4847               3[04-9]|
4848               4[3-6]|
4849               5[0-3689]|
4850               6[2368]|
4851               9[02-9]
4852             )|
4853             8(?:
4854               1[236-8]|
4855               2[5-7]|
4856               3\d|
4857               5[4-9]|
4858               7[02-9]|
4859               8[3678]|
4860               9[1-7]
4861             )|
4862             9(?:
4863               0[1-3689]|
4864               1[1-79]|
4865               [379]\d|
4866               4[13]|
4867               5[1-5]
4868             )
4869           )(?:
4870             100\d{2}|
4871             95\d{3,4}|
4872             \d{7}
4873           )|
4874           80(?:
4875             29|
4876             6[03578]|
4877             7[018]|
4878             81
4879           )\d{4}
4880         </nationalNumberPattern>
4881         <exampleNumber>1012345678</exampleNumber>
4882       </fixedLine>
4883       <mobile>
4884         <!-- 170, 176, 177 and 178 prefixes are introduced in early 2014 for 4G networks. -->
4885         <nationalNumberPattern>
4886           1(?:
4887             [38]\d|
4888             4[57]|
4889             5[0-35-9]|
4890             7[06-8]
4891           )\d{8}
4892         </nationalNumberPattern>
4893         <possibleNumberPattern>\d{11}</possibleNumberPattern>
4894         <exampleNumber>13123456789</exampleNumber>
4895       </mobile>
4896       <!-- Toll free, premium rate, and VoIP numbers are not clearly defined in the official Chinese
4897            number plan, and do not seem to have been standardized. The information below is
4898            collected from searching the web. -->
4899       <!-- http://en.wikipedia.org/wiki/Toll-free_telephone_number -->
4900       <tollFree>
4901         <nationalNumberPattern>
4902           (?:
4903             10
4904           )?800\d{7}
4905         </nationalNumberPattern>
4906         <possibleNumberPattern>\d{10,12}</possibleNumberPattern>
4907         <exampleNumber>8001234567</exampleNumber>
4908       </tollFree>
4909       <premiumRate>
4910         <nationalNumberPattern>16[08]\d{5}</nationalNumberPattern>
4911         <possibleNumberPattern>\d{8}</possibleNumberPattern>
4912         <exampleNumber>16812345</exampleNumber>
4913       </premiumRate>
4914       <sharedCost>
4915         <!-- 96xxx(x) numbers with area codes are included here. Their costs are not well
4916              documented, but they are thought to be mostly local costs with certain exceptions. We
4917              don't support them for 4-digit area codes though, as they don't seem to be used there
4918              based on online searches. -->
4919         <nationalNumberPattern>
4920           400\d{7}|
4921           950\d{7,8}|
4922           (?:
4923             10|
4924             2[0-57-9]|
4925             3(?:
4926               [157]\d|
4927               35|
4928               49|
4929               9[1-68]
4930             )|
4931             4(?:
4932               [17]\d|
4933               2[179]|
4934               [35][1-9]|
4935               6[4789]|
4936               8[23]
4937             )|
4938             5(?:
4939               [1357]\d|
4940               2[37]|
4941               4[36]|
4942               6[1-46]|
4943               80|
4944               9[1-9]
4945             )|
4946             6(?:
4947               3[1-5]|
4948               6[0238]|
4949               9[12]
4950             )|
4951             7(?:
4952               01|
4953               [1579]\d|
4954               2[248]|
4955               3[014-9]|
4956               4[3-6]|
4957               6[023689]
4958             )|
4959             8(?:
4960               1[236-8]|
4961               2[5-7]|
4962               [37]\d|
4963               5[14-9]|
4964               8[3678]|
4965               9[1-8]
4966             )|
4967             9(?:
4968               0[1-3689]|
4969               1[1-79]|
4970               [379]\d|
4971               4[13]|
4972               5[1-5]
4973             )
4974           )96\d{3,4}
4975         </nationalNumberPattern>
4976         <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
4977         <exampleNumber>4001234567</exampleNumber>
4978       </sharedCost>
4979     </territory>
4980
4981     <!-- Colombia -->
4982     <!-- Extra international dialling prefixes from http://www.claro.com.co and
4983          http://www.tigo.com.co. -->
4984     <!-- 05 and 005 are for Orbitel: co.orbitel.com -->
4985     <territory id="CO" countryCode="57" internationalPrefix="00(?:4(?:[14]4|56)|[579])"
4986                nationalPrefix="0" nationalPrefixForParsing="0([3579]|4(?:44|56))?"
4987                mobileNumberPortableRegion="true">
4988       <references>
4989         <sourceUrl>http://www.itu.int/oth/T020200002C/en</sourceUrl>
4990         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Colombia</sourceUrl>
4991       </references>
4992       <availableFormats>
4993         <numberFormat pattern="(\d)(\d{7})" carrierCodeFormattingRule="$NP$CC $FG"
4994           nationalPrefixFormattingRule="($FG)">
4995           <leadingDigits>
4996             1(?:
4997               8[2-9]|
4998               9[0-3]|
4999               [2-7]
5000             )|
5001             [24-8]
5002           </leadingDigits>
5003           <leadingDigits>
5004             1(?:
5005               8[2-9]|
5006               9(?:
5007                 09|
5008                 [1-3]
5009               )|
5010               [2-7]
5011             )|
5012             [24-8]
5013           </leadingDigits>
5014           <format>$1 $2</format>
5015         </numberFormat>
5016         <numberFormat pattern="(\d{3})(\d{7})" carrierCodeFormattingRule="$NP$CC $FG">
5017           <leadingDigits>3</leadingDigits>
5018           <format>$1 $2</format>
5019         </numberFormat>
5020         <numberFormat pattern="(1)(\d{3})(\d{7})" nationalPrefixFormattingRule="$NP$FG">
5021           <leadingDigits>
5022             1(?:
5023               80|
5024               9[04]
5025             )
5026           </leadingDigits>
5027           <leadingDigits>
5028             1(?:
5029               800|
5030               9(?:
5031                 0[01]|
5032                 4[78]
5033               )
5034             )
5035           </leadingDigits>
5036           <format>$1-$2-$3</format>
5037           <intlFormat>$1 $2 $3</intlFormat>
5038         </numberFormat>
5039       </availableFormats>
5040       <generalDesc>
5041         <nationalNumberPattern>
5042           (?:
5043             [13]\d{0,3}|
5044             [24-8]
5045           )\d{7}
5046         </nationalNumberPattern>
5047         <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
5048       </generalDesc>
5049       <fixedLine>
5050         <nationalNumberPattern>[124-8][2-9]\d{6}</nationalNumberPattern>
5051         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5052         <exampleNumber>12345678</exampleNumber>
5053       </fixedLine>
5054       <mobile>
5055         <nationalNumberPattern>
5056           3(?:
5057             0[0-5]|
5058             1\d|
5059             2[0-2]|
5060             5[01]
5061           )\d{7}
5062         </nationalNumberPattern>
5063         <possibleNumberPattern>\d{10}</possibleNumberPattern>
5064         <exampleNumber>3211234567</exampleNumber>
5065       </mobile>
5066       <tollFree>
5067         <nationalNumberPattern>1800\d{7}</nationalNumberPattern>
5068         <possibleNumberPattern>\d{11}</possibleNumberPattern>
5069         <exampleNumber>18001234567</exampleNumber>
5070       </tollFree>
5071       <premiumRate>
5072         <nationalNumberPattern>
5073           19(?:
5074             0[01]|
5075             4[78]
5076           )\d{7}
5077         </nationalNumberPattern>
5078         <possibleNumberPattern>\d{11}</possibleNumberPattern>
5079         <exampleNumber>19001234567</exampleNumber>
5080       </premiumRate>
5081     </territory>
5082
5083     <!-- Costa Rica -->
5084     <territory id="CR" countryCode="506" internationalPrefix="00"
5085                nationalPrefixForParsing="(19(?:0[012468]|1[09]|20|66|77|99))"
5086                carrierCodeFormattingRule="$CC $FG">
5087       <references>
5088         <sourceUrl>http://www.itu.int/oth/T0202000030/en</sourceUrl>
5089       </references>
5090       <availableFormats>
5091         <numberFormat pattern="(\d{4})(\d{4})">
5092           <leadingDigits>
5093             [24-7]|
5094             8[3-9]
5095           </leadingDigits>
5096           <format>$1 $2</format>
5097         </numberFormat>
5098         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
5099           <leadingDigits>[89]0</leadingDigits>
5100           <format>$1-$2-$3</format>
5101         </numberFormat>
5102       </availableFormats>
5103       <generalDesc>
5104         <nationalNumberPattern>[24-9]\d{7,9}</nationalNumberPattern>
5105         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
5106       </generalDesc>
5107       <fixedLine>
5108         <nationalNumberPattern>2[24-7]\d{6}</nationalNumberPattern>
5109         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5110         <exampleNumber>22123456</exampleNumber>
5111       </fixedLine>
5112       <mobile>
5113         <nationalNumberPattern>
5114           5(?:
5115             0[01]|
5116             7[0-3]
5117           )\d{5}|
5118           6(?:
5119             [0-2]\d|
5120             30
5121           )\d{5}|
5122           7[0-3]\d{6}|
5123           8[3-9]\d{6}
5124         </nationalNumberPattern>
5125         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5126         <exampleNumber>83123456</exampleNumber>
5127       </mobile>
5128       <tollFree>
5129         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
5130         <possibleNumberPattern>\d{10}</possibleNumberPattern>
5131         <exampleNumber>8001234567</exampleNumber>
5132       </tollFree>
5133       <premiumRate>
5134         <!-- Includes "mass calls" numbers with prefix 905. -->
5135         <nationalNumberPattern>90[059]\d{7}</nationalNumberPattern>
5136         <possibleNumberPattern>\d{10}</possibleNumberPattern>
5137         <exampleNumber>9001234567</exampleNumber>
5138       </premiumRate>
5139       <voip>
5140         <!-- Including trunking service numbers starting with 5100. 4001 (callmyway.com) was added
5141              from an open-source bug report supported by numbers found online. -->
5142         <nationalNumberPattern>
5143           210[0-6]\d{4}|
5144           4(?:
5145             0(?:
5146               0[01]\d{4}|
5147               10[0-3]\d{3}|
5148               2(?:
5149                 00\d{3}|
5150                 900\d{2}
5151               )|
5152               3[01]\d{4}|
5153               40\d{4}|
5154               5\d{5}|
5155               60\d{4}|
5156               70[01]\d{3}|
5157               8[0-2]\d{4}
5158             )|
5159             1[01]\d{5}|
5160             20[0-3]\d{4}|
5161             400\d{4}|
5162             70[0-2]\d{4}
5163           )|
5164           5100\d{4}
5165         </nationalNumberPattern>
5166         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5167         <exampleNumber>40001234</exampleNumber>
5168       </voip>
5169     </territory>
5170
5171     <!-- Cuba -->
5172     <territory id="CU" countryCode="53" internationalPrefix="119"
5173                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
5174       <references>
5175         <sourceUrl>http://www.itu.int/oth/T0202000033/en</sourceUrl>
5176       </references>
5177       <availableFormats>
5178         <numberFormat pattern="(\d)(\d{6,7})">
5179           <leadingDigits>7</leadingDigits>
5180           <format>$1 $2</format>
5181         </numberFormat>
5182         <numberFormat pattern="(\d{2})(\d{4,6})">
5183           <leadingDigits>[2-4]</leadingDigits>
5184           <format>$1 $2</format>
5185         </numberFormat>
5186         <numberFormat pattern="(\d)(\d{7})" nationalPrefixFormattingRule="$NP$FG">
5187           <leadingDigits>5</leadingDigits>
5188           <format>$1 $2</format>
5189         </numberFormat>
5190       </availableFormats>
5191       <generalDesc>
5192         <nationalNumberPattern>[2-57]\d{5,7}</nationalNumberPattern>
5193         <possibleNumberPattern>\d{4,8}</possibleNumberPattern>
5194       </generalDesc>
5195       <fixedLine>
5196         <nationalNumberPattern>
5197           2[1-4]\d{5,6}|
5198           3(?:
5199             1\d{6}|
5200             [23]\d{4,6}
5201           )|
5202           4(?:
5203             [125]\d{5,6}|
5204             [36]\d{6}|
5205             [78]\d{4,6}
5206           )|
5207           7\d{6,7}
5208         </nationalNumberPattern>
5209         <exampleNumber>71234567</exampleNumber>
5210       </fixedLine>
5211       <mobile>
5212         <nationalNumberPattern>5\d{7}</nationalNumberPattern>
5213         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5214         <exampleNumber>51234567</exampleNumber>
5215       </mobile>
5216     </territory>
5217
5218     <!-- Cape Verde -->
5219     <territory id="CV" countryCode="238" internationalPrefix="0">
5220       <references>
5221         <sourceUrl>http://www.itu.int/oth/T0202000026/en</sourceUrl>
5222       </references>
5223       <availableFormats>
5224         <numberFormat pattern="(\d{3})(\d{2})(\d{2})">
5225           <format>$1 $2 $3</format>
5226         </numberFormat>
5227       </availableFormats>
5228       <generalDesc>
5229         <nationalNumberPattern>[259]\d{6}</nationalNumberPattern>
5230         <possibleNumberPattern>\d{7}</possibleNumberPattern>
5231       </generalDesc>
5232       <fixedLine>
5233         <nationalNumberPattern>
5234           2(?:
5235             2[1-7]|
5236             3[0-8]|
5237             4[12]|
5238             5[1256]|
5239             6\d|
5240             7[1-3]|
5241             8[1-5]
5242           )\d{4}
5243         </nationalNumberPattern>
5244         <exampleNumber>2211234</exampleNumber>
5245       </fixedLine>
5246       <mobile>
5247         <!-- It seems, contrary to their numbering plan, the entire 9X range is used for mobile
5248              phones. SMS messages has been successfully sent to numbers starting with 95 and 97 for
5249              example, and there are plenty of numbers on the internet that start with these
5250              prefixes. -->
5251         <nationalNumberPattern>
5252           (?:
5253             9\d|
5254             59
5255           )\d{5}
5256         </nationalNumberPattern>
5257         <exampleNumber>9911234</exampleNumber>
5258       </mobile>
5259     </territory>
5260
5261     <!-- Curaçao -->
5262     <territory id="CW" countryCode="599" internationalPrefix="00" mainCountryForCode="true">
5263       <references>
5264         <sourceUrl>http://www.itu.int/oth/T02020000F5/en</sourceUrl>
5265       </references>
5266       <!-- All the formatting patterns for country-code 599 are here. -->
5267       <availableFormats>
5268         <numberFormat pattern="(\d{3})(\d{4})">
5269           <leadingDigits>[13-7]</leadingDigits>
5270           <format>$1 $2</format>
5271         </numberFormat>
5272         <numberFormat pattern="(9)(\d{3})(\d{4})">
5273           <leadingDigits>9</leadingDigits>
5274           <format>$1 $2 $3</format>
5275         </numberFormat>
5276       </availableFormats>
5277       <generalDesc>
5278         <nationalNumberPattern>[169]\d{6,7}</nationalNumberPattern>
5279         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
5280       </generalDesc>
5281       <fixedLine>
5282         <nationalNumberPattern>
5283           9(?:
5284             [48]\d{2}|
5285             50\d|
5286             7(?:
5287               2[0-24]|
5288               [34]\d|
5289               6[35-7]|
5290               77|
5291               8[7-9]
5292             )
5293           )\d{4}
5294         </nationalNumberPattern>
5295         <exampleNumber>94151234</exampleNumber>
5296       </fixedLine>
5297       <mobile>
5298         <nationalNumberPattern>
5299           9(?:
5300             5(?:
5301               [1246]\d|
5302               3[01]
5303             )|
5304             6(?:
5305               [16-9]\d|
5306               3[01]
5307             )
5308           )\d{4}
5309         </nationalNumberPattern>
5310         <exampleNumber>95181234</exampleNumber>
5311       </mobile>
5312       <pager>
5313         <nationalNumberPattern>955\d{5}</nationalNumberPattern>
5314         <exampleNumber>95581234</exampleNumber>
5315       </pager>
5316       <sharedCost>
5317         <!-- Value-added services are lumped together under shared cost, since we are not sure
5318              exactly what they are. -->
5319         <nationalNumberPattern>
5320           (?:
5321             10|
5322             69
5323           )\d{5}
5324         </nationalNumberPattern>
5325         <possibleNumberPattern>\d{7}</possibleNumberPattern>
5326         <exampleNumber>1011234</exampleNumber>
5327       </sharedCost>
5328     </territory>
5329
5330     <!-- Christmas Islands -->
5331     <!-- Metadata shared with Australia. -->
5332     <!-- References state Christmas Islands have fixed line numbers starting +61 8 9164. -->
5333     <territory id="CX" countryCode="61" preferredInternationalPrefix="0011"
5334                internationalPrefix="(?:14(?:1[14]|34|4[17]|[56]6|7[47]|88))?001[14-689]"
5335                nationalPrefix="0">
5336       <references>
5337         <sourceUrl>http://en.wikipedia.org/wiki/List_of_country_calling_codes</sourceUrl>
5338         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia</sourceUrl>
5339       </references>
5340       <!-- Uses AU formatting rules. -->
5341       <!-- General desc and fixed line rules different from Australia. -->
5342       <generalDesc>
5343         <nationalNumberPattern>[1458]\d{5,9}</nationalNumberPattern>
5344         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
5345       </generalDesc>
5346       <fixedLine>
5347         <nationalNumberPattern>89164\d{4}</nationalNumberPattern>
5348         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
5349         <exampleNumber>891641234</exampleNumber>
5350       </fixedLine>
5351       <!-- Mobile, toll free, premium rate, personal number and VOIP copied from Australia. -->
5352       <mobile>
5353         <nationalNumberPattern>
5354           14(?:
5355             5\d|
5356             71
5357           )\d{5}|
5358           4(?:
5359             [0-2]\d|
5360             3[0-57-9]|
5361             4[47-9]|
5362             5[0-25-9]|
5363             6[6-9]|
5364             7[03-9]|
5365             8[17-9]|
5366             9[017-9]
5367           )\d{6}
5368         </nationalNumberPattern>
5369         <possibleNumberPattern>\d{9}</possibleNumberPattern>
5370         <exampleNumber>412345678</exampleNumber>
5371       </mobile>
5372       <tollFree>
5373         <nationalNumberPattern>
5374           1(?:
5375             80(?:
5376               0\d{2}
5377             )?|
5378             3(?:
5379               00\d{2}
5380             )?
5381           )\d{4}
5382         </nationalNumberPattern>
5383         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
5384         <exampleNumber>1800123456</exampleNumber>
5385       </tollFree>
5386       <premiumRate>
5387         <nationalNumberPattern>190[0126]\d{6}</nationalNumberPattern>
5388         <possibleNumberPattern>\d{10}</possibleNumberPattern>
5389         <exampleNumber>1900123456</exampleNumber>
5390       </premiumRate>
5391       <personalNumber>
5392         <nationalNumberPattern>500\d{6}</nationalNumberPattern>
5393         <possibleNumberPattern>\d{9}</possibleNumberPattern>
5394         <exampleNumber>500123456</exampleNumber>
5395       </personalNumber>
5396       <voip>
5397         <nationalNumberPattern>550\d{6}</nationalNumberPattern>
5398         <possibleNumberPattern>\d{9}</possibleNumberPattern>
5399         <exampleNumber>550123456</exampleNumber>
5400       </voip>
5401     </territory>
5402
5403     <!-- Cyprus -->
5404     <territory id="CY" countryCode="357" internationalPrefix="00" mobileNumberPortableRegion="true">
5405       <references>
5406         <sourceUrl>http://www.itu.int/oth/T0202000034/en</sourceUrl>
5407       </references>
5408       <availableFormats>
5409         <!-- Format from http://www.cyprusyellowpages.com -->
5410         <numberFormat pattern="(\d{2})(\d{6})">
5411           <format>$1 $2</format>
5412         </numberFormat>
5413       </availableFormats>
5414       <generalDesc>
5415         <nationalNumberPattern>[257-9]\d{7}</nationalNumberPattern>
5416         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5417       </generalDesc>
5418       <fixedLine>
5419         <nationalNumberPattern>2[2-6]\d{6}</nationalNumberPattern>
5420         <exampleNumber>22345678</exampleNumber>
5421       </fixedLine>
5422       <mobile>
5423         <!-- Includes paging numbers (they are mixed into the same block). -->
5424         <nationalNumberPattern>9[5-79]\d{6}</nationalNumberPattern>
5425         <exampleNumber>96123456</exampleNumber>
5426       </mobile>
5427       <tollFree>
5428         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
5429         <exampleNumber>80001234</exampleNumber>
5430       </tollFree>
5431       <premiumRate>
5432         <nationalNumberPattern>90[09]\d{5}</nationalNumberPattern>
5433         <exampleNumber>90012345</exampleNumber>
5434       </premiumRate>
5435       <sharedCost>
5436         <nationalNumberPattern>80[1-9]\d{5}</nationalNumberPattern>
5437         <exampleNumber>80112345</exampleNumber>
5438       </sharedCost>
5439       <personalNumber>
5440         <nationalNumberPattern>700\d{5}</nationalNumberPattern>
5441         <exampleNumber>70012345</exampleNumber>
5442       </personalNumber>
5443       <uan>
5444         <!-- Using for Corporate Network numbers and Universal Service numbers. -->
5445         <nationalNumberPattern>
5446           (?:
5447             50|
5448             77
5449           )\d{6}
5450         </nationalNumberPattern>
5451         <exampleNumber>77123456</exampleNumber>
5452       </uan>
5453     </territory>
5454
5455     <!-- Czech Rep. -->
5456     <territory id="CZ" countryCode="420" internationalPrefix="00" mobileNumberPortableRegion="true">
5457       <references>
5458         <sourceUrl>http://www.itu.int/oth/T0202000035/en</sourceUrl>
5459         <sourceUrl>http://en.wikipedia.org/wiki/%2B420</sourceUrl>
5460       </references>
5461       <availableFormats>
5462         <numberFormat pattern="([2-9]\d{2})(\d{3})(\d{3})">
5463           <leadingDigits>
5464             [2-8]|
5465             9[015-7]
5466           </leadingDigits>
5467           <format>$1 $2 $3</format>
5468         </numberFormat>
5469         <numberFormat pattern="(96\d)(\d{3})(\d{3})(\d{3})">
5470           <leadingDigits>96</leadingDigits>
5471           <format>$1 $2 $3 $4</format>
5472         </numberFormat>
5473         <numberFormat pattern="(9\d)(\d{3})(\d{3})(\d{3})">
5474           <leadingDigits>9[36]</leadingDigits>
5475           <format>$1 $2 $3 $4</format>
5476         </numberFormat>
5477       </availableFormats>
5478       <generalDesc>
5479         <nationalNumberPattern>
5480           [2-8]\d{8}|
5481           9\d{8,11}
5482         </nationalNumberPattern>
5483         <possibleNumberPattern>\d{9,12}</possibleNumberPattern>
5484       </generalDesc>
5485       <fixedLine>
5486         <nationalNumberPattern>
5487           2\d{8}|
5488           (?:
5489             3[1257-9]|
5490             4[16-9]|
5491             5[13-9]
5492           )\d{7}
5493         </nationalNumberPattern>
5494         <exampleNumber>212345678</exampleNumber>
5495       </fixedLine>
5496       <mobile>
5497         <nationalNumberPattern>
5498           (?:
5499             60[1-8]|
5500             7(?:
5501               0[2-5]|
5502               [2379]\d
5503             )
5504           )\d{6}
5505         </nationalNumberPattern>
5506         <exampleNumber>601123456</exampleNumber>
5507       </mobile>
5508       <tollFree>
5509         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
5510         <exampleNumber>800123456</exampleNumber>
5511       </tollFree>
5512       <premiumRate>
5513         <!-- Includes premium rate dial-up. -->
5514         <nationalNumberPattern>
5515           9(?:
5516             0[05689]|
5517             76
5518           )\d{6}
5519         </nationalNumberPattern>
5520         <exampleNumber>900123456</exampleNumber>
5521       </premiumRate>
5522       <sharedCost>
5523         <nationalNumberPattern>8[134]\d{7}</nationalNumberPattern>
5524         <exampleNumber>811234567</exampleNumber>
5525       </sharedCost>
5526       <personalNumber>
5527         <nationalNumberPattern>70[01]\d{6}</nationalNumberPattern>
5528         <exampleNumber>700123456</exampleNumber>
5529       </personalNumber>
5530       <voip>
5531         <nationalNumberPattern>9[17]0\d{6}</nationalNumberPattern>
5532         <exampleNumber>910123456</exampleNumber>
5533       </voip>
5534       <uan>
5535         <!-- Numbers belonging to private communication networks are included here. These are
5536              classified as Institutional networks, belonging to institutions like the police, armed
5537              forces and railways, along with a couple of formerly government-owned banks. These
5538              numbers are reachable by the public. -->
5539         <nationalNumberPattern>
5540           9(?:
5541             5\d|
5542             7[234]
5543           )\d{6}
5544         </nationalNumberPattern>
5545         <exampleNumber>972123456</exampleNumber>
5546       </uan>
5547       <voicemail>
5548         <nationalNumberPattern>
5549           9(?:
5550             3\d{9}|
5551             6\d{7,10}
5552           )
5553         </nationalNumberPattern>
5554         <possibleNumberPattern>\d{9,12}</possibleNumberPattern>
5555         <exampleNumber>93123456789</exampleNumber>
5556       </voicemail>
5557     </territory>
5558
5559     <!-- Germany -->
5560     <territory id="DE" countryCode="49" internationalPrefix="00"
5561                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
5562                mobileNumberPortableRegion="true">
5563       <references>
5564         <sourceUrl>http://www.itu.int/oth/T0202000051/en</sourceUrl>
5565         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_germany</sourceUrl>
5566       </references>
5567       <availableFormats>
5568         <!-- Mobile number formatting rules. We follow the ITU document here for guidance on how
5569              these should best be formatted, even though actual usage varies. -->
5570         <numberFormat pattern="(1\d{2})(\d{7,8})">
5571           <leadingDigits>1[67]</leadingDigits>
5572           <format>$1 $2</format>
5573         </numberFormat>
5574         <numberFormat pattern="(1\d{3})(\d{7})">
5575           <leadingDigits>15</leadingDigits>
5576           <format>$1 $2</format>
5577         </numberFormat>
5578         <numberFormat pattern="(\d{2})(\d{3,11})">
5579           <leadingDigits>
5580             3[02]|
5581             40|
5582             [68]9
5583           </leadingDigits>
5584           <format>$1 $2</format>
5585         </numberFormat>
5586         <!-- The order of the rules on 3-5 digits area code matter as fallback is used here. -->
5587         <!-- 3 digit area codes. -->
5588         <numberFormat pattern="(\d{3})(\d{3,11})">
5589           <leadingDigits>
5590             2(?:
5591               \d1|
5592               0[2389]|
5593               1[24]|
5594               28|
5595               34
5596             )|
5597             3(?:
5598               [3-9][15]|
5599               40
5600             )|
5601             [4-8][1-9]1|
5602             9(?:
5603               06|
5604               [1-9]1
5605             )
5606           </leadingDigits>
5607           <format>$1 $2</format>
5608         </numberFormat>
5609         <!-- 4 digit area codes. -->
5610         <numberFormat pattern="(\d{4})(\d{2,11})">
5611           <leadingDigits>
5612             [24-6]|
5613             [7-9](?:
5614               \d[1-9]|
5615               [1-9]\d
5616             )|
5617             3(?:
5618               [3569][02-46-9]|
5619               4[2-4679]|
5620               7[2-467]|
5621               8[2-46-8]
5622             )
5623           </leadingDigits>
5624           <leadingDigits>
5625             [24-6]|
5626             [7-9](?:
5627               \d[1-9]|
5628               [1-9]\d
5629             )|
5630             3(?:
5631               3(?:
5632                 0[1-467]|
5633                 2[127-9]|
5634                 3[124578]|
5635                 [46][1246]|
5636                 7[1257-9]|
5637                 8[1256]|
5638                 9[145]
5639               )|
5640               4(?:
5641                 2[135]|
5642                 3[1357]|
5643                 4[13578]|
5644                 6[1246]|
5645                 7[1356]|
5646                 9[1346]
5647               )|
5648               5(?:
5649                 0[14]|
5650                 2[1-3589]|
5651                 3[1357]|
5652                 4[1246]|
5653                 6[1-4]|
5654                 7[1346]|
5655                 8[13568]|
5656                 9[1246]
5657               )|
5658               6(?:
5659                 0[356]|
5660                 2[1-489]|
5661                 3[124-6]|
5662                 4[1347]|
5663                 6[13]|
5664                 7[12579]|
5665                 8[1-356]|
5666                 9[135]
5667               )|
5668               7(?:
5669                 2[1-7]|
5670                 3[1357]|
5671                 4[145]|
5672                 6[1-5]|
5673                 7[1-4]
5674               )|
5675               8(?:
5676                 21|
5677                 3[1468]|
5678                 4[1347]|
5679                 6[0135-9]|
5680                 7[1467]|
5681                 8[136]
5682               )|
5683               9(?:
5684                 0[12479]|
5685                 2[1358]|
5686                 3[1357]|
5687                 4[134679]|
5688                 6[1-9]|
5689                 7[136]|
5690                 8[147]|
5691                 9[1468]
5692               )
5693             )
5694           </leadingDigits>
5695           <format>$1 $2</format>
5696         </numberFormat>
5697         <!-- 5 digit area codes. -->
5698         <numberFormat pattern="(3\d{4})(\d{1,10})">
5699           <leadingDigits>3</leadingDigits>
5700           <format>$1 $2</format>
5701         </numberFormat>
5702         <!-- Note: this is getting ridiculous! How can we format these better? -->
5703         <numberFormat pattern="(800)(\d{7,12})">
5704           <leadingDigits>800</leadingDigits>
5705           <format>$1 $2</format>
5706         </numberFormat>
5707         <!-- Voicemail access numbers for the carrier Blau. -->
5708         <numberFormat pattern="(177)(99)(\d{7,8})">
5709           <leadingDigits>177</leadingDigits>
5710           <leadingDigits>1779</leadingDigits>
5711           <leadingDigits>17799</leadingDigits>
5712           <format>$1 $2 $3</format>
5713         </numberFormat>
5714         <numberFormat pattern="(\d{3})(\d)(\d{4,10})">
5715           <leadingDigits>
5716             (?:
5717               18|
5718               90
5719             )0|
5720             137
5721           </leadingDigits>
5722           <leadingDigits>
5723             1(?:
5724               37|
5725               80
5726             )|
5727             900[1359]
5728           </leadingDigits>
5729           <format>$1 $2 $3</format>
5730         </numberFormat>
5731         <numberFormat pattern="(1\d{2})(\d{5,11})">
5732           <leadingDigits>181</leadingDigits>
5733           <format>$1 $2</format>
5734         </numberFormat>
5735         <!-- Where we have seen prefixes in use for the IVPN/User Group numbers, we format it the
5736              way it is generally written. For other prefixes, we fall back to using a three-digit
5737              prefix since we have currently no more information to allow us to format these more
5738              precisely. -->
5739         <numberFormat pattern="(18\d{3})(\d{6})">
5740           <leadingDigits>185</leadingDigits>
5741           <leadingDigits>1850</leadingDigits>
5742           <leadingDigits>18500</leadingDigits>
5743           <format>$1 $2</format>
5744         </numberFormat>
5745         <numberFormat pattern="(18\d{2})(\d{7})">
5746           <leadingDigits>18[68]</leadingDigits>
5747           <format>$1 $2</format>
5748         </numberFormat>
5749         <numberFormat pattern="(18\d)(\d{8})">
5750           <leadingDigits>18[2-579]</leadingDigits>
5751           <format>$1 $2</format>
5752         </numberFormat>
5753         <numberFormat pattern="(700)(\d{4})(\d{4})">
5754           <leadingDigits>700</leadingDigits>
5755           <format>$1 $2 $3</format>
5756         </numberFormat>
5757         <numberFormat pattern="(138)(\d{4})">
5758           <leadingDigits>138</leadingDigits>
5759           <format>$1 $2</format>
5760         </numberFormat>
5761       </availableFormats>
5762       <generalDesc>
5763         <!-- When deciding whether to assume a leading 49 is a country code or not, the number is
5764              examined to see if it is valid with the 49 as part of the number. Due to the variable
5765              length of German numbers, this test is hard to do. The national pattern is hence
5766              stricter for numbers starting with 49, to try and remove the country code if the number
5767              begins with 49 whenever possible. -->
5768         <nationalNumberPattern>
5769           [1-35-9]\d{3,14}|
5770           4(?:
5771             [0-8]\d{4,12}|
5772             9(?:
5773               [0-37]\d|
5774               4(?:
5775                 [1-35-8]|
5776                 4\d?
5777               )|
5778               5\d{1,2}|
5779               6[1-8]\d?
5780             )\d{2,8}
5781           )
5782         </nationalNumberPattern>
5783         <possibleNumberPattern>\d{2,15}</possibleNumberPattern>
5784       </generalDesc>
5785       <fixedLine>
5786         <!-- The numbering plan defines rather optimistic longest-number limits - online numbers
5787              don't seem to respect this. The max-length is hence extended. -->
5788         <nationalNumberPattern>
5789           [246]\d{5,13}|
5790           3(?:
5791             0\d{3,13}|
5792             2\d{9}|
5793             [3-9]\d{4,13}
5794           )|
5795           5(?:
5796             0[2-8]|
5797             [1256]\d|
5798             [38][0-8]|
5799             4\d{0,2}|
5800             [79][0-7]
5801           )\d{3,11}|
5802           7(?:
5803             0[2-8]|
5804             [1-9]\d
5805           )\d{3,10}|
5806           8(?:
5807             0[2-9]|
5808             [1-9]\d
5809           )\d{3,10}|
5810           9(?:
5811             0[6-9]\d{3,10}|
5812             1\d{4,12}|
5813             [2-9]\d{4,11}
5814           )
5815         </nationalNumberPattern>
5816         <exampleNumber>30123456</exampleNumber>
5817       </fixedLine>
5818       <mobile>
5819         <!-- According to
5820              http://www.bundesnetzagentur.de/SharedDocs/Downloads/DE/BNetzA/Sachgebiete/Telekommunikation/Regulierung/Nummernverwaltung/Mobilfunkdienste/NummernplanMobileDienstepdf.pdf?__blob=publicationFile
5821              numbers beginning with 162, 163 and 17 can all be 10 or 11 digits long.
5822              The ranges 15[056] have been removed from the ITU doc, but information found online
5823              indicates that they may still be working.
5824              -->
5825         <nationalNumberPattern>
5826           1(?:
5827             5[0-2579]\d{8}|
5828             6[023]\d{7,8}|
5829             7(?:
5830               [0-57-9]\d?|
5831               6\d
5832             )\d{7}
5833           )
5834         </nationalNumberPattern>
5835         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
5836         <exampleNumber>15123456789</exampleNumber>
5837       </mobile>
5838       <pager>
5839         <nationalNumberPattern>
5840           16(?:
5841             4\d{1,10}|
5842             [89]\d{1,11}
5843           )
5844         </nationalNumberPattern>
5845         <possibleNumberPattern>\d{4,14}</possibleNumberPattern>
5846         <exampleNumber>16412345</exampleNumber>
5847       </pager>
5848       <tollFree>
5849         <nationalNumberPattern>800\d{7,12}</nationalNumberPattern>
5850         <possibleNumberPattern>\d{10,15}</possibleNumberPattern>
5851         <exampleNumber>8001234567890</exampleNumber>
5852       </tollFree>
5853       <premiumRate>
5854         <!-- Includes the more expensive of the "televoting" line numbers. See the shared cost
5855              section for more information. -->
5856         <nationalNumberPattern>
5857           137[7-9]\d{6}|
5858           900(?:
5859             [135]\d{6}|
5860             9\d{7}
5861           )
5862         </nationalNumberPattern>
5863         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
5864         <exampleNumber>9001234567</exampleNumber>
5865       </premiumRate>
5866       <sharedCost>
5867         <!-- Includes some mass-traffic numbers, used for e.g. phone voting, raffles, since their
5868              costs when dialling from a fixed-line phone is similar.
5869              Prices:
5870              http://www.billiger-telefonieren.de/0180-0137-0900-sonderrufnummern/
5871              Documentation:
5872              http://www.bundesnetzagentur.de/SharedDocs/Downloads/DE/Sachgebiete/Telekommunikation/Unternehmen_Institutionen/Nummerierung/Rufnummern/0137/0137_Nummernplan.pdf?__blob=publicationFile&v=2
5873         -->
5874         <nationalNumberPattern>
5875           1(?:
5876             3(?:
5877               7[1-6]\d{6}|
5878               8\d{4}
5879             )|
5880             80\d{5,11}
5881           )
5882         </nationalNumberPattern>
5883         <possibleNumberPattern>\d{7,14}</possibleNumberPattern>
5884         <exampleNumber>18012345</exampleNumber>
5885       </sharedCost>
5886       <personalNumber>
5887         <nationalNumberPattern>700\d{8}</nationalNumberPattern>
5888         <possibleNumberPattern>\d{11}</possibleNumberPattern>
5889         <exampleNumber>70012345678</exampleNumber>
5890       </personalNumber>
5891       <uan>
5892         <!-- Using UAN for numbers marked in the plan as being assigned to International Virtual
5893              Private Networks (0181) & User Groups (018[2-9]). These seem in practice to be assigned
5894              to companies. More information here: http://de.wikipedia.org/wiki/Vorwahl_01 -->
5895         <nationalNumberPattern>
5896           18(?:
5897             1\d{5,11}|
5898             [2-9]\d{8}
5899           )
5900         </nationalNumberPattern>
5901         <possibleNumberPattern>\d{8,14}</possibleNumberPattern>
5902         <exampleNumber>18500123456</exampleNumber>
5903       </uan>
5904       <voicemail>
5905         <nationalNumberPattern>17799\d{7,8}</nationalNumberPattern>
5906         <possibleNumberPattern>\d{12,13}</possibleNumberPattern>
5907         <exampleNumber>177991234567</exampleNumber>
5908       </voicemail>
5909     </territory>
5910
5911     <!-- Djibouti -->
5912     <territory id="DJ" countryCode="253" internationalPrefix="00">
5913       <references>
5914         <sourceUrl>http://www.itu.int/oth/T020200003A/en</sourceUrl>
5915       </references>
5916       <availableFormats>
5917         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
5918           <format>$1 $2 $3 $4</format>
5919         </numberFormat>
5920       </availableFormats>
5921       <generalDesc>
5922         <nationalNumberPattern>[27]\d{7}</nationalNumberPattern>
5923         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5924       </generalDesc>
5925       <fixedLine>
5926         <!-- Includes "Numéro long CDMA fixe" numbers. -->
5927         <nationalNumberPattern>
5928           2(?:
5929             1[2-5]|
5930             7[45]
5931           )\d{5}
5932         </nationalNumberPattern>
5933         <exampleNumber>21360003</exampleNumber>
5934       </fixedLine>
5935       <mobile>
5936         <nationalNumberPattern>77[6-8]\d{5}</nationalNumberPattern>
5937         <exampleNumber>77831001</exampleNumber>
5938       </mobile>
5939     </territory>
5940
5941     <!-- Denmark -->
5942     <territory id="DK" countryCode="45" internationalPrefix="00" mobileNumberPortableRegion="true">
5943       <references>
5944         <sourceUrl>http://www.dba.erhvervsstyrelsen.dk/numbering-lists</sourceUrl>
5945       </references>
5946       <availableFormats>
5947         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
5948           <format>$1 $2 $3 $4</format>
5949         </numberFormat>
5950       </availableFormats>
5951       <generalDesc>
5952         <nationalNumberPattern>[2-9]\d{7}</nationalNumberPattern>
5953         <possibleNumberPattern>\d{8}</possibleNumberPattern>
5954       </generalDesc>
5955       <!-- Note that "mainly mobile" and "mainly fixed-line" are put under both number types to be
5956            safe. -->
5957       <fixedLine>
5958         <nationalNumberPattern>
5959           (?:
5960             [2-7]\d|
5961             8[126-9]|
5962             9[1-36-9]
5963           )\d{6}
5964         </nationalNumberPattern>
5965         <exampleNumber>32123456</exampleNumber>
5966       </fixedLine>
5967       <mobile>
5968         <nationalNumberPattern>
5969           (?:
5970             [2-7]\d|
5971             8[126-9]|
5972             9[1-36-9]
5973           )\d{6}
5974         </nationalNumberPattern>
5975         <exampleNumber>20123456</exampleNumber>
5976       </mobile>
5977       <tollFree>
5978         <nationalNumberPattern>80\d{6}</nationalNumberPattern>
5979         <exampleNumber>80123456</exampleNumber>
5980       </tollFree>
5981       <premiumRate>
5982         <nationalNumberPattern>90\d{6}</nationalNumberPattern>
5983         <exampleNumber>90123456</exampleNumber>
5984       </premiumRate>
5985     </territory>
5986
5987     <!-- Dominica -->
5988     <territory id="DM" countryCode="1" leadingDigits="767" nationalPrefix="1"
5989                internationalPrefix="011">
5990       <references>
5991         <sourceUrl>http://www.itu.int/oth/T020200003B/en</sourceUrl>
5992       </references>
5993       <generalDesc>
5994         <!-- NANPA country - uses US formatting rules -->
5995         <nationalNumberPattern>[57-9]\d{9}</nationalNumberPattern>
5996         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
5997       </generalDesc>
5998       <fixedLine>
5999         <nationalNumberPattern>
6000           767(?:
6001             2(?:
6002               55|
6003               66
6004             )|
6005             4(?:
6006               2[01]|
6007               4[0-25-9]
6008             )|
6009             50[0-4]|
6010             70[1-3]
6011           )\d{4}
6012         </nationalNumberPattern>
6013         <exampleNumber>7674201234</exampleNumber>
6014       </fixedLine>
6015       <mobile>
6016         <!-- Adding 61[237], 285 and 295 since online numbers have been found with this prefix. -->
6017         <nationalNumberPattern>
6018           767(?:
6019             2(?:
6020               [234689]5|
6021               7[5-7]
6022             )|
6023             31[5-7]|
6024             61[2-7]
6025           )\d{4}
6026         </nationalNumberPattern>
6027         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6028         <exampleNumber>7672251234</exampleNumber>
6029       </mobile>
6030       <tollFree>
6031         <nationalNumberPattern>
6032           8(?:
6033             00|
6034             44|
6035             55|
6036             66|
6037             77|
6038             88
6039           )[2-9]\d{6}
6040         </nationalNumberPattern>
6041         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6042         <exampleNumber>8002123456</exampleNumber>
6043       </tollFree>
6044       <premiumRate>
6045         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
6046         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6047         <exampleNumber>9002123456</exampleNumber>
6048       </premiumRate>
6049       <personalNumber>
6050         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
6051         <nationalNumberPattern>
6052           5(?:
6053             00|
6054             33|
6055             44|
6056             66|
6057             77
6058           )[2-9]\d{6}
6059         </nationalNumberPattern>
6060         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6061         <exampleNumber>5002345678</exampleNumber>
6062       </personalNumber>
6063     </territory>
6064
6065     <!-- Dominican Rep. -->
6066     <territory id="DO" countryCode="1" leadingDigits="8[024]9" nationalPrefix="1"
6067                internationalPrefix="011" mobileNumberPortableRegion="true">
6068       <references>
6069         <sourceUrl>http://www.itu.int/oth/T020200003C/en</sourceUrl>
6070       </references>
6071       <generalDesc>
6072         <!-- NANPA country - uses US formatting rules -->
6073         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
6074         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
6075       </generalDesc>
6076       <fixedLine>
6077         <!-- The ITU data seems to be somewhat incomplete. We ensure that the fully-specified mobile
6078              prefixes in the document are classified as such by excluding them from the fixed-line
6079              ranges, but other than this have a generic rule. -->
6080         <nationalNumberPattern>
6081           8(?:
6082             [04]9[2-9]\d{6}|
6083             29(?:
6084               2(?:
6085                 [0-59]\d|
6086                 6[04-9]|
6087                 7[0-27]|
6088                 8[0237-9]
6089               )|
6090               3(?:
6091                 [0-35-9]\d|
6092                 4[7-9]
6093               )|
6094               [45]\d{2}|
6095               6(?:
6096                 [0-27-9]\d|
6097                 [3-5][1-9]|
6098                 6[0135-8]
6099               )|
6100               7(?:
6101                 0[013-9]|
6102                 [1-37]\d|
6103                 4[1-35689]|
6104                 5[1-4689]|
6105                 6[1-57-9]|
6106                 8[1-79]|
6107                 9[1-8]
6108               )|
6109               8(?:
6110                 0[146-9]|
6111                 1[0-48]|
6112                 [248]\d|
6113                 3[1-79]|
6114                 5[01589]|
6115                 6[013-68]|
6116                 7[124-8]|
6117                 9[0-8]
6118               )|
6119               9(?:
6120                 [0-24]\d|
6121                 3[02-46-9]|
6122                 5[0-79]|
6123                 60|
6124                 7[0169]|
6125                 8[57-9]|
6126                 9[02-9]
6127               )
6128             )\d{4}
6129           )
6130         </nationalNumberPattern>
6131         <exampleNumber>8092345678</exampleNumber>
6132       </fixedLine>
6133       <mobile>
6134         <nationalNumberPattern>8[024]9[2-9]\d{6}</nationalNumberPattern>
6135         <exampleNumber>8092345678</exampleNumber>
6136       </mobile>
6137       <tollFree>
6138         <nationalNumberPattern>
6139           8(?:
6140             00|
6141             44|
6142             55|
6143             66|
6144             77|
6145             88
6146           )[2-9]\d{6}
6147         </nationalNumberPattern>
6148         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6149         <exampleNumber>8002123456</exampleNumber>
6150       </tollFree>
6151       <premiumRate>
6152         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
6153         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6154         <exampleNumber>9002123456</exampleNumber>
6155       </premiumRate>
6156       <personalNumber>
6157         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
6158         <nationalNumberPattern>
6159           5(?:
6160             00|
6161             33|
6162             44|
6163             66|
6164             77
6165           )[2-9]\d{6}
6166         </nationalNumberPattern>
6167         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6168         <exampleNumber>5002345678</exampleNumber>
6169       </personalNumber>
6170    </territory>
6171
6172     <!-- Algeria -->
6173     <territory id="DZ" countryCode="213" internationalPrefix="00"
6174                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
6175       <references>
6176         <sourceUrl>http://www.itu.int/oth/T0202000003/en</sourceUrl>
6177         <sourceUrl>http://www.arpt.dz</sourceUrl>
6178       </references>
6179       <availableFormats>
6180         <!-- Formatting from http://www.pagesjaunes-dz.com. -->
6181         <numberFormat pattern="([1-4]\d)(\d{2})(\d{2})(\d{2})">
6182           <leadingDigits>[1-4]</leadingDigits>
6183           <format>$1 $2 $3 $4</format>
6184         </numberFormat>
6185         <numberFormat pattern="([5-8]\d{2})(\d{2})(\d{2})(\d{2})">
6186           <leadingDigits>[5-8]</leadingDigits>
6187           <format>$1 $2 $3 $4</format>
6188         </numberFormat>
6189         <numberFormat pattern="(9\d)(\d{3})(\d{2})(\d{2})">
6190           <leadingDigits>9</leadingDigits>
6191           <format>$1 $2 $3 $4</format>
6192         </numberFormat>
6193       </availableFormats>
6194       <generalDesc>
6195         <nationalNumberPattern>
6196           (?:
6197             [1-4]|
6198             [5-9]\d
6199           )\d{7}
6200         </nationalNumberPattern>
6201         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
6202       </generalDesc>
6203       <fixedLine>
6204         <!-- We include the VSAT lines here. -->
6205         <nationalNumberPattern>
6206           (?:
6207             1\d|
6208             2[014-79]|
6209             3[0-8]|
6210             4[0135689]
6211           )\d{6}|
6212           9619\d{5}
6213         </nationalNumberPattern>
6214         <exampleNumber>12345678</exampleNumber>
6215       </fixedLine>
6216       <mobile>
6217         <!-- Adding 65 and 78 from numbers found online. Also, prefix 670 is added since the carrier
6218              Mobilis Algeria provided it, and 54 for Nedjma. Prefixes 67[1-4] were also added for
6219              Mobilis Algeria based on evidence found online. -->
6220         <nationalNumberPattern>
6221           (?:
6222             5[4-6]|
6223             7[7-9]
6224           )\d{7}|
6225           6(?:
6226             [569]\d|
6227             7[0-4]
6228           )\d{6}
6229         </nationalNumberPattern>
6230         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6231         <exampleNumber>551234567</exampleNumber>
6232       </mobile>
6233       <tollFree>
6234         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
6235         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6236         <exampleNumber>800123456</exampleNumber>
6237       </tollFree>
6238       <premiumRate>
6239         <nationalNumberPattern>80[3-689]1\d{5}</nationalNumberPattern>
6240         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6241         <exampleNumber>808123456</exampleNumber>
6242       </premiumRate>
6243       <!-- The Algerian plan doesn't specify where the costs start to be considered "premium", so we
6244            draw an arbitrary line here and say that from 50 Da up they will be considered premium.
6245            -->
6246       <sharedCost>
6247         <nationalNumberPattern>80[12]1\d{5}</nationalNumberPattern>
6248         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6249         <exampleNumber>801123456</exampleNumber>
6250       </sharedCost>
6251       <voip>
6252         <nationalNumberPattern>98[23]\d{6}</nationalNumberPattern>
6253         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6254         <exampleNumber>983123456</exampleNumber>
6255       </voip>
6256    </territory>
6257
6258     <!-- Ecuador -->
6259     <territory id="EC" countryCode="593" internationalPrefix="00"
6260                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
6261                mobileNumberPortableRegion="true">
6262       <references>
6263         <sourceUrl>http://en.wikipedia.org/wiki/+593</sourceUrl>
6264         <sourceUrl>http://www.conatel.gob.ec/site_conatel/index.php?option=com_content&amp;view=category&amp;layout=blog&amp;id=52&amp;Itemid=153</sourceUrl>
6265         <sourceUrl>http://www.itu.int/oth/T020200003D/en</sourceUrl>
6266       </references>
6267       <availableFormats>
6268         <numberFormat pattern="(\d)(\d{3})(\d{4})">
6269           <leadingDigits>
6270             [247]|
6271             [356][2-8]
6272           </leadingDigits>
6273           <format>$1 $2-$3</format>
6274           <intlFormat>$1-$2-$3</intlFormat>
6275         </numberFormat>
6276         <!-- Formatting for the new longer mobile numbers comes from the advertisements about the
6277              change on the http://www.conatel.gob.ec site. -->
6278         <numberFormat pattern="(\d{2})(\d{3})(\d{4})" nationalPrefixFormattingRule="$NP$FG">
6279           <leadingDigits>9</leadingDigits>
6280           <format>$1 $2 $3</format>
6281         </numberFormat>
6282         <numberFormat pattern="(1800)(\d{3})(\d{3,4})" nationalPrefixFormattingRule="$FG">
6283           <leadingDigits>1</leadingDigits>
6284           <format>$1 $2 $3</format>
6285         </numberFormat>
6286       </availableFormats>
6287       <generalDesc>
6288         <nationalNumberPattern>
6289           1\d{9,10}|
6290           [2-8]\d{7}|
6291           9\d{8}
6292         </nationalNumberPattern>
6293         <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
6294       </generalDesc>
6295       <fixedLine>
6296         <nationalNumberPattern>[2-7][2-7]\d{6}</nationalNumberPattern>
6297         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
6298         <exampleNumber>22123456</exampleNumber>
6299       </fixedLine>
6300       <mobile>
6301         <nationalNumberPattern>
6302           9(?:
6303             39|
6304             [45][89]|
6305             [67][7-9]|
6306             [89]\d
6307           )\d{6}
6308         </nationalNumberPattern>
6309         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6310         <exampleNumber>991234567</exampleNumber>
6311       </mobile>
6312       <tollFree>
6313         <nationalNumberPattern>1800\d{6,7}</nationalNumberPattern>
6314         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
6315         <exampleNumber>18001234567</exampleNumber>
6316       </tollFree>
6317       <voip>
6318         <nationalNumberPattern>[2-7]890\d{4}</nationalNumberPattern>
6319         <possibleNumberPattern>\d{8}</possibleNumberPattern>
6320         <exampleNumber>28901234</exampleNumber>
6321       </voip>
6322     </territory>
6323
6324     <!-- Estonia -->
6325     <territory id="EE" countryCode="372" internationalPrefix="00" mobileNumberPortableRegion="true">
6326       <references>
6327         <sourceUrl>http://www.itu.int/oth/T0202000043/en</sourceUrl>
6328         <sourceUrl>http://www.tja.ee/public/Legislation_side/Numbering_/Estonian_NP_eng.htm</sourceUrl>
6329       </references>
6330       <availableFormats>
6331         <numberFormat pattern="([3-79]\d{2})(\d{4})">
6332           <leadingDigits>
6333             [369]|
6334             4[3-8]|
6335             5(?:
6336               [0-2]|
6337               5[0-478]|
6338               6[45]
6339             )|
6340             7[1-9]
6341           </leadingDigits>
6342           <leadingDigits>
6343             [369]|
6344             4[3-8]|
6345             5(?:
6346               [02]|
6347               1(?:
6348                 [0-8]|
6349                 95
6350               )|
6351               5[0-478]|
6352               6(?:
6353                 4[0-4]|
6354                 5[1-589]
6355               )
6356             )|
6357             7[1-9]
6358           </leadingDigits>
6359           <format>$1 $2</format>
6360         </numberFormat>
6361         <numberFormat pattern="(70)(\d{2})(\d{4})">
6362           <leadingDigits>70</leadingDigits>
6363           <format>$1 $2 $3</format>
6364         </numberFormat>
6365         <numberFormat pattern="(8000)(\d{3})(\d{3})">
6366           <leadingDigits>800</leadingDigits>
6367           <leadingDigits>8000</leadingDigits>
6368           <format>$1 $2 $3</format>
6369         </numberFormat>
6370         <numberFormat pattern="([458]\d{3})(\d{3,4})">
6371           <leadingDigits>
6372             40|
6373             5|
6374             8(?:
6375               00|
6376               [1-5]
6377             )
6378           </leadingDigits>
6379           <leadingDigits>
6380             40|
6381             5|
6382             8(?:
6383               00[1-9]|
6384               [1-5]
6385             )
6386           </leadingDigits>
6387           <format>$1 $2</format>
6388         </numberFormat>
6389       </availableFormats>
6390       <generalDesc>
6391         <nationalNumberPattern>
6392           1\d{3,4}|
6393           [3-9]\d{6,7}|
6394           800\d{6,7}
6395         </nationalNumberPattern>
6396         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
6397       </generalDesc>
6398       <noInternationalDialling>
6399         <nationalNumberPattern>
6400           1\d{3,4}|
6401           800[2-9]\d{3}
6402         </nationalNumberPattern>
6403         <possibleNumberPattern>\d{4,7}</possibleNumberPattern>
6404         <exampleNumber>8002123</exampleNumber>
6405       </noInternationalDialling>
6406       <fixedLine>
6407         <nationalNumberPattern>
6408           (?:
6409             3[23589]|
6410             4[3-8]|
6411             6\d|
6412             7[1-9]|
6413             88
6414           )\d{5}
6415         </nationalNumberPattern>
6416         <possibleNumberPattern>\d{7}</possibleNumberPattern>
6417         <exampleNumber>3212345</exampleNumber>
6418       </fixedLine>
6419       <mobile>
6420         <!-- 7 digit mobile numbers currently in use with special prefixes are preserved - new
6421              numbers are 8 digits. -->
6422         <nationalNumberPattern>
6423           (?:
6424             5\d|
6425             8[1-5]
6426           )\d{6}|
6427           5(?:
6428             [02]\d{2}|
6429             1(?:
6430               [0-8]\d|
6431               95
6432             )|
6433             5[0-478]\d|
6434             64[0-4]|
6435             65[1-589]
6436           )\d{3}
6437         </nationalNumberPattern>
6438         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
6439         <exampleNumber>51234567</exampleNumber>
6440       </mobile>
6441       <tollFree>
6442         <nationalNumberPattern>
6443           800(?:
6444             0\d{3}|
6445             1\d|
6446             [2-9]
6447           )\d{3}
6448         </nationalNumberPattern>
6449         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
6450         <exampleNumber>80012345</exampleNumber>
6451       </tollFree>
6452       <premiumRate>
6453         <!-- Supporting eFax numbers here as well. We aren't sure the exact cost, but have
6454              had user reports that they are expensive to dial. -->
6455         <nationalNumberPattern>
6456           (?:
6457             40\d{2}|
6458             900
6459           )\d{4}
6460         </nationalNumberPattern>
6461         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
6462         <exampleNumber>9001234</exampleNumber>
6463       </premiumRate>
6464       <personalNumber>
6465         <nationalNumberPattern>70[0-2]\d{5}</nationalNumberPattern>
6466         <possibleNumberPattern>\d{8}</possibleNumberPattern>
6467         <exampleNumber>70012345</exampleNumber>
6468       </personalNumber>
6469       <uan>
6470         <!-- All 4-5 digit numbers listed in the plan as being a "short number for a service" are
6471              included here. -->
6472         <nationalNumberPattern>
6473           1(?:
6474             2[01245]|
6475             3[0-6]|
6476             4[1-489]|
6477             5[0-59]|
6478             6[1-46-9]|
6479             7[0-27-9]|
6480             8[189]|
6481             9[012]
6482           )\d{1,2}
6483         </nationalNumberPattern>
6484         <possibleNumberPattern>\d{4,5}</possibleNumberPattern>
6485         <exampleNumber>12123</exampleNumber>
6486       </uan>
6487     </territory>
6488
6489     <!-- Egypt -->
6490     <territory id="EG" countryCode="20" internationalPrefix="00"
6491                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
6492                mobileNumberPortableRegion="true">
6493        <references>
6494          <sourceUrl>http://www.itu.int/oth/T020200003E/en</sourceUrl>
6495        </references>
6496        <availableFormats>
6497          <!-- Note that no explicit formatting rule is here for 5-digit numbers starting with a 16
6498               or 19. These are formatted without national prefix, as a block, so do not need to be
6499               listed here. -->
6500          <numberFormat pattern="(\d)(\d{7,8})">
6501            <leadingDigits>[23]</leadingDigits>
6502            <format>$1 $2</format>
6503          </numberFormat>
6504          <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
6505            <leadingDigits>
6506              1[012]|
6507              [89]00
6508            </leadingDigits>
6509            <format>$1 $2 $3</format>
6510          </numberFormat>
6511          <numberFormat pattern="(\d{2})(\d{6,7})">
6512            <leadingDigits>
6513              1[35]|
6514              [4-6]|
6515              [89][2-9]
6516            </leadingDigits>
6517            <format>$1 $2</format>
6518          </numberFormat>
6519        </availableFormats>
6520       <generalDesc>
6521         <nationalNumberPattern>
6522           1\d{4,9}|
6523           [2456]\d{8}|
6524           3\d{7}|
6525           [89]\d{8,9}
6526         </nationalNumberPattern>
6527         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
6528       </generalDesc>
6529       <fixedLine>
6530         <!-- Short numbers used for businesses (starting with 16 or 19) are covered here. Note also
6531              that the plan says numbers starting with 15 should be followed by seven digit
6532              subscriber numbers, but some numbers we have found online are in fact six digit.
6533              Subscriber numbers starting with 5 are also permitted for the area codes 040, with 5, 6
6534              and 7 for the area code 050, with 5 and 7 for 082, with 6 for 084, with 7 for 086 and
6535              092 and with 5 and 6 for 96. -->
6536         <nationalNumberPattern>
6537           (?:
6538             1(?:
6539               3[23]\d|
6540               5(?:
6541                 [23]|
6542                 9\d
6543               )
6544             )|
6545             2[2-4]\d{2}|
6546             3\d{2}|
6547             4(?:
6548               0[2-5]|
6549               [578][23]|
6550               64
6551             )\d|
6552             5(?:
6553               0[2-7]|
6554               [57][23]
6555             )\d|
6556             6[24-689]3\d|
6557             8(?:
6558               2[2-57]|
6559               4[26]|
6560               6[237]|
6561               8[2-4]
6562             )\d|
6563             9(?:
6564               2[27]|
6565               3[24]|
6566               52|
6567               6[2356]|
6568               7[2-4]
6569             )\d
6570           )\d{5}|
6571           1[69]\d{3}
6572         </nationalNumberPattern>
6573         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
6574         <exampleNumber>234567890</exampleNumber>
6575       </fixedLine>
6576       <mobile>
6577         <!-- Adding the extra prefixes 102 and 121 from user reports that Vodafone and Mobinil have
6578              started allocating numbers beginning with these prefixes, along with 115 from numbers
6579              found online. Etisalat is using 110. -->
6580         <nationalNumberPattern>
6581           1(?:
6582             0[0-269]|
6583             1[0-245]|
6584             2[0-278]
6585           )\d{7}
6586         </nationalNumberPattern>
6587         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6588         <exampleNumber>1001234567</exampleNumber>
6589       </mobile>
6590       <tollFree>
6591         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
6592         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6593         <exampleNumber>8001234567</exampleNumber>
6594       </tollFree>
6595       <premiumRate>
6596         <nationalNumberPattern>900\d{7}</nationalNumberPattern>
6597         <possibleNumberPattern>\d{10}</possibleNumberPattern>
6598         <exampleNumber>9001234567</exampleNumber>
6599       </premiumRate>
6600     </territory>
6601
6602     <!-- Western Sahara -->
6603     <!-- Country calling code shared with Morocco (MA). -->
6604     <!-- Two area codes are defined in the Morocco ITU document; 05288 XXXXX and 05289 XXXXX -->
6605     <territory id="EH" countryCode="212" leadingDigits="528[89]" internationalPrefix="00"
6606                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
6607       <references>
6608         <sourceUrl>http://www.itu.int/oth/T0202000090/en</sourceUrl>
6609       </references>
6610       <!-- Uses MA formatting rules and shares general description
6611            (non-geographical numbers for Morocco are still valid). -->
6612       <generalDesc>
6613         <nationalNumberPattern>[5689]\d{8}</nationalNumberPattern>
6614         <!-- Closed numbering plan. -->
6615         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6616       </generalDesc>
6617       <fixedLine>
6618         <nationalNumberPattern>528[89]\d{5}</nationalNumberPattern>
6619         <exampleNumber>528812345</exampleNumber>
6620       </fixedLine>
6621       <!-- The following sections are copied verbatim from Morocco to allow these non-geographical
6622            numbers to be recognized as available from within Western Sahara. -->
6623       <mobile>
6624         <nationalNumberPattern>
6625           6(?:
6626             0[0-8]|
6627             [12-79]\d|
6628             8[01]
6629           )\d{6}
6630         </nationalNumberPattern>
6631         <exampleNumber>650123456</exampleNumber>
6632       </mobile>
6633       <tollFree>
6634         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
6635         <exampleNumber>801234567</exampleNumber>
6636       </tollFree>
6637       <premiumRate>
6638         <nationalNumberPattern>89\d{7}</nationalNumberPattern>
6639         <exampleNumber>891234567</exampleNumber>
6640       </premiumRate>
6641     </territory>
6642
6643     <!-- Eritrea -->
6644     <territory id="ER" countryCode="291" internationalPrefix="00"
6645                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
6646       <references>
6647         <sourceUrl>http://www.itu.int/oth/T0202000042/en</sourceUrl>
6648       </references>
6649       <availableFormats>
6650         <numberFormat pattern="(\d)(\d{3})(\d{3})">
6651           <format>$1 $2 $3</format>
6652         </numberFormat>
6653       </availableFormats>
6654       <generalDesc>
6655         <nationalNumberPattern>[178]\d{6}</nationalNumberPattern>
6656         <possibleNumberPattern>\d{6,7}</possibleNumberPattern>
6657       </generalDesc>
6658       <fixedLine>
6659         <nationalNumberPattern>
6660           1(?:
6661             1[12568]|
6662             20|
6663             40|
6664             55|
6665             6[146]
6666           )\d{4}|
6667           8\d{6}
6668         </nationalNumberPattern>
6669         <exampleNumber>8370362</exampleNumber><!-- Test number from plan. -->
6670       </fixedLine>
6671       <mobile>
6672         <!-- It is unclear in the plan whether the 07 mobile prefix superseded the previous 017[1-3]
6673              numbers or was in addition to them, so we support both here. -->
6674         <nationalNumberPattern>
6675           17[1-3]\d{4}|
6676           7\d{6}
6677         </nationalNumberPattern>
6678         <possibleNumberPattern>\d{7}</possibleNumberPattern>
6679         <exampleNumber>7123456</exampleNumber>
6680       </mobile>
6681     </territory>
6682
6683     <!-- Spain -->
6684     <territory id="ES" countryCode="34" internationalPrefix="00" mobileNumberPortableRegion="true">
6685       <references>
6686         <sourceUrl>http://www.mityc.es/telecomunicaciones/es-ES/Servicios/Numeracion/Paginas/Plan.aspx</sourceUrl>
6687       </references>
6688       <availableFormats>
6689         <numberFormat pattern="([5-9]\d{2})(\d{2})(\d{2})(\d{2})">
6690           <leadingDigits>
6691             [568]|
6692             [79][0-8]
6693           </leadingDigits>
6694           <format>$1 $2 $3 $4</format>
6695         </numberFormat>
6696       </availableFormats>
6697       <generalDesc>
6698         <nationalNumberPattern>[5-9]\d{8}</nationalNumberPattern>
6699         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6700       </generalDesc>
6701       <!-- The pattern is complex because the Lleida Networks mobile ranges are inside the
6702            fixed-line ranges. -->
6703       <fixedLine>
6704         <nationalNumberPattern>
6705           8(?:
6706             [13]0|
6707             [28][0-8]|
6708             [47][1-9]|
6709             5[01346-9]|
6710             6[0457-9]
6711           )\d{6}|
6712           9(?:
6713             [1238][0-8]\d{6}|
6714             4[1-9]\d{6}|
6715             5\d{7}|
6716             6(?:
6717               [0-8]\d{6}|
6718               9(?:
6719                 0(?:
6720                   [0-57-9]\d{4}|
6721                   6(?:
6722                     0[0-8]|
6723                     1[1-9]|
6724                     [2-9]\d
6725                   )\d{2}
6726                 )|
6727                 [1-9]\d{5}
6728               )
6729             )|
6730             7(?:
6731               [124-9]\d{2}|
6732               3(?:
6733                 [0-8]\d|
6734                 9[1-9]
6735               )
6736             )\d{4}
6737           )
6738         </nationalNumberPattern>
6739         <exampleNumber>810123456</exampleNumber>
6740       </fixedLine>
6741       <!-- The ranges 969060900 to 969061099 and 973900000 to 973909999 are mobile according to
6742            information received from Lleida Networks. -->
6743       <mobile>
6744         <nationalNumberPattern>
6745           (?:
6746             6\d{6}|
6747             7[1-4]\d{5}|
6748             9(?:
6749               6906(?:
6750                 09|
6751                 10
6752               )|
6753               7390\d{2}
6754             )
6755           )\d{2}
6756         </nationalNumberPattern>
6757         <exampleNumber>612345678</exampleNumber>
6758       </mobile>
6759       <tollFree>
6760         <nationalNumberPattern>[89]00\d{6}</nationalNumberPattern>
6761         <exampleNumber>800123456</exampleNumber>
6762       </tollFree>
6763       <premiumRate>
6764         <nationalNumberPattern>80[367]\d{6}</nationalNumberPattern>
6765         <exampleNumber>803123456</exampleNumber>
6766       </premiumRate>
6767       <sharedCost>
6768         <nationalNumberPattern>90[12]\d{6}</nationalNumberPattern>
6769         <exampleNumber>901123456</exampleNumber>
6770       </sharedCost>
6771       <personalNumber>
6772         <nationalNumberPattern>70\d{7}</nationalNumberPattern>
6773         <exampleNumber>701234567</exampleNumber>
6774       </personalNumber>
6775       <!-- Modelling non-geographic nomadic numbers as UAN. -->
6776       <uan>
6777         <nationalNumberPattern>51\d{7}</nationalNumberPattern>
6778         <exampleNumber>511234567</exampleNumber>
6779       </uan>
6780     </territory>
6781
6782     <!-- Ethiopia -->
6783     <territory id="ET" countryCode="251" internationalPrefix="00"
6784                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
6785       <references>
6786         <sourceUrl>http://www.itu.int/oth/T0202000044/en</sourceUrl>
6787       </references>
6788       <availableFormats>
6789         <numberFormat pattern="([1-59]\d)(\d{3})(\d{4})">
6790           <format>$1 $2 $3</format>
6791         </numberFormat>
6792       </availableFormats>
6793       <generalDesc>
6794         <nationalNumberPattern>[1-59]\d{8}</nationalNumberPattern>
6795         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
6796       </generalDesc>
6797       <fixedLine>
6798         <nationalNumberPattern>
6799           (?:
6800             11(?:
6801               1(?:
6802                 1[124]|
6803                 2[2-57]|
6804                 3[1-5]|
6805                 5[5-8]|
6806                 8[6-8]
6807               )|
6808               2(?:
6809                 13|
6810                 3[6-8]|
6811                 5[89]|
6812                 7[05-9]|
6813                 8[2-6]
6814               )|
6815               3(?:
6816                 2[01]|
6817                 3[0-289]|
6818                 4[1289]|
6819                 7[1-4]|
6820                 87
6821               )|
6822               4(?:
6823                 1[69]|
6824                 3[2-49]|
6825                 4[0-3]|
6826                 6[5-8]
6827               )|
6828               5(?:
6829                 1[57]|
6830                 44|
6831                 5[0-4]
6832               )|
6833               6(?:
6834                 18|
6835                 2[69]|
6836                 4[5-7]|
6837                 5[1-5]|
6838                 6[0-59]|
6839                 8[015-8]
6840               )
6841             )|
6842             2(?:
6843               2(?:
6844                 11[1-9]|
6845                 22[0-7]|
6846                 33\d|
6847                 44[1467]|
6848                 66[1-68]
6849               )|
6850               5(?:
6851                 11[124-6]|
6852                 33[2-8]|
6853                 44[1467]|
6854                 55[14]|
6855                 66[1-3679]|
6856                 77[124-79]|
6857                 880
6858               )
6859             )|
6860             3(?:
6861               3(?:
6862                 11[0-46-8]|
6863                 22[0-6]|
6864                 33[0134689]|
6865                 44[04]|
6866                 55[0-6]|
6867                 66[01467]
6868               )|
6869               4(?:
6870                 44[0-8]|
6871                 55[0-69]|
6872                 66[0-3]|
6873                 77[1-5]
6874               )
6875             )|
6876             4(?:
6877               6(?:
6878                 22[0-24-7]|
6879                 33[1-5]|
6880                 44[13-69]|
6881                 55[14-689]|
6882                 660|
6883                 88[1-4]
6884               )|
6885               7(?:
6886                 11[1-9]|
6887                 22[1-9]|
6888                 33[13-7]|
6889                 44[13-6]|
6890                 55[1-689]
6891               )
6892             )|
6893             5(?:
6894               7(?:
6895                 227|
6896                 55[05]|
6897                 (?:
6898                   66|
6899                   77
6900                 )[14-8]
6901               )|
6902               8(?:
6903                 11[149]|
6904                 22[013-79]|
6905                 33[0-68]|
6906                 44[013-8]|
6907                 550|
6908                 66[1-5]|
6909                 77\d
6910               )
6911             )
6912           )\d{4}
6913         </nationalNumberPattern>
6914         <exampleNumber>111112345</exampleNumber>
6915       </fixedLine>
6916       <mobile>
6917         <!-- The data here is not regularly updated by the Ethiopian authorities, and many more
6918              numbers are visible online than are reported in the ITU document. This pattern is
6919              therefore somewhat more relaxed than in the ITU document. According to the ETC, the
6920              prefix 93 is assigned to Addis Ababa Mobile and 95[89] to some CDMA providers. -->
6921         <nationalNumberPattern>
6922           9(?:
6923             [1-3]\d|
6924             5[89]
6925           )\d{6}
6926         </nationalNumberPattern>
6927         <possibleNumberPattern>\d{9}</possibleNumberPattern>
6928         <exampleNumber>911234567</exampleNumber>
6929       </mobile>
6930     </territory>
6931
6932     <!-- Finland -->
6933     <!-- Metadata shared with Ã…land (AX) -->
6934     <territory id="FI" countryCode="358" internationalPrefix="00|99[049]" nationalPrefix="0"
6935                nationalPrefixFormattingRule="$NP$FG" mainCountryForCode="true"
6936                mobileNumberPortableRegion="true">
6937       <references>
6938         <sourceUrl>https://www.viestintavirasto.fi/internetpuhelin/puhelinverkonnumerointi.html</sourceUrl>
6939       </references>
6940       <availableFormats>
6941         <numberFormat pattern="(\d{3})(\d{3,7})">
6942           <leadingDigits>
6943             (?:
6944               [1-3]00|
6945               [6-8]0
6946             )
6947           </leadingDigits>
6948           <format>$1 $2</format>
6949         </numberFormat>
6950         <numberFormat pattern="(\d{2})(\d{4,10})">
6951           <leadingDigits>
6952             [14]|
6953             2[09]|
6954             50|
6955             7[135]
6956           </leadingDigits>
6957           <format>$1 $2</format>
6958         </numberFormat>
6959         <numberFormat pattern="(\d)(\d{4,11})">
6960           <leadingDigits>
6961             [25689][1-8]|
6962             3
6963           </leadingDigits>
6964           <format>$1 $2</format>
6965         </numberFormat>
6966       </availableFormats>
6967       <generalDesc>
6968         <nationalNumberPattern>
6969           1\d{4,11}|
6970           [2-9]\d{4,10}
6971         </nationalNumberPattern>
6972         <possibleNumberPattern>\d{5,12}</possibleNumberPattern>
6973       </generalDesc>
6974       <noInternationalDialling>
6975         <!-- According to the national numbering plan, service numbers are in general not accessible
6976              from abroad, although 600/700/800 numbers may be. -->
6977         <nationalNumberPattern>
6978           [13]00\d{3,7}|
6979           2(?:
6980             0(?:
6981               0\d{3,7}|
6982               2[023]\d{1,6}|
6983               9[89]\d{1,6}
6984             )
6985           )|
6986           60(?:
6987             [12]\d{5,6}|
6988             6\d{7}
6989           )|
6990           7(?:
6991             1\d{7}|
6992             3\d{8}|
6993             5[03-9]\d{2,7}
6994           )
6995         </nationalNumberPattern>
6996         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
6997         <exampleNumber>100123</exampleNumber>
6998       </noInternationalDialling>
6999       <fixedLine>
7000         <!-- This is limited to geographic numbers - non-geographic nationwide subscriber numbers
7001              are listed under UAN. It also excludes Ã…land numbers. -->
7002         <nationalNumberPattern>
7003           1(?:
7004             [3569][1-8]\d{3,9}|
7005             [47]\d{5,10}
7006           )|
7007           2[1-8]\d{3,9}|
7008           3(?:
7009             [1-8]\d{3,9}|
7010             9\d{4,8}
7011           )|
7012           [5689][1-8]\d{3,9}
7013         </nationalNumberPattern>
7014         <exampleNumber>1312345678</exampleNumber>
7015       </fixedLine>
7016       <mobile>
7017         <nationalNumberPattern>
7018           4\d{5,10}|
7019           50\d{4,8}
7020         </nationalNumberPattern>
7021         <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
7022         <exampleNumber>412345678</exampleNumber>
7023       </mobile>
7024       <tollFree>
7025         <nationalNumberPattern>800\d{4,7}</nationalNumberPattern>
7026         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
7027         <exampleNumber>8001234567</exampleNumber>
7028       </tollFree>
7029       <premiumRate>
7030         <nationalNumberPattern>[67]00\d{5,6}</nationalNumberPattern>
7031         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
7032         <exampleNumber>600123456</exampleNumber>
7033       </premiumRate>
7034       <uan>
7035         <!-- Covers nationwide non-geographic numbers, and nationwide "service numbers", typically
7036              assigned to institutions such as universities, the national post, etc, where they are
7037              not otherwise classified as toll-free or premium-rate numbers. -->
7038         <nationalNumberPattern>
7039           [13]0\d{4,8}|
7040           2(?:
7041             0(?:
7042               [016-8]\d{3,7}|
7043               [2-59]\d{2,7}
7044             )|
7045             9\d{4,8}
7046           )|
7047           60(?:
7048             [12]\d{5,6}|
7049             6\d{7}
7050           )|
7051           7(?:
7052             1\d{7}|
7053             3\d{8}|
7054             5[03-9]\d{2,7}
7055           )
7056         </nationalNumberPattern>
7057         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
7058         <exampleNumber>10112345</exampleNumber>
7059       </uan>
7060     </territory>
7061
7062     <!-- Fiji -->
7063     <territory id="FJ" countryCode="679" internationalPrefix="0(?:0|52)"
7064                preferredInternationalPrefix="00" leadingZeroPossible="true">
7065       <references>
7066         <sourceUrl>http://www.itu.int/oth/T0202000048/en</sourceUrl>
7067         <sourceUrl>http://www.tfl.com.fj</sourceUrl>
7068       </references>
7069       <availableFormats>
7070         <numberFormat pattern="(\d{3})(\d{4})">
7071           <leadingDigits>[36-9]</leadingDigits>
7072           <format>$1 $2</format>
7073         </numberFormat>
7074         <numberFormat pattern="(\d{4})(\d{3})(\d{4})">
7075           <leadingDigits>0</leadingDigits>
7076           <format>$1 $2 $3</format>
7077         </numberFormat>
7078       </availableFormats>
7079       <generalDesc>
7080         <nationalNumberPattern>
7081           [36-9]\d{6}|
7082           0\d{10}
7083         </nationalNumberPattern>
7084         <possibleNumberPattern>\d{7}(?:\d{4})?</possibleNumberPattern>
7085       </generalDesc>
7086       <fixedLine>
7087         <!-- Adding the prefixes 30X, 31X and 62X, since numbers with these prefixes have been found
7088              online, including in the white pages. 35X and 85X were found in the exchanges listed on
7089              http://www.tfl.com.fj. -->
7090         <nationalNumberPattern>
7091           (?:
7092             3[0-5]|
7093             6[25-7]|
7094             8[58]
7095           )\d{5}
7096         </nationalNumberPattern>
7097         <possibleNumberPattern>\d{7}</possibleNumberPattern>
7098         <exampleNumber>3212345</exampleNumber>
7099       </fixedLine>
7100       <mobile>
7101         <!-- Adding 7[5-8], 8[03679], and 9[034678] from numbers found online and numbers where SMSs
7102              have been received from. Adding 9[15] and 84 from Vodafone Fiji IR21. -->
7103         <nationalNumberPattern>
7104           (?:
7105             7[0-8]|
7106             8[034679]|
7107             9\d
7108           )\d{5}
7109         </nationalNumberPattern>
7110         <possibleNumberPattern>\d{7}</possibleNumberPattern>
7111         <exampleNumber>7012345</exampleNumber>
7112       </mobile>
7113       <tollFree>
7114         <!-- Information found on http://www.tfl.com.fj. It is not clear if these are
7115              internationally diallable, or if so, how. -->
7116         <nationalNumberPattern>0800\d{7}</nationalNumberPattern>
7117         <possibleNumberPattern>\d{11}</possibleNumberPattern>
7118         <exampleNumber>08001234567</exampleNumber>
7119       </tollFree>
7120     </territory>
7121
7122     <!-- Falkland Islands (Malvinas) -->
7123     <territory id="FK" countryCode="500" internationalPrefix="00">
7124       <references>
7125         <sourceUrl>http://www.itu.int/oth/T0202000046/en</sourceUrl>
7126       </references>
7127       <!-- All numbers are formatted together, as a block. -->
7128       <generalDesc>
7129         <nationalNumberPattern>[2-7]\d{4}</nationalNumberPattern>
7130         <possibleNumberPattern>\d{5}</possibleNumberPattern>
7131       </generalDesc>
7132       <fixedLine>
7133         <nationalNumberPattern>[2-47]\d{4}</nationalNumberPattern>
7134         <exampleNumber>31234</exampleNumber>
7135       </fixedLine>
7136       <mobile>
7137         <nationalNumberPattern>[56]\d{4}</nationalNumberPattern>
7138         <exampleNumber>51234</exampleNumber>
7139       </mobile>
7140     </territory>
7141
7142     <!-- Micronesia, Federated States of -->
7143     <territory id="FM" countryCode="691" internationalPrefix="00">
7144       <references>
7145         <sourceUrl>http://www.itu.int/oth/T020200008B/en</sourceUrl>
7146       </references>
7147       <availableFormats>
7148         <numberFormat pattern="(\d{3})(\d{4})">
7149           <format>$1 $2</format>
7150         </numberFormat>
7151       </availableFormats>
7152       <generalDesc>
7153         <nationalNumberPattern>[39]\d{6}</nationalNumberPattern>
7154         <possibleNumberPattern>\d{7}</possibleNumberPattern>
7155       </generalDesc>
7156       <fixedLine>
7157         <nationalNumberPattern>
7158             3[2357]0[1-9]\d{3}|
7159             9[2-6]\d{5}
7160         </nationalNumberPattern>
7161         <exampleNumber>3201234</exampleNumber>
7162       </fixedLine>
7163       <mobile>
7164         <!-- Note that most ranges are used for both fixed and mobile but numbers starting with 970
7165              are exclusively mobile. -->
7166         <nationalNumberPattern>
7167           3[2357]0[1-9]\d{3}|
7168           9[2-7]\d{5}
7169         </nationalNumberPattern>
7170         <exampleNumber>3501234</exampleNumber>
7171       </mobile>
7172     </territory>
7173
7174     <!-- Faroe Islands -->
7175     <territory id="FO" countryCode="298" internationalPrefix="00"
7176                nationalPrefixForParsing="(10(?:01|[12]0|88))"
7177                carrierCodeFormattingRule="$CC $FG">
7178       <references>
7179         <sourceUrl>http://www.itu.int/oth/T0202000047/en</sourceUrl>
7180       </references>
7181       <!-- All numbers are formatted together, as a block. -->
7182       <availableFormats>
7183         <numberFormat pattern="(\d{6})">
7184           <format>$1</format>
7185         </numberFormat>
7186       </availableFormats>
7187       <generalDesc>
7188         <nationalNumberPattern>[2-9]\d{5}</nationalNumberPattern>
7189         <possibleNumberPattern>\d{6}</possibleNumberPattern>
7190       </generalDesc>
7191       <fixedLine>
7192         <nationalNumberPattern>
7193           (?:
7194             20|
7195             [3-4]\d|
7196             8[19]
7197           )\d{4}
7198         </nationalNumberPattern>
7199         <exampleNumber>201234</exampleNumber>
7200       </fixedLine>
7201       <mobile>
7202         <nationalNumberPattern>
7203           (?:
7204             2[1-9]|
7205             5\d|
7206             7[1-79]
7207           )\d{4}
7208         </nationalNumberPattern>
7209         <exampleNumber>211234</exampleNumber>
7210       </mobile>
7211       <tollFree>
7212         <nationalNumberPattern>80[257-9]\d{3}</nationalNumberPattern>
7213         <exampleNumber>802123</exampleNumber>
7214       </tollFree>
7215       <premiumRate>
7216         <nationalNumberPattern>
7217           90(?:
7218             [1345][15-7]|
7219             2[125-7]|
7220             99
7221             )\d{2}
7222         </nationalNumberPattern>
7223         <exampleNumber>901123</exampleNumber>
7224       </premiumRate>
7225       <voip>
7226         <nationalNumberPattern>
7227           (?:
7228             6[0-36]|
7229             88
7230           )\d{4}
7231         </nationalNumberPattern>
7232         <exampleNumber>601234</exampleNumber>
7233       </voip>
7234     </territory>
7235
7236     <!-- France -->
7237     <territory id="FR" countryCode="33" internationalPrefix="00" nationalPrefix="0"
7238                nationalPrefixFormattingRule="$NP$FG" mobileNumberPortableRegion="true">
7239       <references>
7240         <sourceUrl>http://www.itu.int/oth/T020200004A/en</sourceUrl>
7241         <sourceUrl>http://www.arcep.fr/index.php?id=8146</sourceUrl>
7242         <sourceUrl>http://en.wikipedia.org/wiki/%2B33</sourceUrl>
7243       </references>
7244       <!-- Short numbers will be formatted as a block without a national prefix. -->
7245       <availableFormats>
7246         <numberFormat pattern="([1-79])(\d{2})(\d{2})(\d{2})(\d{2})">
7247           <leadingDigits>[1-79]</leadingDigits>
7248           <format>$1 $2 $3 $4 $5</format>
7249         </numberFormat>
7250         <numberFormat pattern="(1\d{2})(\d{3})" nationalPrefixFormattingRule="$FG">
7251           <leadingDigits>11</leadingDigits>
7252           <format>$1 $2</format>
7253           <intlFormat>NA</intlFormat>
7254         </numberFormat>
7255         <numberFormat nationalPrefixFormattingRule="$NP $FG"
7256           pattern="(8\d{2})(\d{2})(\d{2})(\d{2})">
7257           <leadingDigits>8</leadingDigits>
7258           <format>$1 $2 $3 $4</format>
7259         </numberFormat>
7260       </availableFormats>
7261       <generalDesc>
7262         <nationalNumberPattern>[1-9]\d{8}</nationalNumberPattern>
7263         <possibleNumberPattern>\d{9}</possibleNumberPattern>
7264       </generalDesc>
7265       <fixedLine>
7266         <nationalNumberPattern>[1-5]\d{8}</nationalNumberPattern>
7267         <exampleNumber>123456789</exampleNumber>
7268       </fixedLine>
7269       <mobile>
7270         <nationalNumberPattern>
7271           6\d{8}|
7272           7[5-9]\d{7}
7273         </nationalNumberPattern>
7274         <exampleNumber>612345678</exampleNumber>
7275       </mobile>
7276       <tollFree>
7277         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
7278         <exampleNumber>801234567</exampleNumber>
7279       </tollFree>
7280       <premiumRate>
7281         <nationalNumberPattern>89[1-37-9]\d{6}</nationalNumberPattern>
7282         <exampleNumber>891123456</exampleNumber>
7283       </premiumRate>
7284       <sharedCost>
7285         <nationalNumberPattern>
7286           8(?:
7287             1[019]|
7288             2[0156]|
7289             84|
7290             90
7291           )\d{6}
7292         </nationalNumberPattern>
7293         <exampleNumber>810123456</exampleNumber>
7294       </sharedCost>
7295       <voip>
7296         <!-- 087 numbers used to be used for this. -->
7297         <nationalNumberPattern>9\d{8}</nationalNumberPattern>
7298         <exampleNumber>912345678</exampleNumber>
7299       </voip>
7300     </territory>
7301
7302     <!-- Gabon -->
7303     <!-- Note: We cannot set nationalPrefix="0" while fixed line numbers can start with a zero
7304          as this breaks parsing (it treats all leading zeros as national prefixes. -->
7305     <territory id="GA" countryCode="241" internationalPrefix="00" leadingZeroPossible="true" >
7306       <references>
7307         <sourceUrl>http://www.itu.int/oth/T020200004E/en</sourceUrl>
7308         <sourceUrl>http://www.arcep.ga</sourceUrl>
7309       </references>
7310       <availableFormats>
7311         <!-- If no leading zero was supplied, format with the national prefix. -->
7312         <numberFormat pattern="(\d)(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="0$FG">
7313           <leadingDigits>[2-7]</leadingDigits>
7314           <format>$1 $2 $3 $4</format>
7315         </numberFormat>
7316         <!-- This already has a leading zero so we format is "as is". -->
7317         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
7318           <leadingDigits>0</leadingDigits>
7319          <format>$1 $2 $3 $4</format>
7320         </numberFormat>
7321       </availableFormats>
7322       <generalDesc>
7323         <nationalNumberPattern>0?\d{7}</nationalNumberPattern>
7324         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
7325       </generalDesc>
7326       <!-- A 7-digit fixed-line plan was scheduled to be implemented on June 17, 2012 to unify fixed
7327            line and mobile numbering. However, this has only partially happened; mobile numbers can
7328            now be dialed without a leading zero, but fixed line numbers still require it. Their own
7329            website still lists fixed line numbers as "+241 01 44 68 11" and upon ringing they will
7330            not connect from outside the country without the 0. This was last tested March 2014. -->
7331       <fixedLine>
7332         <nationalNumberPattern>01\d{6}</nationalNumberPattern>
7333         <possibleNumberPattern>\d{8}</possibleNumberPattern>
7334         <exampleNumber>01441234</exampleNumber>
7335       </fixedLine>
7336       <mobile>
7337         <!-- Mobile numbers can be 7 or 8 digits (with or without a leading zero). -->
7338         <nationalNumberPattern>0?[2-7]\d{6}</nationalNumberPattern>
7339         <exampleNumber>06031234</exampleNumber>
7340       </mobile>
7341     </territory>
7342
7343     <!-- United Kingdom -->
7344     <!-- Note that this excludes Isle of Man, Jersey and Guernsey prefixes for the purposes of
7345          validation, although the formatting rules are shared. -->
7346     <territory id="GB" countryCode="44" internationalPrefix="00"
7347                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG"
7348                mainCountryForCode="true" mobileNumberPortableRegion="true">
7349       <references>
7350         <sourceUrl>http://stakeholders.ofcom.org.uk/telecoms/numbering/</sourceUrl>
7351         <sourceUrl>http://en.wikipedia.org/wiki/List_of_United_Kingdom_dialling_codes</sourceUrl>
7352         <sourceUrl>http://www.numberingplans.com/?page=dialling&amp;sub=areacodes&amp;ac=GB</sourceUrl>
7353       </references>
7354       <availableFormats>
7355         <!-- 2d, 55, 56, 70 and 76 pager numbers (excludes 7624) with 10 digits. -->
7356         <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
7357           <leadingDigits>
7358             2|
7359             5[56]|
7360             7(?:
7361               0|
7362               6[013-9]
7363             )
7364           </leadingDigits>
7365           <leadingDigits>
7366             2|
7367             5[56]|
7368             7(?:
7369               0|
7370               6(?:
7371                 [013-9]|
7372                 2[0-35-9]
7373               )
7374             )
7375           </leadingDigits>
7376           <format>$1 $2 $3</format>
7377         </numberFormat>
7378         <!-- 11d, 1d1, 3dd, 9dd with 10 digits. -->
7379         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
7380           <leadingDigits>
7381             1(?:
7382               1|
7383               \d1
7384             )|
7385             3|
7386             9[018]
7387           </leadingDigits>
7388           <format>$1 $2 $3</format>
7389         </numberFormat>
7390         <!-- 1dddd with 9 or 10 digits.
7391              These area codes are very rare in GB, and are only available in the following places:
7392              13873(Langholm), 15242(Hornby), 15394(Hawkshead), 15395(Grange-over-Sands),
7393              15396(Sedbergh), 16973(Wigton), 16974(Raughton Head), 16977(Brampton),
7394              17683(Appleby), 17684(Pooley Bridge), 17687(Keswick), 19467(Gosforth). -->
7395         <numberFormat pattern="(\d{5})(\d{4,5})">
7396           <leadingDigits>
7397             1(?:
7398               38|
7399               5[23]|
7400               69|
7401               76|
7402               94
7403             )
7404           </leadingDigits>
7405           <leadingDigits>
7406             1(?:
7407               387|
7408               5(?:
7409                 24|
7410                 39
7411               )|
7412               697|
7413               768|
7414               946
7415             )
7416           </leadingDigits>
7417           <leadingDigits>
7418             1(?:
7419               3873|
7420               5(?:
7421                 242|
7422                 39[456]
7423               )|
7424               697[347]|
7425               768[347]|
7426               9467
7427             )
7428           </leadingDigits>
7429           <format>$1 $2</format>
7430         </numberFormat>
7431         <!-- 1ddd with 9 or 10 digits. -->
7432         <numberFormat pattern="(1\d{3})(\d{5,6})">
7433           <leadingDigits>1</leadingDigits>
7434           <format>$1 $2</format>
7435         </numberFormat>
7436         <!-- 7ddd (not 70, 76) with 10 digits. Note: DOES include 7624 when used for IM. -->
7437         <numberFormat pattern="(7\d{3})(\d{6})">
7438           <leadingDigits>
7439             7(?:
7440               [1-5789]|
7441               62
7442             )
7443           </leadingDigits>
7444           <leadingDigits>
7445             7(?:
7446               [1-5789]|
7447               624
7448             )
7449           </leadingDigits>
7450           <format>$1 $2</format>
7451         </numberFormat>
7452         <!-- 800 1111 : UK ChildLine. -->
7453         <numberFormat pattern="(800)(\d{4})">
7454           <leadingDigits>800</leadingDigits>
7455           <leadingDigits>8001</leadingDigits>
7456           <leadingDigits>80011</leadingDigits>
7457           <leadingDigits>800111</leadingDigits>
7458           <leadingDigits>8001111</leadingDigits>
7459           <format>$1 $2</format>
7460         </numberFormat>
7461         <!-- 845 46 47 : UK NHS Direct. -->
7462         <numberFormat pattern="(845)(46)(4\d)">
7463           <leadingDigits>845</leadingDigits>
7464           <leadingDigits>8454</leadingDigits>
7465           <leadingDigits>84546</leadingDigits>
7466           <leadingDigits>845464</leadingDigits>
7467           <format>$1 $2 $3</format>
7468         </numberFormat>
7469         <!-- 84d, 87d with 10 digits. -->
7470         <numberFormat pattern="(8\d{2})(\d{3})(\d{4})">
7471           <leadingDigits>
7472             8(?:
7473               4[2-5]|
7474               7[0-3]
7475             )
7476           </leadingDigits>
7477           <format>$1 $2 $3</format>
7478         </numberFormat>
7479         <!-- 80d (including 800) with 10 digits. -->
7480         <numberFormat pattern="(80\d)(\d{3})(\d{4})">
7481           <leadingDigits>80</leadingDigits>
7482           <format>$1 $2 $3</format>
7483         </numberFormat>
7484         <!-- 500, 800 with 9 digits. -->
7485         <numberFormat pattern="([58]00)(\d{6})">
7486           <leadingDigits>[58]00</leadingDigits>
7487           <format>$1 $2</format>
7488         </numberFormat>
7489       </availableFormats>
7490       <generalDesc>
7491         <nationalNumberPattern>\d{7,10}</nationalNumberPattern>
7492         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
7493       </generalDesc>
7494       <areaCodeOptional>
7495         <!-- These are a subset of the fixed-line rules, with digits 2-9 as the leading digit of the
7496              subscriber number. There are patterns for 2+8, 3+7 and a combined pattern for all
7497              4+6/4+5 and 5+5/5+4 numbers. Note that numbers matching this pattern are not
7498              necessarily valid numbers. -->
7499         <nationalNumberPattern>
7500           2\d[2-9]\d{7}|
7501           1(?:
7502             1\d|
7503             \d1
7504           )[2-9]\d{6}|
7505           1(?:
7506             [248][02-9]\d[2-9]\d{4,5}|
7507             (?:
7508               3(?:
7509                 [02-79]\d|
7510                 8[0-69]
7511               )|
7512               5(?:
7513                 [04-9]\d|
7514                 2[0-35-9]|
7515                 3[0-8]
7516               )|
7517               6(?:
7518                 [02-8]\d|
7519                 9[0-689]
7520               )|
7521               7(?:
7522                 [02-5789]\d|
7523                 6[0-79]
7524               )|
7525               9(?:
7526                 [0235-9]\d|
7527                 4[0-5789]
7528               )
7529             )[2-9]\d{4,5}|
7530             (?:
7531               387(?:
7532                 3[2-9]|
7533                 [24-9]\d
7534               )|
7535               5(?:
7536                 24(?:
7537                   2[2-9]|
7538                   [3-9]\d
7539                 )|
7540                 39(?:
7541                   [4-6][2-9]|
7542                   [237-9]\d
7543                 )
7544               )|
7545               697(?:
7546                 [347][2-9]|
7547                 [25689]\d
7548               )|
7549               768(?:
7550                 [347][2-9]|
7551                 [25679]\d
7552               )|
7553               946(?:
7554                 7[2-9]|
7555                 [2-689]\d
7556               )
7557             )\d{3,4}
7558           )
7559         </nationalNumberPattern>
7560         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
7561         <exampleNumber>1332456789</exampleNumber>
7562       </areaCodeOptional>
7563       <fixedLine>
7564         <!-- http://en.wikipedia.org/wiki/List_of_United_Kingdom_dialling_codes -->
7565         <!-- Pattern matches geographic NSN=10 numbers as follows:
7566              - area code and local number first digit for 2+8,
7567              - area code and local number first digit for 3+7,
7568              - area code only for 4+6 (including areas with embedded 5+5).
7569              Pattern matches geographic NSN=9 numbers as follows:
7570              - area code and local number first two digits for 4+5,
7571              - area code and local number first three digits for 4+5 special case (01768) 88Ddd,
7572              - area code and local number first digit for 5+4 special case (016977) Dddd.
7573              All patterns exclude ranges used in GG, IM, JE. -->
7574         <nationalNumberPattern>
7575           2(?:
7576             0[01378]|
7577             3[0189]|
7578             4[017]|
7579             8[0-46-9]|
7580             9[012]
7581           )\d{7}|
7582           1(?:
7583             (?:
7584               1(?:
7585                 3[0-48]|
7586                 [46][0-4]|
7587                 5[012789]|
7588                 7[0-49]|
7589                 8[01349]
7590               )|
7591               21[0-7]|
7592               31[0-8]|
7593               [459]1\d|
7594               61[0-46-9]
7595             )
7596           )\d{6}|
7597           1(?:
7598             2(?:
7599               0[024-9]|
7600               2[3-9]|
7601               3[3-79]|
7602               4[1-689]|
7603               [58][02-9]|
7604               6[0-4789]|
7605               7[013-9]|
7606               9\d
7607             )|
7608             3(?:
7609               0\d|
7610               [25][02-9]|
7611               3[02-579]|
7612               [468][0-46-9]|
7613               7[1235679]|
7614               9[24578]
7615             )|
7616             4(?:
7617               0[03-9]|
7618               [28][02-5789]|
7619               [37]\d|
7620               4[02-69]|
7621               5[0-8]|
7622               [69][0-79]
7623             )|
7624             5(?:
7625               0[1235-9]|
7626               2[024-9]|
7627               3[015689]|
7628               4[02-9]|
7629               5[03-9]|
7630               6\d|
7631               7[0-35-9]|
7632               8[0-468]|
7633               9[0-5789]
7634             )|
7635             6(?:
7636               0[034689]|
7637               2[0-35689]|
7638               [38][013-9]|
7639               4[1-467]|
7640               5[0-69]|
7641               6[13-9]|
7642               7[0-8]|
7643               9[0124578]
7644             )|
7645             7(?:
7646               0[0246-9]|
7647               2\d|
7648               3[023678]|
7649               4[03-9]|
7650               5[0-46-9]|
7651               6[013-9]|
7652               7[0-35-9]|
7653               8[024-9]|
7654               9[02-9]
7655             )|
7656             8(?:
7657               0[35-9]|
7658               2[1-5789]|
7659               3[02-578]|
7660               4[0-578]|
7661               5[124-9]|
7662               6[2-69]|
7663               7\d|
7664               8[02-9]|
7665               9[02569]
7666             )|
7667             9(?:
7668               0[02-589]|
7669               2[02-689]|
7670               3[1-5789]|
7671               4[2-9]|
7672               5[0-579]|
7673               6[234789]|
7674               7[0124578]|
7675               8\d|
7676               9[2-57]
7677             )
7678           )\d{6}|
7679           1(?:
7680             2(?:
7681               0(?:
7682                 46[1-4]|
7683                 87[2-9]
7684               )|
7685               545[1-79]|
7686               76(?:
7687                 2\d|
7688                 3[1-8]|
7689                 6[1-6]
7690               )|
7691               9(?:
7692                 7(?:
7693                   2[0-4]|
7694                   3[2-5]
7695                 )|
7696                 8(?:
7697                   2[2-8]|
7698                   7[0-4789]|
7699                   8[345]
7700                 )
7701               )
7702             )|
7703             3(?:
7704               638[2-5]|
7705               647[23]|
7706               8(?:
7707                 47[04-9]|
7708                 64[015789]
7709               )
7710             )|
7711             4(?:
7712               044[1-7]|
7713               20(?:
7714                 2[23]|
7715                 8\d
7716               )|
7717               6(?:
7718                 0(?:
7719                   30|
7720                   5[2-57]|
7721                   6[1-8]|
7722                   7[2-8]
7723                 )|
7724                 140
7725               )|
7726               8(?:
7727                 052|
7728                 87[123]
7729               )
7730             )|
7731             5(?:
7732               24(?:
7733                 3[2-79]|
7734                 6\d
7735               )|
7736               276\d|
7737               6(?:
7738                 26[06-9]|
7739                 686
7740               )
7741             )|
7742             6(?:
7743               06(?:
7744                 4\d|
7745                 7[4-79]
7746               )|
7747               295[567]|
7748               35[34]\d|
7749               47(?:
7750                 24|
7751                 61
7752               )|
7753               59(?:
7754                 5[08]|
7755                 6[67]|
7756                 74
7757               )|
7758               955[0-4]
7759             )|
7760             7(?:
7761               26(?:
7762                 6[13-9]|
7763                 7[0-7]
7764               )|
7765               442\d|
7766               50(?:
7767                 2[0-3]|
7768                 [3-68]2|
7769                 76
7770               )
7771             )|
7772             8(?:
7773               27[56]\d|
7774               37(?:
7775                 5[2-5]|
7776                 8[239]
7777               )|
7778               84(?:
7779                 3[2-58]
7780               )
7781             )|
7782             9(?:
7783               0(?:
7784                 0(?:
7785                   6[1-8]|
7786                   85
7787                 )|
7788                 52\d
7789               )|
7790               3583|
7791               4(?:
7792                 66[1-8]|
7793                 9(?:
7794                   2[01]|
7795                   81
7796                 )
7797               )|
7798               63(?:
7799                 23|
7800                 3[1-4]
7801               )|
7802               9561
7803             )
7804           )\d{3}|
7805           176888[234678]\d{2}|
7806           16977[23]\d{3}
7807         </nationalNumberPattern>
7808         <exampleNumber>1212345678</exampleNumber>
7809       </fixedLine>
7810       <mobile>
7811         <!-- http://stakeholders.ofcom.org.uk/telecoms/numbering/telephone-no-availability/numbers-administered/
7812              7100-7599, 7700-7999 with 10 digits; excluding ranges used in GG, IM, JE. -->
7813         <nationalNumberPattern>
7814           7(?:
7815             [1-4]\d\d|
7816             5(?:
7817               0[0-8]|
7818               [13-9]\d|
7819               2[0-35-9]
7820             )|
7821             7(?:
7822               0[1-9]|
7823               [1-7]\d|
7824               8[02-9]|
7825               9[0-689]
7826             )|
7827             8(?:
7828               [014-9]\d|
7829               [23][0-8]
7830             )|
7831             9(?:
7832               [04-9]\d|
7833               1[02-9]|
7834               2[0-35-9]|
7835               3[0-689]
7836             )
7837           )\d{6}
7838         </nationalNumberPattern>
7839         <possibleNumberPattern>\d{10}</possibleNumberPattern>
7840         <exampleNumber>7400123456</exampleNumber>
7841       </mobile>
7842       <pager>
7843         <!-- 76 with 10 digits; excluding ranges used in IM. -->
7844         <nationalNumberPattern>
7845           76(?:
7846             0[012]|
7847             2[356]|
7848             4[0134]|
7849             5[49]|
7850             6[0-369]|
7851             77|
7852             81|
7853             9[39]
7854           )\d{6}
7855         </nationalNumberPattern>
7856         <possibleNumberPattern>\d{10}</possibleNumberPattern>
7857         <exampleNumber>7640123456</exampleNumber>
7858       </pager>
7859       <!-- Source for non geographic numbers:
7860            http://en.wikipedia.org/wiki/Non-geographic_telephone_numbers_in_the_United_Kingdom -->
7861       <tollFree>
7862         <!-- 800 1111 with 7 digits, 800 with 9 or 10 digits, 808 with 10 digits, 500 with 9 digits.
7863              -->
7864         <nationalNumberPattern>
7865           80(?:
7866             0(?:
7867               1111|
7868               \d{6,7}
7869             )|
7870             8\d{7}
7871           )|
7872           500\d{6}
7873         </nationalNumberPattern>
7874         <possibleNumberPattern>\d{7}(?:\d{2,3})?</possibleNumberPattern>
7875         <exampleNumber>8001234567</exampleNumber>
7876       </tollFree>
7877       <premiumRate>
7878         <!-- 871, 872, 873 with 10 digits are now Controlled Premium Rate Services, so are listed
7879              here as well as 900-909, 910-919, 982-984, 989 with 10 digits.
7880              Note that only 908, 909, 980-989 are reserved for "adult services" while 900-907 and
7881              910-919 are reserved for standard premium rate services. -->
7882         <nationalNumberPattern>
7883           (?:
7884             87[123]|
7885             9(?:
7886               [01]\d|
7887               8[2349]
7888             )
7889           )\d{7}
7890         </nationalNumberPattern>
7891         <possibleNumberPattern>\d{10}</possibleNumberPattern>
7892         <exampleNumber>9012345678</exampleNumber>
7893       </premiumRate>
7894       <sharedCost>
7895         <!-- Using shared cost to deal with the various revenue sharing number prefixes in the
7896              United Kingdom: 845 46 47 with 7 digits, 842-845, 870 with 10 digits. -->
7897         <nationalNumberPattern>
7898           8(?:
7899             4(?:
7900               5464\d|
7901               [2-5]\d{7}
7902             )|
7903             70\d{7}
7904           )
7905         </nationalNumberPattern>
7906         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
7907         <exampleNumber>8431234567</exampleNumber>
7908       </sharedCost>
7909       <personalNumber>
7910         <!-- 70 with 10 digits. -->
7911         <nationalNumberPattern>70\d{8}</nationalNumberPattern>
7912         <possibleNumberPattern>\d{10}</possibleNumberPattern>
7913         <exampleNumber>7012345678</exampleNumber>
7914       </personalNumber>
7915       <voip>
7916         <!-- 56 with 10 digits. -->
7917         <nationalNumberPattern>56\d{8}</nationalNumberPattern>
7918         <possibleNumberPattern>\d{10}</possibleNumberPattern>
7919         <exampleNumber>5612345678</exampleNumber>
7920       </voip>
7921       <uan>
7922         <!-- 30d, 33d, 34d, 37d, 55 with 10 digits. -->
7923         <nationalNumberPattern>
7924           (?:
7925             3[0347]|
7926             55
7927           )\d{8}
7928         </nationalNumberPattern>
7929         <possibleNumberPattern>\d{10}</possibleNumberPattern>
7930         <exampleNumber>5512345678</exampleNumber>
7931       </uan>
7932     </territory>
7933
7934     <!-- Grenada -->
7935     <territory id="GD" countryCode="1" leadingDigits="473" nationalPrefix="1"
7936                internationalPrefix="011">
7937       <references>
7938         <sourceUrl>http://www.itu.int/oth/T0202000057/en</sourceUrl>
7939       </references>
7940       <generalDesc>
7941         <!-- NANPA country - uses US formatting rules -->
7942         <nationalNumberPattern>[4589]\d{9}</nationalNumberPattern>
7943         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
7944       </generalDesc>
7945       <fixedLine>
7946         <nationalNumberPattern>
7947           473(?:
7948             2(?:
7949               3[0-2]|
7950               69
7951             )|
7952             3(?:
7953               2[89]|
7954               86
7955             )|
7956             4(?:
7957               [06]8|
7958               3[5-9]|
7959               4[0-49]|
7960               5[5-79]|
7961               68|
7962               73|
7963               90
7964             )|
7965             63[68]|
7966             7(?:
7967               58|
7968               84
7969             )|
7970             800|
7971             938
7972           )\d{4}
7973         </nationalNumberPattern>
7974         <exampleNumber>4732691234</exampleNumber>
7975       </fixedLine>
7976       <mobile>
7977         <nationalNumberPattern>
7978           473(?:
7979             4(?:
7980               0[2-79]|
7981               1[04-9]|
7982               20|
7983               58
7984             )|
7985             5(?:
7986               2[01]|
7987               3[3-8]
7988             )|
7989             901
7990           )\d{4}
7991         </nationalNumberPattern>
7992         <possibleNumberPattern>\d{10}</possibleNumberPattern>
7993         <exampleNumber>4734031234</exampleNumber>
7994       </mobile>
7995       <tollFree>
7996         <nationalNumberPattern>
7997           8(?:
7998             00|
7999             44|
8000             55|
8001             66|
8002             77|
8003             88
8004           )[2-9]\d{6}
8005         </nationalNumberPattern>
8006         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8007         <exampleNumber>8002123456</exampleNumber>
8008       </tollFree>
8009       <premiumRate>
8010         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
8011         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8012         <exampleNumber>9002123456</exampleNumber>
8013       </premiumRate>
8014       <personalNumber>
8015         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
8016         <nationalNumberPattern>
8017           5(?:
8018             00|
8019             33|
8020             44|
8021             66|
8022             77
8023           )[2-9]\d{6}
8024         </nationalNumberPattern>
8025         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8026         <exampleNumber>5002345678</exampleNumber>
8027       </personalNumber>
8028     </territory>
8029
8030     <!-- Georgia -->
8031     <territory id="GE" countryCode="995" internationalPrefix="00" nationalPrefix="0"
8032                mobileNumberPortableRegion="true">
8033       <references>
8034         <sourceUrl>http://www.itu.int/oth/T0202000050/en</sourceUrl>
8035         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Georgia_(country)</sourceUrl>
8036       </references>
8037       <availableFormats>
8038         <!-- Format isn't very strictly defined - the yellow pages omits area code and does 2 2 2,
8039              the communications commission uses 2 3 3. Wikipedia says 3 2 3. Some use 2 6. -->
8040         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="$NP$FG">
8041           <leadingDigits>[348]</leadingDigits>
8042           <format>$1 $2 $3 $4</format>
8043         </numberFormat>
8044         <numberFormat pattern="(\d{3})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
8045           <leadingDigits>7</leadingDigits>
8046           <format>$1 $2 $3</format>
8047         </numberFormat>
8048         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="$FG">
8049           <leadingDigits>5</leadingDigits>
8050           <format>$1 $2 $3 $4</format>
8051         </numberFormat>
8052       </availableFormats>
8053       <noInternationalDialling>
8054         <!-- Online numbers mention that this is not internationally diallable. -->
8055         <nationalNumberPattern>706\d{6}</nationalNumberPattern>
8056         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8057         <exampleNumber>706123456</exampleNumber>
8058       </noInternationalDialling>
8059       <generalDesc>
8060         <nationalNumberPattern>[34578]\d{8}</nationalNumberPattern>
8061         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
8062       </generalDesc>
8063       <fixedLine>
8064         <nationalNumberPattern>
8065           (?:
8066             3(?:
8067               [256]\d|
8068               4[124-9]|
8069               7[0-4]
8070             )|
8071             4(?:
8072               1\d|
8073               2[2-7]|
8074               3[1-79]|
8075               4[2-8]|
8076               7[239]|
8077               9[1-7]
8078             )
8079           )\d{6}
8080         </nationalNumberPattern>
8081         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
8082         <exampleNumber>322123456</exampleNumber>
8083       </fixedLine>
8084       <mobile>
8085         <!-- The ITU document says 790 instead of 590, but this contradicts their press release
8086              about the change in numbers, and online numbers found. -->
8087         <nationalNumberPattern>
8088           5(?:
8089             14|
8090             5[01578]|
8091             68|
8092             7[0147-9]|
8093             9[0-35-9]
8094           )\d{6}
8095         </nationalNumberPattern>
8096         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8097         <exampleNumber>555123456</exampleNumber>
8098       </mobile>
8099       <!-- Information from http://www.yell.ge, examples such as Wissol Petroleum Georgia
8100            hotline. -->
8101       <tollFree>
8102         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
8103         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8104         <exampleNumber>800123456</exampleNumber>
8105       </tollFree>
8106       <voip>
8107         <!-- http://www.mydivert.com/virtual-numbers/995-virtual-number-National.html -->
8108         <nationalNumberPattern>706\d{6}</nationalNumberPattern>
8109         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8110         <exampleNumber>706123456</exampleNumber>
8111       </voip>
8112       <!-- It seems there may be special 6 digit numbers beginning with 91, but we are not sure, so
8113            these are omitted for now. -->
8114     </territory>
8115
8116     <!-- French Guiana (French Dept. of) -->
8117     <!-- Using a national prefix here as online numbers are formatted with it. -->
8118     <territory id="GF" countryCode="594" internationalPrefix="00"
8119                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
8120       <references>
8121         <sourceUrl>http://www.itu.int/oth/T020200004C/en</sourceUrl>
8122         <sourceUrl>http://www.arcep.fr/index.php?id=2137&amp;bloc=0594&amp;CMD=RESULTS_NUMEROTATION</sourceUrl>
8123         <sourceUrl>http://www.arcep.fr/uploads/tx_gsavis/11-1297.pdf</sourceUrl>
8124       </references>
8125       <availableFormats>
8126         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
8127           <format>$1 $2 $3 $4</format>
8128         </numberFormat>
8129       </availableFormats>
8130       <generalDesc>
8131         <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
8132         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8133       </generalDesc>
8134       <fixedLine>
8135         <nationalNumberPattern>
8136           594(?:
8137             10|
8138             2[012457-9]|
8139             3[0-57-9]|
8140             4[3-9]|
8141             5[7-9]|
8142             6[0-3]|
8143             9[014]
8144           )\d{4}
8145         </nationalNumberPattern>
8146         <exampleNumber>594101234</exampleNumber>
8147       </fixedLine>
8148       <mobile>
8149         <nationalNumberPattern>
8150           694(?:
8151             [04][0-7]|
8152             1[0-5]|
8153             3[018]|
8154             [29]\d
8155           )\d{4}
8156         </nationalNumberPattern>
8157         <exampleNumber>694201234</exampleNumber>
8158       </mobile>
8159       <!-- The 876 prefix is mentioned in the plan, but the plan is from 2006 and in France VOIP
8160            numbers were changed from 087 to the 09 prefix in 2009. It is likely this occurred here
8161            too. -->
8162     </territory>
8163
8164     <!-- Guernsey -->
8165     <!-- Inherits formatting rules from the UK. -->
8166     <territory id="GG" countryCode="44" internationalPrefix="00"
8167                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG">
8168       <references>
8169         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom</sourceUrl>
8170       </references>
8171       <generalDesc>
8172         <nationalNumberPattern>[135789]\d{6,9}</nationalNumberPattern>
8173         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
8174       </generalDesc>
8175       <areaCodeOptional>
8176         <nationalNumberPattern>1481[2-9]\d{5}</nationalNumberPattern>
8177         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8178         <exampleNumber>1481250123</exampleNumber>
8179       </areaCodeOptional>
8180       <!-- Specific to GG. -->
8181       <fixedLine>
8182         <!-- 1481 with 10 digits. -->
8183         <nationalNumberPattern>1481\d{6}</nationalNumberPattern>
8184         <exampleNumber>1481456789</exampleNumber>
8185       </fixedLine>
8186       <mobile>
8187         <!-- 7781, 7839, 7911 with 10 digits. -->
8188         <nationalNumberPattern>
8189           7(?:
8190             781|
8191             839|
8192             911
8193           )\d{6}
8194         </nationalNumberPattern>
8195         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8196         <exampleNumber>7781123456</exampleNumber>
8197       </mobile>
8198       <!-- Other numbers as per GB. -->
8199       <pager>
8200         <nationalNumberPattern>
8201           76(?:
8202             0[012]|
8203             2[356]|
8204             4[0134]|
8205             5[49]|
8206             6[0-369]|
8207             77|
8208             81|
8209             9[39]
8210           )\d{6}
8211         </nationalNumberPattern>
8212         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8213         <exampleNumber>7640123456</exampleNumber>
8214       </pager>
8215       <tollFree>
8216         <nationalNumberPattern>
8217           80(?:
8218             0(?:
8219               1111|
8220               \d{6,7}
8221             )|
8222             8\d{7}
8223           )|
8224           500\d{6}
8225         </nationalNumberPattern>
8226         <possibleNumberPattern>\d{7}(?:\d{2,3})?</possibleNumberPattern>
8227         <exampleNumber>8001234567</exampleNumber>
8228       </tollFree>
8229       <premiumRate>
8230         <nationalNumberPattern>
8231           (?:
8232             87[123]|
8233             9(?:
8234               [01]\d|
8235               8[0-3]
8236             )
8237           )\d{7}
8238         </nationalNumberPattern>
8239         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8240         <exampleNumber>9012345678</exampleNumber>
8241       </premiumRate>
8242       <sharedCost>
8243         <nationalNumberPattern>
8244           8(?:
8245             4(?:
8246               5464\d|
8247               [2-5]\d{7}
8248             )|
8249             70\d{7}
8250           )
8251         </nationalNumberPattern>
8252         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
8253         <exampleNumber>8431234567</exampleNumber>
8254       </sharedCost>
8255       <personalNumber>
8256         <nationalNumberPattern>70\d{8}</nationalNumberPattern>
8257         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8258         <exampleNumber>7012345678</exampleNumber>
8259       </personalNumber>
8260       <voip>
8261         <nationalNumberPattern>56\d{8}</nationalNumberPattern>
8262         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8263         <exampleNumber>5612345678</exampleNumber>
8264       </voip>
8265       <uan>
8266         <nationalNumberPattern>
8267           (?:
8268             3[0347]|
8269             55
8270           )\d{8}
8271         </nationalNumberPattern>
8272         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8273         <exampleNumber>5512345678</exampleNumber>
8274       </uan>
8275     </territory>
8276
8277     <!-- Ghana -->
8278     <territory id="GH" countryCode="233" internationalPrefix="00"
8279                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
8280                mobileNumberPortableRegion="true">
8281       <references>
8282         <sourceUrl>http://www.itu.int/oth/T0202000052/en</sourceUrl>
8283         <sourceUrl>http://www.nca.org.gh/index.php?option=com_content&amp;view=article&amp;id=90&amp;Itemid=65</sourceUrl>
8284       </references>
8285       <availableFormats>
8286         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
8287           <leadingDigits>[235]</leadingDigits>
8288           <format>$1 $2 $3</format>
8289         </numberFormat>
8290         <numberFormat pattern="(\d{3})(\d{5})">
8291           <leadingDigits>8</leadingDigits>
8292           <format>$1 $2</format>
8293         </numberFormat>
8294       </availableFormats>
8295       <generalDesc>
8296         <nationalNumberPattern>
8297           [235]\d{8}|
8298           8\d{7}
8299         </nationalNumberPattern>
8300         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
8301       </generalDesc>
8302       <noInternationalDialling>
8303         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
8304         <possibleNumberPattern>\d{8}</possibleNumberPattern>
8305         <exampleNumber>80012345</exampleNumber>
8306       </noInternationalDialling>
8307       <fixedLine>
8308         <nationalNumberPattern>
8309           3(?:
8310             0[237]\d|
8311             [167](?:
8312               2[0-6]|
8313               7\d
8314             )|
8315             2(?:
8316               2[0-5]|
8317               7\d
8318             )|
8319             3(?:
8320               2[0-3]|
8321               7\d
8322             )|
8323             4(?:
8324               2[013-9]|
8325               3[01]|
8326               7\d
8327             )|
8328             5(?:
8329               2[0-7]|
8330               7\d
8331             )|
8332             8(?:
8333               2[0-2]|
8334               7\d
8335             )|
8336             9(?:
8337               20|
8338               7\d
8339             )
8340           )\d{5}
8341         </nationalNumberPattern>
8342         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
8343         <exampleNumber>302345678</exampleNumber>
8344       </fixedLine>
8345       <mobile>
8346         <nationalNumberPattern>
8347           (?:
8348             2[034678]\d|
8349             5(?:
8350               [047]\d|
8351               5[3-6]|
8352               6[01]
8353             )
8354           )\d{6}
8355         </nationalNumberPattern>
8356         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8357         <exampleNumber>231234567</exampleNumber>
8358       </mobile>
8359       <tollFree>
8360         <!-- Found online references to these numbers, although they are not in the plan since they
8361              are not internationally diallable. -->
8362         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
8363         <possibleNumberPattern>\d{8}</possibleNumberPattern>
8364         <exampleNumber>80012345</exampleNumber>
8365       </tollFree>
8366       <!-- No premiumRate information can be found. -->
8367     </territory>
8368
8369     <!-- Gibraltar -->
8370     <territory id="GI" countryCode="350" internationalPrefix="00">
8371       <references>
8372         <sourceUrl>http://www.gra.gi/index.php?topic=numbering+plan&amp;section=legislation&amp;site=communications</sourceUrl>
8373       </references>
8374       <availableFormats>
8375         <!-- Most numbers are formatted as a block -->
8376         <numberFormat pattern="(\d{3})(\d{5})">
8377           <leadingDigits>2</leadingDigits>
8378           <format>$1 $2</format>
8379         </numberFormat>
8380       </availableFormats>
8381       <generalDesc>
8382         <nationalNumberPattern>[2568]\d{7}</nationalNumberPattern>
8383         <possibleNumberPattern>\d{8}</possibleNumberPattern>
8384       </generalDesc>
8385       <fixedLine>
8386         <nationalNumberPattern>
8387           2(?:
8388             00\d|
8389             1(?:
8390               6[24-7]|
8391               9\d
8392             )|
8393             2(?:
8394               00|
8395               2[2457]
8396             )
8397           )\d{4}
8398         </nationalNumberPattern>
8399         <exampleNumber>20012345</exampleNumber>
8400       </fixedLine>
8401       <mobile>
8402         <nationalNumberPattern>
8403           (?:
8404             5[46-8]|
8405             62
8406           )\d{6}
8407         </nationalNumberPattern>
8408         <exampleNumber>57123456</exampleNumber>
8409       </mobile>
8410       <tollFree>
8411         <nationalNumberPattern>80\d{6}</nationalNumberPattern>
8412         <exampleNumber>80123456</exampleNumber>
8413       </tollFree>
8414       <premiumRate>
8415         <nationalNumberPattern>8[1-689]\d{6}</nationalNumberPattern>
8416         <exampleNumber>88123456</exampleNumber>
8417       </premiumRate>
8418       <sharedCost>
8419         <nationalNumberPattern>87\d{6}</nationalNumberPattern>
8420         <exampleNumber>87123456</exampleNumber>
8421       </sharedCost>
8422     </territory>
8423
8424     <!-- Greenland -->
8425     <territory id="GL" countryCode="299" internationalPrefix="00">
8426       <references>
8427         <sourceUrl>http://www.itu.int/oth/T0202000056/en</sourceUrl>
8428       </references>
8429       <availableFormats>
8430         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
8431           <format>$1 $2 $3</format>
8432         </numberFormat>
8433       </availableFormats>
8434       <generalDesc>
8435         <nationalNumberPattern>[1-689]\d{5}</nationalNumberPattern>
8436         <possibleNumberPattern>\d{6}</possibleNumberPattern>
8437       </generalDesc>
8438       <fixedLine>
8439         <!-- Including VSAT numbers here. -->
8440         <nationalNumberPattern>
8441           (?:
8442             19|
8443             3[1-6]|
8444             6[14689]|
8445             8[14-79]|
8446             9\d
8447           )\d{4}
8448         </nationalNumberPattern>
8449         <exampleNumber>321000</exampleNumber>
8450       </fixedLine>
8451       <mobile>
8452         <nationalNumberPattern>[245][2-9]\d{4}</nationalNumberPattern>
8453         <exampleNumber>221234</exampleNumber>
8454       </mobile>
8455       <tollFree>
8456         <nationalNumberPattern>80\d{4}</nationalNumberPattern>
8457         <exampleNumber>801234</exampleNumber>
8458       </tollFree>
8459       <voip>
8460         <nationalNumberPattern>3[89]\d{4}</nationalNumberPattern>
8461         <exampleNumber>381234</exampleNumber>
8462       </voip>
8463     </territory>
8464
8465     <!-- Gambia -->
8466     <territory id="GM" countryCode="220" internationalPrefix="00">
8467       <references>
8468         <sourceUrl>http://www.itu.int/oth/T020200004F/en</sourceUrl>
8469       </references>
8470       <availableFormats>
8471         <numberFormat pattern="(\d{3})(\d{4})">
8472           <format>$1 $2</format>
8473         </numberFormat>
8474       </availableFormats>
8475       <generalDesc>
8476         <nationalNumberPattern>[2-9]\d{6}</nationalNumberPattern>
8477         <possibleNumberPattern>\d{7}</possibleNumberPattern>
8478       </generalDesc>
8479       <fixedLine>
8480         <nationalNumberPattern>
8481           (?:
8482             4(?:
8483               [23]\d{2}|
8484               4(?:
8485                 1[024679]|
8486                 [6-9]\d
8487               )
8488             )|
8489             5(?:
8490               54[0-7]|
8491               6(?:
8492                 [67]\d
8493               )|
8494               7(?:
8495                 1[04]|
8496                 2[035]|
8497                 3[58]|
8498                 48
8499               )
8500             )|
8501             8\d{3}
8502           )\d{3}
8503         </nationalNumberPattern>
8504         <exampleNumber>5661234</exampleNumber>
8505       </fixedLine>
8506       <mobile>
8507         <nationalNumberPattern>
8508           (?:
8509             2[0-6]|
8510             [3679]\d
8511           )\d{5}
8512         </nationalNumberPattern>
8513         <exampleNumber>3012345</exampleNumber>
8514       </mobile>
8515     </territory>
8516
8517     <!-- Guinea -->
8518     <territory id="GN" countryCode="224" internationalPrefix="00">
8519       <references>
8520         <sourceUrl>http://www.itu.int/oth/T020200005B/en</sourceUrl>
8521       </references>
8522       <availableFormats>
8523         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
8524           <leadingDigits>3</leadingDigits>
8525           <format>$1 $2 $3 $4</format>
8526         </numberFormat>
8527         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
8528           <leadingDigits>[67]</leadingDigits>
8529           <format>$1 $2 $3 $4</format>
8530         </numberFormat>
8531       </availableFormats>
8532       <generalDesc>
8533         <nationalNumberPattern>[367]\d{7,8}</nationalNumberPattern>
8534         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
8535       </generalDesc>
8536       <fixedLine>
8537         <nationalNumberPattern>
8538           30(?:
8539             24|
8540             3[12]|
8541             4[1-35-7]|
8542             5[13]|
8543             6[189]|
8544             [78]1|
8545             9[1478]
8546           )\d{4}
8547         </nationalNumberPattern>
8548         <possibleNumberPattern>\d{8}</possibleNumberPattern>
8549         <exampleNumber>30241234</exampleNumber>
8550       </fixedLine>
8551       <mobile>
8552         <!-- Prefixes here match those assigned to carriers, as per the ITU communication Jan 23rd
8553              2013. -->
8554         <nationalNumberPattern>6[02356]\d{7}</nationalNumberPattern>
8555         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8556         <exampleNumber>601123456</exampleNumber>
8557       </mobile>
8558       <voip>
8559         <!-- Gamma concept network is being listed as VoIP as per
8560              http://www.gammaconcept.com/internet%20sat.html -->
8561         <nationalNumberPattern>722\d{6}</nationalNumberPattern>
8562         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8563         <exampleNumber>722123456</exampleNumber>
8564       </voip>
8565     </territory>
8566
8567     <!-- Guadeloupe -->
8568     <territory id="GP" countryCode="590" internationalPrefix="00"
8569                mainCountryForCode="true" nationalPrefix="0"
8570                nationalPrefixFormattingRule="$NP$FG">
8571       <references>
8572         <sourceUrl>http://www.itu.int/oth/T0202000058/en</sourceUrl>
8573         <!-- Linked from http://www.arcep.fr/index.php?id=interactivenumeros -->
8574         <sourceUrl>http://www.arcep.fr/fileadmin/reprise/dossiers/numero/ZABPQ-ZNE.xls</sourceUrl>
8575       </references>
8576       <availableFormats>
8577         <numberFormat pattern="([56]90)(\d{2})(\d{4})">
8578           <format>$1 $2-$3</format>
8579         </numberFormat>
8580       </availableFormats>
8581       <generalDesc>
8582         <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
8583         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8584       </generalDesc>
8585       <fixedLine>
8586         <nationalNumberPattern>
8587           590(?:
8588             0[13468]|
8589             1[012]|
8590             2[0-68]|
8591             3[28]|
8592             4[0-8]|
8593             5[579]|
8594             6[0189]|
8595             70|
8596             8[0-689]|
8597             9\d
8598           )\d{4}
8599         </nationalNumberPattern>
8600         <exampleNumber>590201234</exampleNumber>
8601       </fixedLine>
8602       <mobile>
8603         <!-- Any ranges assigned from
8604              http://www.arcep.fr/index.php?id=interactivenumeros have been listed as belonging to
8605              Guadeloupe, St Martin and St Barthélemy, since we can't reliably distinguish between
8606              them. -->
8607         <nationalNumberPattern>
8608           690(?:
8609             0[0-7]|
8610             [1-9]\d
8611           )\d{4}
8612         </nationalNumberPattern>
8613         <exampleNumber>690301234</exampleNumber>
8614       </mobile>
8615     </territory>
8616
8617     <!-- Equatorial Guinea -->
8618     <territory id="GQ" countryCode="240" internationalPrefix="00">
8619       <references>
8620         <sourceUrl>http://www.itu.int/oth/T0202000041/en</sourceUrl>
8621       </references>
8622       <availableFormats>
8623         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
8624           <leadingDigits>[235]</leadingDigits>
8625           <format>$1 $2 $3</format>
8626         </numberFormat>
8627         <numberFormat pattern="(\d{3})(\d{6})">
8628           <leadingDigits>[89]</leadingDigits>
8629           <format>$1 $2</format>
8630         </numberFormat>
8631       </availableFormats>
8632       <generalDesc>
8633         <nationalNumberPattern>[23589]\d{8}</nationalNumberPattern>
8634         <possibleNumberPattern>\d{9}</possibleNumberPattern>
8635       </generalDesc>
8636       <fixedLine>
8637         <nationalNumberPattern>
8638           3(?:
8639             3(?:
8640               3\d[7-9]|
8641               [0-24-9]\d[46]
8642             )|
8643             5\d{2}[7-9]
8644           )\d{4}
8645         </nationalNumberPattern>
8646         <exampleNumber>333091234</exampleNumber>
8647       </fixedLine>
8648       <mobile>
8649         <nationalNumberPattern>
8650           (?:
8651             222|
8652             551
8653           )\d{6}
8654         </nationalNumberPattern>
8655         <exampleNumber>222123456</exampleNumber>
8656       </mobile>
8657       <!-- Note that personal and sharedCost numbers are said to go under here too - hopefully when
8658            they start allocating them there will be a differentiation of prefixes, but this is not
8659            clear now. -->
8660       <tollFree>
8661         <nationalNumberPattern>80\d[1-9]\d{5}</nationalNumberPattern>
8662         <exampleNumber>800123456</exampleNumber>
8663       </tollFree>
8664       <premiumRate>
8665         <nationalNumberPattern>90\d[1-9]\d{5}</nationalNumberPattern>
8666         <exampleNumber>900123456</exampleNumber>
8667       </premiumRate>
8668     </territory>
8669
8670     <!-- Greece -->
8671     <territory id="GR" countryCode="30" internationalPrefix="00" mobileNumberPortableRegion="true">
8672       <references>
8673         <sourceUrl>http://www.itu.int/oth/T0202000055/en</sourceUrl>
8674         <sourceUrl>http://en.wikipedia.org/wiki/%2B30</sourceUrl>
8675       </references>
8676       <availableFormats>
8677         <numberFormat pattern="([27]\d)(\d{4})(\d{4})">
8678           <leadingDigits>
8679             21|
8680             7
8681           </leadingDigits>
8682           <format>$1 $2 $3</format>
8683         </numberFormat>
8684         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
8685           <leadingDigits>
8686             2[2-9]1|
8687             [689]
8688           </leadingDigits>
8689           <format>$1 $2 $3</format>
8690         </numberFormat>
8691         <numberFormat pattern="(2\d{3})(\d{6})">
8692           <leadingDigits>2[2-9][02-9]</leadingDigits>
8693           <format>$1 $2</format>
8694         </numberFormat>
8695       </availableFormats>
8696       <generalDesc>
8697         <nationalNumberPattern>[26-9]\d{9}</nationalNumberPattern>
8698         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8699       </generalDesc>
8700       <fixedLine>
8701         <nationalNumberPattern>
8702           2(?:
8703             1\d{2}|
8704             2(?:
8705               2[1-46-9]|
8706               3[1-8]|
8707               4[1-7]|
8708               5[1-4]|
8709               6[1-8]|
8710               7[1-5]|
8711               [89][1-9]
8712             )|
8713             3(?:
8714               1\d|
8715               2[1-57]|
8716               [35][1-3]|
8717               4[13]|
8718               7[1-7]|
8719               8[124-6]|
8720               9[1-79]
8721             )|
8722             4(?:
8723               1\d|
8724               2[1-8]|
8725               3[1-4]|
8726               4[13-5]|
8727               6[1-578]|
8728               9[1-5]
8729             )|
8730             5(?:
8731               1\d|
8732               [29][1-4]|
8733               3[1-5]|
8734               4[124]|
8735               5[1-6]
8736             )|
8737             6(?:
8738               1\d|
8739               3[1245]|
8740               4[1-7]|
8741               5[13-9]|
8742               [269][1-6]|
8743               7[14]|
8744               8[1-5]
8745             )|
8746             7(?:
8747               1\d|
8748               2[1-5]|
8749               3[1-6]|
8750               4[1-7]|
8751               5[1-57]|
8752               6[135]|
8753               9[125-7]
8754             )|
8755             8(?:
8756               1\d|
8757               2[1-5]|
8758               [34][1-4]|
8759               9[1-57]
8760             )
8761           )\d{6}
8762         </nationalNumberPattern>
8763         <exampleNumber>2123456789</exampleNumber>
8764       </fixedLine>
8765       <mobile>
8766         <nationalNumberPattern>69\d{8}</nationalNumberPattern>
8767         <exampleNumber>6912345678</exampleNumber>
8768       </mobile>
8769       <tollFree>
8770         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
8771         <exampleNumber>8001234567</exampleNumber>
8772       </tollFree>
8773       <premiumRate>
8774         <nationalNumberPattern>90[19]\d{7}</nationalNumberPattern>
8775         <exampleNumber>9091234567</exampleNumber>
8776       </premiumRate>
8777       <!-- Including calls with maximum charge of 0,25 EUR/minute here instead of under premium
8778            rate. -->
8779       <sharedCost>
8780         <nationalNumberPattern>
8781           8(?:
8782             0[16]|
8783             12|
8784             25
8785           )\d{7}
8786         </nationalNumberPattern>
8787         <exampleNumber>8011234567</exampleNumber>
8788       </sharedCost>
8789       <personalNumber>
8790         <nationalNumberPattern>70\d{8}</nationalNumberPattern>
8791         <exampleNumber>7012345678</exampleNumber>
8792       </personalNumber>
8793     </territory>
8794
8795     <!-- Guatemala -->
8796     <territory id="GT" countryCode="502" internationalPrefix="00">
8797       <references>
8798         <sourceUrl>http://www.itu.int/oth/T020200005A/en</sourceUrl>
8799         <sourceUrl>http://www.sit.gob.gt/index.php?page=plan-de-numeracion</sourceUrl>
8800         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Guatemala</sourceUrl>
8801       </references>
8802       <availableFormats>
8803         <numberFormat pattern="(\d{4})(\d{4})">
8804           <leadingDigits>[2-7]</leadingDigits>
8805           <format>$1 $2</format>
8806         </numberFormat>
8807         <numberFormat pattern="(\d{4})(\d{3})(\d{4})">
8808           <leadingDigits>1</leadingDigits>
8809           <format>$1 $2 $3</format>
8810         </numberFormat>
8811       </availableFormats>
8812       <generalDesc>
8813         <nationalNumberPattern>
8814           [2-7]\d{7}|
8815           1[89]\d{9}
8816         </nationalNumberPattern>
8817         <possibleNumberPattern>\d{8}(?:\d{3})?</possibleNumberPattern>
8818       </generalDesc>
8819       <fixedLine>
8820         <nationalNumberPattern>[267][2-9]\d{6}</nationalNumberPattern>
8821         <possibleNumberPattern>\d{8}</possibleNumberPattern>
8822         <exampleNumber>22456789</exampleNumber>
8823       </fixedLine>
8824       <mobile>
8825         <!-- Wikipedia claims numbers with 3 are also mobile although in ITU document it says that
8826              they are just reserved. -->
8827         <nationalNumberPattern>[345]\d{7}</nationalNumberPattern>
8828         <possibleNumberPattern>\d{8}</possibleNumberPattern>
8829         <exampleNumber>51234567</exampleNumber>
8830       </mobile>
8831       <tollFree>
8832         <nationalNumberPattern>18[01]\d{8}</nationalNumberPattern>
8833         <possibleNumberPattern>\d{11}</possibleNumberPattern>
8834         <exampleNumber>18001112222</exampleNumber>
8835       </tollFree>
8836       <premiumRate>
8837         <nationalNumberPattern>19\d{9}</nationalNumberPattern>
8838         <possibleNumberPattern>\d{11}</possibleNumberPattern>
8839         <exampleNumber>19001112222</exampleNumber>
8840       </premiumRate>
8841     </territory>
8842
8843     <!-- Guam -->
8844     <territory id="GU" countryCode="1" leadingDigits="671" nationalPrefix="1"
8845                internationalPrefix="011">
8846       <references>
8847         <sourceUrl>http://www.nationalnanpa.com/nas/public/assigned_code_query_step1.do?method=resetCodeQueryModel</sourceUrl>
8848       </references>
8849       <generalDesc>
8850         <!-- NANPA country - uses US formatting rules -->
8851         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
8852         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
8853       </generalDesc>
8854       <fixedLine>
8855         <!-- Added 671 489/555/720/721 based on information from
8856              http://www.area-codes.com/area-code/area-code-671.asp -->
8857         <nationalNumberPattern>
8858           671(?:
8859             3(?:
8860               00|
8861               3[39]|
8862               4[349]|
8863               55|
8864               6[26]
8865             )|
8866             4(?:
8867               56|
8868               7[1-9]|
8869               8[236-9]
8870             )|
8871             5(?:
8872               55|
8873               6[2-5]|
8874               88
8875             )|
8876             6(?:
8877               3[2-578]|
8878               4[24-9]|
8879               5[34]|
8880               78|
8881               8[5-9]
8882             )|
8883             7(?:
8884               [079]7|
8885               2[0167]|
8886               3[45]|
8887               8[789]
8888             )|
8889             8(?:
8890               [2-5789]8|
8891               6[48]
8892             )|
8893             9(?:
8894               2[29]|
8895               6[79]|
8896               7[179]|
8897               8[789]|
8898               9[78]
8899             )
8900           )\d{4}
8901         </nationalNumberPattern>
8902         <exampleNumber>6713001234</exampleNumber>
8903       </fixedLine>
8904       <!-- We assume mobile phone numbers to be the same as fixed-line - further info unavailable
8905            -->
8906       <mobile>
8907         <nationalNumberPattern>
8908           671(?:
8909             3(?:
8910               00|
8911               3[39]|
8912               4[349]|
8913               55|
8914               6[26]
8915             )|
8916             4(?:
8917               56|
8918               7[1-9]|
8919               8[236-9]
8920             )|
8921             5(?:
8922               55|
8923               6[2-5]|
8924               88
8925             )|
8926             6(?:
8927               3[2-578]|
8928               4[24-9]|
8929               5[34]|
8930               78|
8931               8[5-9]
8932             )|
8933             7(?:
8934               [079]7|
8935               2[0167]|
8936               3[45]|
8937               8[789]
8938             )|
8939             8(?:
8940               [2-5789]8|
8941               6[48]
8942             )|
8943             9(?:
8944               2[29]|
8945               6[79]|
8946               7[179]|
8947               8[789]|
8948               9[78]
8949             )
8950           )\d{4}
8951         </nationalNumberPattern>
8952         <exampleNumber>6713001234</exampleNumber>
8953       </mobile>
8954       <tollFree>
8955         <nationalNumberPattern>
8956           8(?:
8957             00|
8958             44|
8959             55|
8960             66|
8961             77|
8962             88
8963           )[2-9]\d{6}
8964         </nationalNumberPattern>
8965         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8966         <exampleNumber>8002123456</exampleNumber>
8967       </tollFree>
8968       <premiumRate>
8969         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
8970         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8971         <exampleNumber>9002123456</exampleNumber>
8972       </premiumRate>
8973       <personalNumber>
8974         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
8975         <nationalNumberPattern>
8976           5(?:
8977             00|
8978             33|
8979             44|
8980             66|
8981             77
8982           )[2-9]\d{6}
8983         </nationalNumberPattern>
8984         <possibleNumberPattern>\d{10}</possibleNumberPattern>
8985         <exampleNumber>5002345678</exampleNumber>
8986       </personalNumber>
8987     </territory>
8988
8989     <!-- Guinea-Bissau -->
8990     <territory id="GW" countryCode="245" internationalPrefix="00">
8991       <references>
8992         <sourceUrl>http://www.itu.int/oth/T020200005C/en</sourceUrl>
8993       </references>
8994       <availableFormats>
8995         <numberFormat pattern="(\d{3})(\d{4})">
8996           <format>$1 $2</format>
8997         </numberFormat>
8998       </availableFormats>
8999       <generalDesc>
9000         <nationalNumberPattern>[3-79]\d{6}</nationalNumberPattern>
9001         <possibleNumberPattern>\d{7}</possibleNumberPattern>
9002       </generalDesc>
9003       <fixedLine>
9004         <nationalNumberPattern>
9005           3(?:
9006             2[0125]|
9007             3[1245]|
9008             4[12]|
9009             5[1-4]|
9010             70|
9011             9[1-467]
9012           )\d{4}
9013         </nationalNumberPattern>
9014         <exampleNumber>3201234</exampleNumber>
9015       </fixedLine>
9016       <mobile>
9017         <nationalNumberPattern>
9018           (?:
9019             [5-7]\d|
9020             9[012]
9021           )\d{5}
9022         </nationalNumberPattern>
9023         <exampleNumber>5012345</exampleNumber>
9024       </mobile>
9025       <voip>
9026         <nationalNumberPattern>40\d{5}</nationalNumberPattern>
9027         <exampleNumber>4012345</exampleNumber>
9028       </voip>
9029     </territory>
9030
9031     <!-- Guyana -->
9032     <territory id="GY" countryCode="592" internationalPrefix="001">
9033       <references>
9034         <sourceUrl>http://www.itu.int/oth/T020200005D/en</sourceUrl>
9035       </references>
9036       <availableFormats>
9037         <numberFormat pattern="(\d{3})(\d{4})">
9038           <format>$1 $2</format>
9039         </numberFormat>
9040       </availableFormats>
9041       <generalDesc>
9042         <nationalNumberPattern>[2-4679]\d{6}</nationalNumberPattern>
9043         <possibleNumberPattern>\d{7}</possibleNumberPattern>
9044       </generalDesc>
9045       <fixedLine>
9046         <nationalNumberPattern>
9047           (?:
9048             2(?:
9049               1[6-9]|
9050               2[0-35-9]|
9051               3[1-4]|
9052               5[3-9]|
9053               6\d|
9054               7[0-24-79]
9055             )|
9056             3(?:
9057               2[25-9]|
9058               3\d
9059             )|
9060             4(?:
9061               4[0-24]|
9062               5[56]
9063             )|
9064             77[1-57]
9065           )\d{4}
9066         </nationalNumberPattern>
9067         <exampleNumber>2201234</exampleNumber>
9068       </fixedLine>
9069       <mobile>
9070         <!-- The ITU document only describes a few ranges for mobile numbers but there is evidence
9071              that SMS messages have been succesfully sent to numbers in the entire range prefixed
9072              with 6. -->
9073         <nationalNumberPattern>6\d{6}</nationalNumberPattern>
9074         <exampleNumber>6091234</exampleNumber>
9075       </mobile>
9076       <tollFree>
9077         <nationalNumberPattern>
9078           (?:
9079             289|
9080             862
9081           )\d{4}
9082         </nationalNumberPattern>
9083         <exampleNumber>2891234</exampleNumber>
9084       </tollFree>
9085       <premiumRate>
9086         <nationalNumberPattern>9008\d{3}</nationalNumberPattern>
9087         <exampleNumber>9008123</exampleNumber>
9088       </premiumRate>
9089     </territory>
9090
9091     <!-- Hong Kong -->
9092     <territory id="HK" countryCode="852" internationalPrefix="00" mobileNumberPortableRegion="true">
9093       <references>
9094         <sourceUrl>http://www.ofca.gov.hk/en/industry_focus/telecommunications/portability/index.html</sourceUrl>
9095       </references>
9096       <availableFormats>
9097         <numberFormat pattern="(\d{4})(\d{4})">
9098           <leadingDigits>
9099             [235-7]|
9100             [89](?:
9101               0[1-9]|
9102               [1-9]
9103             )
9104           </leadingDigits>
9105           <format>$1 $2</format>
9106         </numberFormat>
9107         <numberFormat pattern="(800)(\d{3})(\d{3})">
9108           <leadingDigits>800</leadingDigits>
9109           <format>$1 $2 $3</format>
9110         </numberFormat>
9111         <numberFormat pattern="(900)(\d{2})(\d{3})(\d{3})">
9112           <leadingDigits>900</leadingDigits>
9113           <format>$1 $2 $3 $4</format>
9114         </numberFormat>
9115         <numberFormat pattern="(900)(\d{2,5})">
9116           <leadingDigits>900</leadingDigits>
9117           <format>$1 $2</format>
9118         </numberFormat>
9119       </availableFormats>
9120       <generalDesc>
9121         <!-- Slightly more complex pattern to allow the country code to be stripped off if
9122              necessary. -->
9123         <nationalNumberPattern>
9124           [235-7]\d{7}|
9125           8\d{7,8}|
9126           9\d{4,10}
9127         </nationalNumberPattern>
9128         <possibleNumberPattern>\d{5,11}</possibleNumberPattern>
9129       </generalDesc>
9130       <fixedLine>
9131         <nationalNumberPattern>
9132           (?:
9133             [23]\d|
9134             5[78]
9135           )\d{6}
9136         </nationalNumberPattern>
9137         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9138         <exampleNumber>21234567</exampleNumber>
9139       </fixedLine>
9140       <mobile>
9141         <nationalNumberPattern>
9142           (?:
9143             5[1-69]\d|
9144             6\d{2}|
9145             9(?:
9146               0[1-9]|
9147               [1-8]\d
9148             )
9149           )\d{5}
9150         </nationalNumberPattern>
9151         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9152         <exampleNumber>51234567</exampleNumber>
9153       </mobile>
9154       <pager>
9155         <nationalNumberPattern>7\d{7}</nationalNumberPattern>
9156         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9157         <exampleNumber>71234567</exampleNumber>
9158       </pager>
9159       <tollFree>
9160         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
9161         <possibleNumberPattern>\d{9}</possibleNumberPattern>
9162         <exampleNumber>800123456</exampleNumber>
9163       </tollFree>
9164       <premiumRate>
9165         <nationalNumberPattern>
9166           900(?:
9167             [0-24-9]\d{7}|
9168             3\d{1,4}
9169           )
9170         </nationalNumberPattern>
9171         <possibleNumberPattern>\d{5,11}</possibleNumberPattern>
9172         <exampleNumber>90012345678</exampleNumber>
9173       </premiumRate>
9174       <personalNumber>
9175         <nationalNumberPattern>8[1-3]\d{6}</nationalNumberPattern>
9176         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9177         <exampleNumber>81123456</exampleNumber>
9178       </personalNumber>
9179    </territory>
9180
9181     <!-- Honduras -->
9182     <!-- It seems there is no longer a trunk prefix in use, based on websites like
9183          http://www.howtocallabroad.com/codes.html and on seeing how locals write their numbers in
9184          national format. -->
9185     <territory id="HN" countryCode="504" internationalPrefix="00" >
9186       <references>
9187         <sourceUrl>http://www.itu.int/oth/T020200005F/en</sourceUrl>
9188       </references>
9189       <availableFormats>
9190        <numberFormat pattern="(\d{4})(\d{4})">
9191          <format>$1-$2</format>
9192        </numberFormat>
9193       </availableFormats>
9194       <generalDesc>
9195         <nationalNumberPattern>[237-9]\d{7}</nationalNumberPattern>
9196         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9197       </generalDesc>
9198       <fixedLine>
9199         <!-- Extra prefixes 227[01389], 228X, 2292 & 260X were added from numbers found online. -->
9200         <nationalNumberPattern>
9201           2(?:
9202             2(?:
9203               0[019]|
9204               1[1-36]|
9205               [23]\d|
9206               4[056]|
9207               5[57]|
9208               7[01389]|
9209               8[0146-9]|
9210               9[012]
9211             )|
9212             4(?:
9213               2[3-59]|
9214               3[13-689]|
9215               4[0-68]|
9216               5[1-35]
9217             )|
9218             5(?:
9219               4[3-5]|
9220               5\d|
9221               6[56]|
9222               74
9223             )|
9224             6(?:
9225               [056]\d|
9226               4[0-378]|
9227               [78][0-8]|
9228               9[01]
9229             )|
9230             7(?:
9231               6[46-9]|
9232               7[02-9]|
9233               8[34]
9234             )|
9235             8(?:
9236               79|
9237               8[0-35789]|
9238               9[1-57-9]
9239             )
9240           )\d{4}
9241         </nationalNumberPattern>
9242         <exampleNumber>22123456</exampleNumber>
9243       </fixedLine>
9244       <mobile>
9245         <nationalNumberPattern>[37-9]\d{7}</nationalNumberPattern>
9246         <exampleNumber>91234567</exampleNumber>
9247       </mobile>
9248     </territory>
9249
9250     <!-- Croatia -->
9251     <territory id="HR" countryCode="385" internationalPrefix="00"
9252                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
9253                mobileNumberPortableRegion="true">
9254       <references>
9255         <sourceUrl>http://www.itu.int/oth/T0202000032/en</sourceUrl>
9256         <sourceUrl>http://en.wikipedia.org/wiki/%2B385</sourceUrl>
9257       </references>
9258       <availableFormats>
9259         <!-- The plan says 1 XXX XXXX but the government and local telecom websites are formatted 1
9260              XXXX XXX, so we prefer that formatting here. These same sources prefer XXX XXX to XX
9261              XXXX as well. -->
9262        <numberFormat pattern="(1)(\d{4})(\d{3})">
9263          <leadingDigits>1</leadingDigits>
9264          <format>$1 $2 $3</format>
9265        </numberFormat>
9266        <numberFormat pattern="(6[09])(\d{4})(\d{3})">
9267          <leadingDigits>6[09]</leadingDigits>
9268          <format>$1 $2 $3</format>
9269        </numberFormat>
9270        <numberFormat pattern="(62)(\d{3})(\d{3,4})">
9271          <leadingDigits>62</leadingDigits>
9272          <format>$1 $2 $3</format>
9273        </numberFormat>
9274        <numberFormat pattern="([2-5]\d)(\d{3})(\d{3})">
9275          <leadingDigits>[2-5]</leadingDigits>
9276           <format>$1 $2 $3</format>
9277         </numberFormat>
9278         <numberFormat pattern="(9\d)(\d{3})(\d{3,4})">
9279           <leadingDigits>9</leadingDigits>
9280           <format>$1 $2 $3</format>
9281         </numberFormat>
9282         <numberFormat pattern="(9\d)(\d{4})(\d{4})">
9283           <leadingDigits>9</leadingDigits>
9284           <format>$1 $2 $3</format>
9285         </numberFormat>
9286         <numberFormat pattern="(9\d)(\d{3,4})(\d{3})(\d{3})">
9287           <leadingDigits>9</leadingDigits>
9288           <format>$1 $2 $3 $4</format>
9289         </numberFormat>
9290         <numberFormat pattern="(\d{2})(\d{2})(\d{2,3})">
9291           <leadingDigits>
9292             6[145]|
9293             7
9294           </leadingDigits>
9295           <format>$1 $2 $3</format>
9296         </numberFormat>
9297         <numberFormat pattern="(\d{2})(\d{3,4})(\d{3})">
9298           <leadingDigits>
9299             6[145]|
9300             7
9301           </leadingDigits>
9302           <format>$1 $2 $3</format>
9303         </numberFormat>
9304         <numberFormat pattern="(80[01])(\d{2})(\d{2,3})">
9305           <leadingDigits>8</leadingDigits>
9306           <format>$1 $2 $3</format>
9307         </numberFormat>
9308         <numberFormat pattern="(80[01])(\d{3,4})(\d{3})">
9309           <leadingDigits>8</leadingDigits>
9310           <format>$1 $2 $3</format>
9311         </numberFormat>
9312       </availableFormats>
9313       <generalDesc>
9314         <nationalNumberPattern>
9315           [1-7]\d{5,8}|
9316           [89]\d{6,11}
9317         </nationalNumberPattern>
9318         <possibleNumberPattern>\d{6,12}</possibleNumberPattern>
9319       </generalDesc>
9320       <fixedLine>
9321         <nationalNumberPattern>
9322           1\d{7}|
9323           (?:
9324             2[0-3]|
9325             3[1-5]|
9326             4[02-47-9]|
9327             5[1-3]
9328           )\d{6}
9329         </nationalNumberPattern>
9330         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
9331         <exampleNumber>12345678</exampleNumber>
9332       </fixedLine>
9333       <uan>
9334         <!-- ITU numbering plan doesn't specify the length of the numbers with prefix 62, but there
9335              are numbers on the internet with 6 or 7 digits after the prefix. -->
9336         <nationalNumberPattern>62\d{6,7}</nationalNumberPattern>
9337         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
9338         <exampleNumber>62123456</exampleNumber>
9339       </uan>
9340       <mobile>
9341         <nationalNumberPattern>9[1257-9]\d{6,10}</nationalNumberPattern>
9342         <possibleNumberPattern>\d{8,12}</possibleNumberPattern>
9343         <exampleNumber>912345678</exampleNumber>
9344       </mobile>
9345       <tollFree>
9346         <nationalNumberPattern>80[01]\d{4,7}</nationalNumberPattern>
9347         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
9348         <exampleNumber>8001234567</exampleNumber>
9349       </tollFree>
9350       <premiumRate>
9351         <!-- The prefixes 060, 061, 064, 065 and 069 are named as premium rate numbers by
9352              http://www.vipnet.hr/en/poslovni-korisnici/telefon-internet/vip-adsl-usluga#panel_4.
9353              -->
9354         <nationalNumberPattern>
9355           6(?:
9356             [09]\d{7}|
9357             [145]\d{4,7}
9358           )
9359         </nationalNumberPattern>
9360         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
9361         <exampleNumber>611234</exampleNumber>
9362       </premiumRate>
9363       <personalNumber>
9364         <nationalNumberPattern>7[45]\d{4,7}</nationalNumberPattern>
9365         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
9366         <exampleNumber>741234567</exampleNumber>
9367       </personalNumber>
9368     </territory>
9369
9370     <!-- Haiti -->
9371     <territory id="HT" countryCode="509" internationalPrefix="00">
9372       <references>
9373         <sourceUrl>http://www.itu.int/oth/T020200005E/en</sourceUrl>
9374         <sourceUrl>http://www.numberingplans.com/</sourceUrl>
9375       </references>
9376       <availableFormats>
9377         <numberFormat pattern="(\d{2})(\d{2})(\d{4})">
9378           <format>$1 $2 $3</format>
9379         </numberFormat>
9380       </availableFormats>
9381       <generalDesc>
9382         <nationalNumberPattern>[2-489]\d{7}</nationalNumberPattern>
9383         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9384       </generalDesc>
9385       <fixedLine>
9386         <!-- The prefix 24 seems to be also used, based on online searches. -->
9387         <nationalNumberPattern>
9388           2(?:
9389             [24]\d|
9390             5[1-5]|
9391             94
9392           )\d{5}
9393         </nationalNumberPattern>
9394         <exampleNumber>22453300</exampleNumber>
9395       </fixedLine>
9396       <mobile>
9397         <!-- The prefix 31 seems to be also used, based on online searches. -->
9398         <nationalNumberPattern>
9399           (?:
9400             3[1-9]|
9401             4\d
9402           )\d{6}
9403         </nationalNumberPattern>
9404         <exampleNumber>34101234</exampleNumber>
9405       </mobile>
9406       <tollFree>
9407         <!-- ITU document says numbers with prefix 8 are "value-added services and free numbers
9408              without making any further distinction. However, http://www.numberingplans.com/ seems
9409              to suggest they are free. -->
9410         <nationalNumberPattern>8\d{7}</nationalNumberPattern>
9411         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9412         <exampleNumber>80012345</exampleNumber>
9413       </tollFree>
9414       <voip>
9415         <!-- ITU document suggests 98\d{6}, but http://www.numberingplans.com/ restricts it to
9416              98[89]\d{5}. -->
9417         <nationalNumberPattern>98[89]\d{5}</nationalNumberPattern>
9418         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9419         <exampleNumber>98901234</exampleNumber>
9420       </voip>
9421     </territory>
9422
9423     <!-- Hungary -->
9424     <territory id="HU" countryCode="36" internationalPrefix="00"
9425                nationalPrefix="06" nationalPrefixFormattingRule="($FG)"
9426                mobileNumberPortableRegion="true">
9427       <references>
9428         <sourceUrl>http://www.itu.int/oth/T0202000061/en</sourceUrl>
9429       </references>
9430       <!-- Although the national prefix is necessary for dialling, the preferred format (confirmed
9431            by a Hungarian person and following the yellow pages) is to omit this when formatting.
9432            Yellow pages: http://www.aranyoldalak.hu -->
9433       <availableFormats>
9434         <numberFormat pattern="(1)(\d{3})(\d{4})">
9435           <leadingDigits>1</leadingDigits>
9436           <format>$1 $2 $3</format>
9437         </numberFormat>
9438         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})">
9439           <leadingDigits>[2-9]</leadingDigits>
9440           <format>$1 $2 $3</format>
9441         </numberFormat>
9442       </availableFormats>
9443       <generalDesc>
9444         <nationalNumberPattern>[1-9]\d{7,8}</nationalNumberPattern>
9445         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
9446       </generalDesc>
9447       <noInternationalDialling>
9448         <nationalNumberPattern>[48]0\d{6}</nationalNumberPattern>
9449         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9450         <exampleNumber>80123456</exampleNumber>
9451       </noInternationalDialling>
9452       <fixedLine>
9453         <!-- Includes numbers for corporate networks. Note the ITU numbering plan contains a M2M
9454              number in the form of 71\d{10}, which doesn't seem to agree with evidence online. We
9455              keep it as 71\d{7} like before. -->
9456         <nationalNumberPattern>
9457           (?:
9458             1\d|
9459             2(?:
9460               1\d|
9461               [2-9]
9462             )|
9463             3(?:
9464               [2-7]|
9465               8\d
9466             )|
9467             4[24-9]|
9468             5[2-79]|
9469             6[23689]|
9470             7(?:
9471               1\d|
9472               [2-9]
9473             )|
9474             8[2-57-9]|
9475             9[2-69]
9476           )\d{6}
9477         </nationalNumberPattern>
9478         <exampleNumber>12345678</exampleNumber>
9479       </fixedLine>
9480       <mobile>
9481         <nationalNumberPattern>
9482           (?:
9483             [257]0|
9484             3[01]
9485           )\d{7}
9486         </nationalNumberPattern>
9487         <possibleNumberPattern>\d{9}</possibleNumberPattern>
9488         <exampleNumber>201234567</exampleNumber>
9489       </mobile>
9490       <tollFree>
9491         <nationalNumberPattern>80\d{6}</nationalNumberPattern>
9492         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9493         <exampleNumber>80123456</exampleNumber>
9494       </tollFree>
9495       <premiumRate>
9496         <nationalNumberPattern>9[01]\d{6}</nationalNumberPattern>
9497         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9498         <exampleNumber>90123456</exampleNumber>
9499       </premiumRate>
9500       <sharedCost>
9501         <nationalNumberPattern>40\d{6}</nationalNumberPattern>
9502         <possibleNumberPattern>\d{8}</possibleNumberPattern>
9503         <exampleNumber>40123456</exampleNumber>
9504       </sharedCost>
9505     </territory>
9506
9507     <!-- Indonesia -->
9508     <territory id="ID" countryCode="62" internationalPrefix="0(?:0[1789]|10(?:00|1[67]))"
9509                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
9510       <references>
9511         <!-- From 2001, very out of date. -->
9512         <sourceUrl>http://www.itu.int/oth/T0202000064/en</sourceUrl>
9513         <sourceUrl>http://en.wikipedia.org/wiki/%2B62</sourceUrl>
9514       </references>
9515       <availableFormats>
9516         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
9517           pattern="(\d{2})(\d{5,8})">
9518           <leadingDigits>
9519             2[124]|
9520             [36]1
9521           </leadingDigits>
9522           <format>$1 $2</format>
9523         </numberFormat>
9524         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
9525           pattern="(\d{3})(\d{5,8})">
9526           <leadingDigits>
9527             [4579]|
9528             2[035-9]|
9529             [36][02-9]
9530           </leadingDigits>
9531           <format>$1 $2</format>
9532         </numberFormat>
9533         <numberFormat pattern="(8\d{2})(\d{3,4})(\d{3,4})">
9534           <leadingDigits>8[1-35-9]</leadingDigits>
9535           <format>$1-$2-$3</format>
9536         </numberFormat>
9537         <numberFormat pattern="(177)(\d{6,8})">
9538           <leadingDigits>1</leadingDigits>
9539           <format>$1 $2</format>
9540         </numberFormat>
9541         <!-- http://en.wikipedia.org/wiki/Toll-free_telephone_number, and examples on the web show
9542              that sometimes they are followed by less digits. -->
9543         <numberFormat pattern="(800)(\d{5,7})">
9544           <leadingDigits>800</leadingDigits>
9545           <format>$1 $2</format>
9546         </numberFormat>
9547         <numberFormat pattern="(80\d)(\d)(\d{3})(\d{3})">
9548           <leadingDigits>80[79]</leadingDigits>
9549           <format>$1 $2 $3 $4</format>
9550         </numberFormat>
9551       </availableFormats>
9552       <generalDesc>
9553         <nationalNumberPattern>[1-9]\d{6,10}</nationalNumberPattern>
9554         <possibleNumberPattern>\d{5,11}</possibleNumberPattern>
9555       </generalDesc>
9556       <fixedLine>
9557         <!-- Area codes taken from wikipedia, with missing ones added from
9558              http://www.telkom.co.id/customer-services/area-and-country-code/?type=area.
9559              We also added 0770 after user feedback because it seems to be used on Bintan island.
9560              Where known, fixed mobile prefixes have been represented as Mobile. -->
9561         <!-- Very short (5/6 digit) local numbers in Jakarta seem to be special cases for various
9562              well known companies (Mc Donalds, KFC etc...). Some of these are listed in:
9563              http://cms.binus.edu/datapage/file/io/Spring2014SE/International_Student_Handbook_BINUS.pdf
9564              There seem to be numbers of this length for area code 22 as well based on numbers found
9565              online. -->
9566         <nationalNumberPattern>
9567           2(?:
9568             1(?:
9569               14\d{3}|
9570               [0-8]\d{6,7}|
9571               500\d{3}|
9572               9\d{6}
9573             )|
9574             2\d{6,8}|
9575             4\d{7,8}
9576           )|
9577           (?:
9578             2(?:
9579               [35][1-4]|
9580               6[0-8]|
9581               7[1-6]|
9582               8\d|
9583               9[1-8]
9584             )|
9585             3(?:
9586               1|
9587               2[1-8]|
9588               3[1-68]|
9589               4[1-3]|
9590               5[1-8]|
9591               6[1-3568]|
9592               7[0-469]|
9593               8\d
9594             )|
9595             4(?:
9596               0[1-589]|
9597               1[01347-9]|
9598               2[0-36-8]|
9599               3[0-24-68]|
9600               43|
9601               5[1-378]|
9602               6[1-5]|
9603               7[134]|
9604               8[1245]
9605             )|
9606             5(?:
9607               1[1-35-9]|
9608               2[25-8]|
9609               3[124-9]|
9610               4[1-3589]|
9611               5[1-46]|
9612               6[1-8]
9613             )|
9614             6(?:
9615               19?|
9616               [25]\d|
9617               3[1-69]|
9618               4[1-6]
9619             )|
9620             7(?:
9621               02|
9622               1[1-9]|
9623               2[1-9]|
9624               [36]\d|
9625               4[1-8]|
9626               5[1-9]|
9627               7[0-36-9]
9628             )|
9629             9(?:
9630               0[12]|
9631               1[013-8]|
9632               2[0-479]|
9633               5[125-8]|
9634               6[23679]|
9635               7[159]|
9636               8[01346]
9637             )
9638           )\d{5,8}
9639         </nationalNumberPattern>
9640         <possibleNumberPattern>\d{5,11}</possibleNumberPattern>
9641         <exampleNumber>612345678</exampleNumber>
9642       </fixedLine>
9643       <mobile>
9644         <!-- It is unclear exactly which prefixes could be mobile phones, based on the information
9645              on the wikipedia page. However, Bakrie have provided a list of their prefixes, which
9646              are captured below. The pattern covers the area code plus the first one-two digits of
9647              the subscriber number. -->
9648         <nationalNumberPattern>
9649           (?:
9650             2(?:
9651               1(?:
9652                 3[145]|
9653                 4[01]|
9654                 5[1-469]|
9655                 60|
9656                 8[0359]|
9657                 9\d
9658               )|
9659               2(?:
9660                 88|
9661                 9[1256]
9662               )|
9663               3[1-4]9|
9664               4(?:
9665                 36|
9666                 91
9667               )|
9668               5(?:
9669                 1[349]|
9670                 [2-4]9
9671               )|
9672               6[0-7]9|
9673               7(?:
9674                 [1-36]9|
9675                 4[39]
9676               )|
9677               8[1-5]9|
9678               9[1-48]9
9679             )|
9680             3(?:
9681               19[1-3]|
9682               2[12]9|
9683               3[13]9|
9684               4(?:
9685                 1[69]|
9686                 39
9687               )|
9688               5[14]9|
9689               6(?:
9690                 1[69]|
9691                 2[89]
9692               )|
9693               709
9694             )|
9695             4[13]19|
9696             5(?:
9697               1(?:
9698                 19|
9699                 8[39]
9700               )|
9701               4[129]9|
9702               6[12]9
9703             )|
9704             6(?:
9705               19[12]|
9706               2(?:
9707                 [23]9|
9708                 77
9709               )
9710             )|
9711             7(?:
9712               1[13]9|
9713               2[15]9|
9714               419|
9715               5(?:
9716                 1[89]|
9717                 29
9718               )|
9719               6[15]9|
9720               7[178]9
9721             )
9722           )\d{5,6}|
9723           8[1-35-9]\d{7,9}
9724         </nationalNumberPattern>
9725         <possibleNumberPattern>\d{9,11}</possibleNumberPattern>
9726         <exampleNumber>812345678</exampleNumber>
9727       </mobile>
9728       <tollFree>
9729         <nationalNumberPattern>
9730           177\d{6,8}|
9731           800\d{5,7}
9732         </nationalNumberPattern>
9733         <possibleNumberPattern>\d{8,11}</possibleNumberPattern>
9734         <exampleNumber>8001234567</exampleNumber>
9735       </tollFree>
9736       <uan>
9737         <nationalNumberPattern>8071\d{6}</nationalNumberPattern>
9738         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9739         <exampleNumber>8071123456</exampleNumber>
9740       </uan>
9741       <noInternationalDialling>
9742         <nationalNumberPattern>8071\d{6}</nationalNumberPattern>
9743         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9744         <exampleNumber>8071123456</exampleNumber>
9745       </noInternationalDialling>
9746       <!-- The information below is provided by an Indonesian -->
9747       <premiumRate>
9748         <nationalNumberPattern>809\d{7}</nationalNumberPattern>
9749         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9750         <exampleNumber>8091234567</exampleNumber>
9751       </premiumRate>
9752     </territory>
9753
9754     <!-- Ireland -->
9755     <territory id="IE" countryCode="353" internationalPrefix="00"
9756                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
9757                mobileNumberPortableRegion="true">
9758       <references>
9759         <sourceUrl>http://www.comreg.ie/licensing_and_services/numbering_plan_for_ireland.552.440.html</sourceUrl>
9760         <sourceUrl>http://www.comreg.ie/_fileupload/publications/ComReg1119.pdf</sourceUrl>
9761       </references>
9762       <availableFormats>
9763         <numberFormat pattern="(1)(\d{3,4})(\d{4})">
9764           <leadingDigits>1</leadingDigits>
9765           <format>$1 $2 $3</format>
9766         </numberFormat>
9767         <numberFormat pattern="(\d{2})(\d{5})">
9768           <leadingDigits>
9769             2[24-9]|
9770             47|
9771             58|
9772             6[237-9]|
9773             9[35-9]
9774           </leadingDigits>
9775           <format>$1 $2</format>
9776         </numberFormat>
9777         <numberFormat pattern="(\d{3})(\d{5})">
9778           <leadingDigits>
9779             40[24]|
9780             50[45]
9781           </leadingDigits>
9782           <format>$1 $2</format>
9783         </numberFormat>
9784         <numberFormat pattern="(48)(\d{4})(\d{4})">
9785           <leadingDigits>48</leadingDigits>
9786           <format>$1 $2 $3</format>
9787         </numberFormat>
9788         <numberFormat pattern="(818)(\d{3})(\d{3})">
9789           <leadingDigits>81</leadingDigits>
9790           <format>$1 $2 $3</format>
9791         </numberFormat>
9792         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})">
9793           <leadingDigits>
9794             [24-69]|
9795             7[14]
9796           </leadingDigits>
9797           <format>$1 $2 $3</format>
9798         </numberFormat>
9799         <numberFormat nationalPrefixFormattingRule="$NP$FG"
9800           pattern="([78]\d)(\d{3,4})(\d{4})">
9801           <leadingDigits>
9802             76|
9803             8[35-9]
9804           </leadingDigits>
9805           <format>$1 $2 $3</format>
9806         </numberFormat>
9807         <numberFormat nationalPrefixFormattingRule="$NP$FG"
9808           pattern="(700)(\d{3})(\d{3})">
9809           <leadingDigits>70</leadingDigits>
9810           <format>$1 $2 $3</format>
9811         </numberFormat>
9812         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{3})(\d{3})">
9813           <leadingDigits>
9814             1(?:
9815               8[059]|
9816               5
9817             )
9818           </leadingDigits>
9819           <leadingDigits>
9820             1(?:
9821               8[059]0|
9822               5
9823             )
9824           </leadingDigits>
9825           <format>$1 $2 $3</format>
9826         </numberFormat>
9827       </availableFormats>
9828       <generalDesc>
9829         <nationalNumberPattern>[124-9]\d{6,9}</nationalNumberPattern>
9830         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
9831       </generalDesc>
9832       <noInternationalDialling>
9833         <nationalNumberPattern>18[59]0\d{6}</nationalNumberPattern>
9834         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9835         <exampleNumber>1850123456</exampleNumber>
9836       </noInternationalDialling>
9837       <fixedLine>
9838         <!-- We allow 6-7 digit subscriber numbers for the 021 area code since that seems to be
9839              reflected by the numbers in the Yellow Pages. Another peculiarity is that 048 actually
9840              replaces 00 44 28 when Irish people dial, allowing them to easily dial Northern
9841              Ireland. We support these numbers here, although technically they are numbers for the
9842              UK. -->
9843         <nationalNumberPattern>
9844           1\d{7,8}|
9845           2(?:
9846             1\d{6,7}|
9847             3\d{7}|
9848             [24-9]\d{5}
9849           )|
9850           4(?:
9851             0[24]\d{5}|
9852             [1-469]\d{7}|
9853             5\d{6}|
9854             7\d{5}|
9855             8[0-46-9]\d{7}
9856           )|
9857           5(?:
9858             0[45]\d{5}|
9859             1\d{6}|
9860             [23679]\d{7}|
9861             8\d{5}
9862           )|
9863           6(?:
9864             1\d{6}|
9865             [237-9]\d{5}|
9866             [4-6]\d{7}
9867           )|
9868           7[14]\d{7}|
9869           9(?:
9870             1\d{6}|
9871             [04]\d{7}|
9872             [35-9]\d{5}
9873           )
9874         </nationalNumberPattern>
9875         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
9876         <exampleNumber>2212345</exampleNumber>
9877       </fixedLine>
9878       <mobile>
9879         <nationalNumberPattern>
9880           8(?:
9881             22\d{6}|
9882             [35-9]\d{7}
9883           )
9884         </nationalNumberPattern>
9885         <possibleNumberPattern>\d{9}</possibleNumberPattern>
9886         <exampleNumber>850123456</exampleNumber>
9887       </mobile>
9888       <tollFree>
9889         <nationalNumberPattern>1800\d{6}</nationalNumberPattern>
9890         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9891         <exampleNumber>1800123456</exampleNumber>
9892       </tollFree>
9893       <premiumRate>
9894         <nationalNumberPattern>
9895           15(?:
9896             1[2-8]|
9897             [2-8]0|
9898             9[089]
9899           )\d{6}
9900         </nationalNumberPattern>
9901         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9902         <exampleNumber>1520123456</exampleNumber>
9903       </premiumRate>
9904       <sharedCost>
9905         <nationalNumberPattern>18[59]0\d{6}</nationalNumberPattern>
9906         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9907         <exampleNumber>1850123456</exampleNumber>
9908       </sharedCost>
9909       <personalNumber>
9910         <nationalNumberPattern>700\d{6}</nationalNumberPattern>
9911         <possibleNumberPattern>\d{9}</possibleNumberPattern>
9912         <exampleNumber>700123456</exampleNumber>
9913       </personalNumber>
9914       <voip>
9915         <nationalNumberPattern>76\d{7}</nationalNumberPattern>
9916         <possibleNumberPattern>\d{9}</possibleNumberPattern>
9917         <exampleNumber>761234567</exampleNumber>
9918       </voip>
9919       <uan>
9920         <nationalNumberPattern>818\d{6}</nationalNumberPattern>
9921         <possibleNumberPattern>\d{9}</possibleNumberPattern>
9922         <exampleNumber>818123456</exampleNumber>
9923       </uan>
9924       <voicemail>
9925         <nationalNumberPattern>8[35-9]\d{8}</nationalNumberPattern>
9926         <possibleNumberPattern>\d{10}</possibleNumberPattern>
9927         <exampleNumber>8501234567</exampleNumber>
9928       </voicemail>
9929     </territory>
9930
9931     <!-- Israel -->
9932     <!-- Formatting practice following wikipedia, and government sites. -->
9933     <territory id="IL" countryCode="972" internationalPrefix="0(?:0|1[2-9])"
9934                nationalPrefix="0" nationalPrefixFormattingRule="$FG"
9935                mobileNumberPortableRegion="true">
9936       <references>
9937         <sourceUrl>http://www.itu.int/oth/T020200006A/en</sourceUrl>
9938         <sourceUrl>http://en.wikipedia.org/wiki/%2B972</sourceUrl>
9939         <!-- in Hebrew -->
9940         <sourceUrl>http://he.wikipedia.org/wiki/%D7%A7%D7%99%D7%93%D7%95%D7%9E%D7%AA_%D7%98%D7%9C%D7%A4%D7%95%D7%9F_%D7%91%D7%99%D7%A9%D7%A8%D7%90%D7%9C</sourceUrl>
9941       </references>
9942       <availableFormats>
9943         <numberFormat nationalPrefixFormattingRule="$NP$FG"
9944           pattern="([2-489])(\d{3})(\d{4})">
9945           <leadingDigits>[2-489]</leadingDigits>
9946           <format>$1-$2-$3</format>
9947         </numberFormat>
9948         <numberFormat nationalPrefixFormattingRule="$NP$FG"
9949           pattern="([57]\d)(\d{3})(\d{4})">
9950           <leadingDigits>[57]</leadingDigits>
9951           <format>$1-$2-$3</format>
9952         </numberFormat>
9953         <numberFormat pattern="(1)([7-9]\d{2})(\d{3})(\d{3})">
9954           <leadingDigits>1[7-9]</leadingDigits>
9955           <format>$1-$2-$3-$4</format>
9956         </numberFormat>
9957         <!-- The following number is for hospitals. -->
9958         <numberFormat pattern="(1255)(\d{3})">
9959           <leadingDigits>125</leadingDigits>
9960           <format>$1-$2</format>
9961         </numberFormat>
9962         <numberFormat pattern="(1200)(\d{3})(\d{3})">
9963           <leadingDigits>120</leadingDigits>
9964           <format>$1-$2-$3</format>
9965         </numberFormat>
9966         <numberFormat pattern="(1212)(\d{2})(\d{2})">
9967           <leadingDigits>121</leadingDigits>
9968           <format>$1-$2-$3</format>
9969         </numberFormat>
9970         <!-- The following is for voicemail access. -->
9971         <numberFormat pattern="(1599)(\d{6})">
9972           <leadingDigits>15</leadingDigits>
9973           <format>$1-$2</format>
9974         </numberFormat>
9975         <!-- These are 4-digit star numbers which are only accessible within Israel and must be
9976              dialed with a star in front of the number. -->
9977         <numberFormat pattern="(\d{4})">
9978           <leadingDigits>[2-689]</leadingDigits>
9979           <format>*$1</format>
9980         </numberFormat>
9981       </availableFormats>
9982       <generalDesc >
9983         <nationalNumberPattern>
9984           [17]\d{6,9}|
9985           [2-589]\d{3}(?:\d{3,6})?|
9986           6\d{3}
9987         </nationalNumberPattern>
9988         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
9989       </generalDesc>
9990       <noInternationalDialling>
9991         <nationalNumberPattern>
9992           1700\d{6}|
9993           [2-689]\d{3}
9994         </nationalNumberPattern>
9995         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
9996         <exampleNumber>1700123456</exampleNumber>
9997       </noInternationalDialling>
9998       <fixedLine>
9999         <nationalNumberPattern>[2-489]\d{7}</nationalNumberPattern>
10000         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
10001         <exampleNumber>21234567</exampleNumber>
10002       </fixedLine>
10003       <mobile>
10004         <!-- The ITU document has only some of these prefixes - wikipedia lists more. We are fairly
10005              sure wikipedia is accurate based on news coverage of the launch of these numbers. Also
10006              added 5570 and 5571 prefixes based on confirmation from the carrier. -->
10007         <nationalNumberPattern>
10008           5(?:
10009             [02347-9]\d{2}|
10010             5(?:
10011               01|
10012               2[23]|
10013               3[34]|
10014               4[45]|
10015               5[5689]|
10016               6[67]|
10017               7[0178]|
10018               [89][7-9]
10019             )|
10020             6[2-9]\d
10021           )\d{5}
10022         </nationalNumberPattern>
10023         <possibleNumberPattern>\d{9}</possibleNumberPattern>
10024         <exampleNumber>501234567</exampleNumber>
10025       </mobile>
10026       <tollFree>
10027         <!-- Online 1-809 numbers now classify themselves as "toll-free". -->
10028         <nationalNumberPattern>
10029           1(?:
10030             80[019]\d{3}|
10031             255
10032           )\d{3}
10033         </nationalNumberPattern>
10034         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
10035         <exampleNumber>1800123456</exampleNumber>
10036       </tollFree>
10037       <premiumRate>
10038           <!-- Peculiarly, one source states that 1956 and 1957 are the new premium rate prefixes.
10039                However, no online numbers starting with these prefixes can be found, and this data
10040                is not found in any other source. -->
10041           <!-- 1200 and 1212 numbers are for televoting. -->
10042         <nationalNumberPattern>
10043           1(?:
10044             212|
10045             (?:
10046               9(?:
10047                 0[01]|
10048                 19
10049               )|
10050               200
10051             )\d{2}
10052           )\d{4}
10053         </nationalNumberPattern>
10054         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
10055         <exampleNumber>1919123456</exampleNumber>
10056       </premiumRate>
10057       <sharedCost>
10058         <nationalNumberPattern>1700\d{6}</nationalNumberPattern>
10059         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10060         <exampleNumber>1700123456</exampleNumber>
10061       </sharedCost>
10062       <voip>
10063         <!-- These rules are a union of the wikipedia and ITU document prefixes. They are mostly
10064              marked as VoIP on wikipedia, but it seems they may indeed be DID (Direct Inward
10065              Dialing) numbers, that most people forward to VoIP numbers. -->
10066         <nationalNumberPattern>
10067           7(?:
10068             2[23]\d|
10069             3[237]\d|
10070             47\d|
10071             6(?:
10072               5\d|
10073               8[068]
10074             )|
10075             7\d{2}|
10076             8(?:
10077               33|
10078               55|
10079               77|
10080               81
10081             )
10082           )\d{5}
10083         </nationalNumberPattern>
10084         <possibleNumberPattern>\d{9}</possibleNumberPattern>
10085         <exampleNumber>771234567</exampleNumber>
10086       </voip>
10087       <uan>
10088         <!-- 4-digit star numbers and 1-599 numbers. The latter are actually labelled "interactive
10089              voicemail" in the ITU document, but according to reports from businesses in Israel and
10090              the Hebrew version of the wikipedia page, these are actually a router for business
10091              calls, and incur a normal call cost on account of the caller. -->
10092         <nationalNumberPattern>
10093           [2-689]\d{3}|
10094           1599\d{6}
10095         </nationalNumberPattern>
10096         <possibleNumberPattern>\d{4}(?:\d{6})?</possibleNumberPattern>
10097         <exampleNumber>1599123456</exampleNumber>
10098       </uan>
10099     </territory>
10100
10101     <!-- Isle of Man -->
10102     <!-- Inherits formatting rules from the UK. -->
10103     <territory id="IM" countryCode="44" internationalPrefix="00"
10104                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG">
10105       <references>
10106         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom</sourceUrl>
10107       </references>
10108       <generalDesc>
10109         <nationalNumberPattern>[135789]\d{6,9}</nationalNumberPattern>
10110         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
10111       </generalDesc>
10112       <areaCodeOptional>
10113         <nationalNumberPattern>1624[2-9]\d{5}</nationalNumberPattern>
10114         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10115         <exampleNumber>1624250123</exampleNumber>
10116       </areaCodeOptional>
10117       <!-- Specific to IM. -->
10118       <fixedLine>
10119         <!-- 1624 with 10 digits. -->
10120         <nationalNumberPattern>1624\d{6}</nationalNumberPattern>
10121         <exampleNumber>1624456789</exampleNumber>
10122       </fixedLine>
10123       <mobile>
10124         <!-- 7524, 7624, 7924 with 10 digits. -->
10125         <nationalNumberPattern>7[569]24\d{6}</nationalNumberPattern>
10126         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10127         <exampleNumber>7924123456</exampleNumber>
10128       </mobile>
10129       <tollFree>
10130         <!-- 808 162 with 10 digits. -->
10131         <nationalNumberPattern>808162\d{4}</nationalNumberPattern>
10132         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10133         <exampleNumber>8081624567</exampleNumber>
10134       </tollFree>
10135       <premiumRate>
10136         <!-- 872 299, 900 624, 901 624, 906 624, 907 624 with 10 digits. -->
10137         <nationalNumberPattern>
10138           (?:
10139             872299|
10140             90[0167]624
10141           )\d{4}
10142         </nationalNumberPattern>
10143         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10144         <exampleNumber>9016247890</exampleNumber>
10145       </premiumRate>
10146       <sharedCost>
10147         <!-- 844 040 6, 844 090 6, 845 624, 870 624 with 10 digits. -->
10148         <nationalNumberPattern>
10149           8(?:
10150             4(?:
10151               40[49]06|
10152               5624\d
10153             )|
10154             70624\d
10155           )\d{3}
10156         </nationalNumberPattern>
10157         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10158         <exampleNumber>8456247890</exampleNumber>
10159       </sharedCost>
10160       <!-- Other numbers as per GB. -->
10161       <personalNumber>
10162         <nationalNumberPattern>70\d{8}</nationalNumberPattern>
10163         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10164         <exampleNumber>7012345678</exampleNumber>
10165       </personalNumber>
10166       <voip>
10167         <nationalNumberPattern>56\d{8}</nationalNumberPattern>
10168         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10169         <exampleNumber>5612345678</exampleNumber>
10170       </voip>
10171       <uan>
10172         <!-- 308 162, 33d, 344 040 6, 344 090 6, 345 624, 370 624, 372 299, 55 with 10 digits. -->
10173         <nationalNumberPattern>
10174           3(?:
10175             08162\d|
10176             3\d{5}|
10177             4(?:
10178               40[49]06|
10179               5624\d
10180             )|
10181             7(?:
10182               0624\d|
10183               2299\d
10184             )
10185           )\d{3}|
10186           55\d{8}
10187         </nationalNumberPattern>
10188         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10189         <exampleNumber>5512345678</exampleNumber>
10190       </uan>
10191     </territory>
10192
10193     <!-- India -->
10194     <!-- Note that several changes in area codes have occurred since the numbering plan was released
10195          - fixed line changes are notified on the http://www.bsnl.co.in website. Area codes can be
10196          verified here at http://dq.ndc.bsnl.co.in/bsnl-web/stdSearch.seam. -->
10197     <territory id="IN" countryCode="91" internationalPrefix="00" nationalPrefix="0"
10198                nationalPrefixFormattingRule="$NP$FG" nationalPrefixOptionalWhenFormatting="true"
10199                mobileNumberPortableRegion="true">
10200       <references>
10201         <sourceUrl>http://www.itu.int/oth/T0202000063/en</sourceUrl>
10202         <sourceUrl>http://en.wikipedia.org/wiki/%2B91</sourceUrl>
10203         <sourceUrl>http://www.coai.in/msccodes.php</sourceUrl>
10204       </references>
10205        <availableFormats>
10206          <!-- Mobile numbers. -->
10207          <numberFormat pattern="(\d{5})(\d{5})">
10208            <leadingDigits>
10209              7(?:
10210                0[2-9]|
10211                2[0579]|
10212                3[057-9]|
10213                4[0-389]|
10214                6[0-35-9]|
10215                [57]|
10216                8[0-79]
10217              )|
10218              8(?:
10219                0[015689]|
10220                1[0-57-9]|
10221                2[2356-9]|
10222                3[0-57-9]|
10223                [45]|
10224                6[02457-9]|
10225                7[1-69]|
10226                8[0124-9]|
10227                9[02-9]
10228              )|
10229              9
10230            </leadingDigits>
10231            <leadingDigits>
10232              7(?:
10233                0(?:
10234                  2[2-9]|
10235                  [3-8]|
10236                  9[0-8]
10237                )|
10238                2(?:
10239                  0[04-9]|
10240                  5[09]|
10241                  7[5-8]|
10242                  9[389]
10243                )|
10244                3(?:
10245                  0[1-9]|
10246                  [58]|
10247                  7[3679]|
10248                  9[689]
10249                )|
10250                4(?:
10251                  0[1-9]|
10252                  1[15-9]|
10253                  [29][89]|
10254                  39|
10255                  8[389]
10256                )|
10257                5(?:
10258                  [034678]|
10259                  2[03-9]|
10260                  5[017-9]|
10261                  9[7-9]
10262                )|
10263                6(?:
10264                  0[0-27]|
10265                  1[0-257-9]|
10266                  2[0-4]|
10267                  3[19]|
10268                  5[4589]|
10269                  [6-9]
10270                )|
10271                7(?:
10272                  0[2-9]|
10273                  [1-79]|
10274                  8[1-9]
10275                )|
10276                8(?:
10277                  [0-7]|
10278                  9[013-9]
10279                )
10280              )|
10281              8(?:
10282                0(?:
10283                  [01589]|
10284                  6[67]
10285                )|
10286                1(?:
10287                  [02-589]|
10288                  1[0135-9]|
10289                  7[0-79]
10290                )|
10291                2(?:
10292                  [236-9]|
10293                  5[1-9]
10294                )|
10295                3(?:
10296                  [0357-9]|
10297                  4[1-9]
10298                )|
10299                [45]|
10300                6[02457-9]|
10301                7[1-69]|
10302                8(?:
10303                  [0-26-9]|
10304                  44|
10305                  5[2-9]
10306                )|
10307                9(?:
10308                  [035-9]|
10309                  2[2-9]|
10310                  4[0-8]
10311                )
10312              )|
10313              9
10314            </leadingDigits>
10315            <format>$1 $2</format>
10316          </numberFormat>
10317          <!-- 2 digits area code -->
10318          <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
10319            <leadingDigits>
10320              11|
10321              2[02]|
10322              33|
10323              4[04]|
10324              79|
10325              80[2-46]
10326            </leadingDigits>
10327            <format>$1 $2 $3</format>
10328          </numberFormat>
10329          <!-- 3 digit area codes that don't clash with mobile patterns. -->
10330          <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
10331            <leadingDigits>
10332              1(?:
10333                2[0-249]|
10334                3[0-25]|
10335                4[145]|
10336                [569][14]|
10337                7[1257]|
10338                8[1346]|
10339                [68][1-9]
10340              )|
10341              2(?:
10342                1[257]|
10343                3[013]|
10344                4[01]|
10345                5[0137]|
10346                6[0158]|
10347                78|
10348                8[1568]|
10349                9[14]
10350              )|
10351              3(?:
10352                26|
10353                4[1-3]|
10354                5[34]|
10355                6[01489]|
10356                7[02-46]|
10357                8[159]
10358              )|
10359              4(?:
10360                1[36]|
10361                2[1-47]|
10362                3[15]|
10363                5[12]|
10364                6[0-26-9]|
10365                7[0-24-9]|
10366                8[013-57]|
10367                9[014-7]
10368              )|
10369              5(?:
10370                [136][25]|
10371                22|
10372                4[28]|
10373                5[12]|
10374                [78]1|
10375                9[15]
10376              )|
10377              6(?:
10378                12|
10379                [2345]1|
10380                57|
10381                6[13]|
10382                7[14]|
10383                80
10384              )
10385            </leadingDigits>
10386            <format>$1 $2 $3</format>
10387          </numberFormat>
10388          <!-- Three-digit area codes that potentially overlap with mobile. -->
10389          <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
10390            <leadingDigits>
10391              7(?:
10392                12|
10393                2[14]|
10394                3[134]|
10395                4[47]|
10396                5[15]|
10397                [67]1|
10398                88
10399              )
10400            </leadingDigits>
10401            <leadingDigits>
10402              7(?:
10403                12|
10404                2[14]|
10405                3[134]|
10406                4[47]|
10407                5(?:
10408                  1|
10409                  5[2-6]
10410                )|
10411                [67]1|
10412                88
10413              )
10414            </leadingDigits>
10415            <format>$1 $2 $3</format>
10416          </numberFormat>
10417          <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
10418            <leadingDigits>
10419              8(?:
10420                16|
10421                2[014]|
10422                3[126]|
10423                6[136]|
10424                7[078]|
10425                8[34]|
10426                91
10427              )
10428            </leadingDigits>
10429            <format>$1 $2 $3</format>
10430          </numberFormat>
10431          <!-- 4 digits area code -->
10432          <!-- Fallback for fixed-line numbers. -->
10433          <numberFormat pattern="(\d{4})(\d{3})(\d{3})">
10434            <leadingDigits>
10435              1(?:
10436                [23579]|
10437                [468][1-9]
10438              )|
10439              [2-8]
10440            </leadingDigits>
10441            <format>$1 $2 $3</format>
10442          </numberFormat>
10443          <numberFormat nationalPrefixFormattingRule="$FG"
10444            pattern="(1600)(\d{2})(\d{4})">
10445            <leadingDigits>160</leadingDigits>
10446            <leadingDigits>1600</leadingDigits>
10447            <format>$1 $2 $3</format>
10448          </numberFormat>
10449          <numberFormat nationalPrefixFormattingRule="$FG"
10450            pattern="(1800)(\d{4,5})">
10451            <leadingDigits>180</leadingDigits>
10452            <leadingDigits>1800</leadingDigits>
10453            <format>$1 $2</format>
10454          </numberFormat>
10455          <numberFormat nationalPrefixFormattingRule="$FG"
10456            pattern="(18[06]0)(\d{2,4})(\d{4})">
10457            <leadingDigits>18[06]</leadingDigits>
10458            <leadingDigits>18[06]0</leadingDigits>
10459            <format>$1 $2 $3</format>
10460          </numberFormat>
10461          <numberFormat nationalPrefixFormattingRule="$FG"
10462            pattern="(140)(\d{3})(\d{4})">
10463            <leadingDigits>140</leadingDigits>
10464            <format>$1 $2 $3</format>
10465          </numberFormat>
10466          <!-- Televoting numbers. Formatting information is from
10467               http://www.bsnl.co.in/service/telev.htm -->
10468          <numberFormat nationalPrefixFormattingRule="$FG"
10469            pattern="(\d{4})(\d{3})(\d{3})(\d{3})">
10470            <leadingDigits>18[06]</leadingDigits>
10471            <leadingDigits>
10472              18(?:
10473                0[03]|
10474                6[12]
10475              )
10476            </leadingDigits>
10477            <format>$1 $2 $3 $4</format>
10478          </numberFormat>
10479       </availableFormats>
10480       <generalDesc>
10481         <nationalNumberPattern>
10482           1\d{7,12}|
10483           [2-9]\d{9,10}
10484         </nationalNumberPattern>
10485         <possibleNumberPattern>\d{6,13}</possibleNumberPattern>
10486       </generalDesc>
10487       <noInternationalDialling>
10488         <nationalNumberPattern>
10489           1(?:
10490             600\d{6}|
10491             8(?:
10492               0(?:
10493                 0\d{4,9}|
10494                 3\d{9}
10495               )|
10496               6(?:
10497                 0\d{7}|
10498                 [12]\d{9}
10499               )
10500             )
10501           )
10502         </nationalNumberPattern>
10503         <possibleNumberPattern>\d{8,13}</possibleNumberPattern>
10504         <exampleNumber>1800123456</exampleNumber>
10505       </noInternationalDialling>
10506       <fixedLine>
10507         <!-- This is a list of the 2 and 3 digit area codes and the first 3 digits of 4 digit area
10508              codes, so we can check the following digit belongs to one of the operator-codes (2-7).
10509              Operator codes are from wikipedia, with the addition of 5 (HFCL Infotel in some areas).
10510              Not all operator codes are available in all areas, but we don't maintain that
10511              distinction here.
10512              Area codes starting with a 7 are listed separately, since the prefixes need to be more
10513              detailed so they clash less with mobile phone prefixes. -->
10514         <nationalNumberPattern>
10515           (?:
10516             11|
10517             2[02]|
10518             33|
10519             4[04]|
10520             79
10521           )[2-7]\d{7}|
10522           80[2-467]\d{7}|
10523           (?:
10524             1(?:
10525               2[0-249]|
10526               3[0-25]|
10527               4[145]|
10528               [59][14]|
10529               6[014]|
10530               7[1257]|
10531               8[01346]
10532             )|
10533             2(?:
10534               1[257]|
10535               3[013]|
10536               4[01]|
10537               5[0137]|
10538               6[0158]|
10539               78|
10540               8[1568]|
10541               9[14]
10542             )|
10543             3(?:
10544               26|
10545               4[1-3]|
10546               5[34]|
10547               6[01489]|
10548               7[02-46]|
10549               8[159]
10550             )|
10551             4(?:
10552               1[36]|
10553               2[1-47]|
10554               3[15]|
10555               5[12]|
10556               6[0-26-9]|
10557               7[0-24-9]|
10558               8[013-57]|
10559               9[014-7]
10560             )|
10561             5(?:
10562               [136][25]|
10563               22|
10564               4[28]|
10565               5[12]|
10566               [78]1|
10567               9[15]
10568             )|
10569             6(?:
10570               12|
10571               [2345]1|
10572               57|
10573               6[13]|
10574               7[14]|
10575               80
10576             )|
10577             7(?:
10578               12|
10579               2[14]|
10580               3[134]|
10581               4[47]|
10582               5[15]|
10583               [67]1|
10584               88
10585             )|
10586             8(?:
10587               16|
10588               2[014]|
10589               3[126]|
10590               6[136]|
10591               7[078]|
10592               8[34]|
10593               91
10594             )
10595           )[2-7]\d{6}|
10596           (?:
10597             (?:
10598               1(?:
10599                 2[35-8]|
10600                 3[346-9]|
10601                 4[236-9]|
10602                 [59][0235-9]|
10603                 6[235-9]|
10604                 7[34689]|
10605                 8[257-9]
10606               )|
10607               2(?:
10608                 1[134689]|
10609                 3[24-8]|
10610                 4[2-8]|
10611                 5[25689]|
10612                 6[2-4679]|
10613                 7[13-79]|
10614                 8[2-479]|
10615                 9[235-9]
10616               )|
10617               3(?:
10618                 01|
10619                 1[79]|
10620                 2[1-5]|
10621                 4[25-8]|
10622                 5[125689]|
10623                 6[235-7]|
10624                 7[157-9]|
10625                 8[2-467]
10626               )|
10627               4(?:
10628                 1[14578]|
10629                 2[5689]|
10630                 3[2-467]|
10631                 5[4-7]|
10632                 6[35]|
10633                 73|
10634                 8[2689]|
10635                 9[2389]
10636               )|
10637               5(?:
10638                 [16][146-9]|
10639                 2[14-8]|
10640                 3[1346]|
10641                 4[14-69]|
10642                 5[46]|
10643                 7[2-4]|
10644                 8[2-8]|
10645                 9[246]
10646               )|
10647               6(?:
10648                 1[1358]|
10649                 2[2457]|
10650                 3[2-4]|
10651                 4[235-7]|
10652                 [57][2-689]|
10653                 6[24-578]|
10654                 8[1-6]
10655               )|
10656               8(?:
10657                 1[1357-9]|
10658                 2[235-8]|
10659                 3[03-57-9]|
10660                 4[0-24-9]|
10661                 5\d|
10662                 6[2457-9]|
10663                 7[1-6]|
10664                 8[1256]|
10665                 9[2-4]
10666               )
10667             )\d|
10668             7(?:
10669               (?:
10670                 1[013-9]|
10671                 2[0235-9]|
10672                 3[2679]|
10673                 4[1-35689]|
10674                 5[2-46-9]|
10675                 [67][02-9]|
10676                 9\d
10677               )\d|
10678               8(?:
10679                 2[0-6]|
10680                 [013-8]\d
10681               )
10682             )
10683           )[2-7]\d{5}
10684         </nationalNumberPattern>
10685         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
10686         <exampleNumber>1123456789</exampleNumber>
10687       </fixedLine>
10688       <!-- http://en.wikipedia.org/wiki/Mobile_telephone_numbering_in_India -->
10689       <!-- The document titled "List of MSC codes" linked off
10690            http://www.dot.gov.in/access-services/national-numbering-plan-2003 was helpful but last
10691            updated 2012 - more updates at http://www.dot.gov.in/access-services/allotment-msc-codes. -->
10692       <mobile>
10693         <!-- A couple of additional prefixes found neither on the wikipedia page nor in the MSC
10694              codes list, are added because SMS messages have been successfully sent to these
10695              numbers. It seems almost impossible to know for some of these numbers whether they are
10696              land-line or mobile, since the ranges overlap. Extra prefixes added: 7601, 768[567],
10697              7695, 8299, 8309. New prefixes were also added based on the document provided from
10698              mobile carriers: https://github.com/googlei18n/libphonenumber/issues/260 -->
10699         <nationalNumberPattern>
10700           (?:
10701             7(?:
10702               0(?:
10703                 2[2-9]|
10704                 [3-8]\d|
10705                 9[0-8]
10706               )|
10707               2(?:
10708                 0[04-9]|
10709                 5[09]|
10710                 7[5-8]|
10711                 9[389]
10712               )|
10713               3(?:
10714                 0[1-9]|
10715                 [58]\d|
10716                 7[3679]|
10717                 9[689]
10718               )|
10719               4(?:
10720                 0[1-9]|
10721                 1[15-9]|
10722                 [29][89]|
10723                 39|
10724                 8[389]
10725               )|
10726               5(?:
10727                 [034678]\d|
10728                 2[03-9]|
10729                 5[017-9]|
10730                 9[7-9]
10731               )|
10732               6(?:
10733                 0[0127]|
10734                 1[0-257-9]|
10735                 2[0-4]|
10736                 3[19]|
10737                 5[4589]|
10738                 [6-9]\d
10739               )|
10740               7(?:
10741                 0[2-9]|
10742                 [1-79]\d|
10743                 8[1-9]
10744               )|
10745               8(?:
10746                 [0-7]\d|
10747                 9[013-9]
10748               )
10749             )|
10750             8(?:
10751               0(?:
10752                 [01589]\d|
10753                 6[67]
10754               )|
10755               1(?:
10756                 [02-589]\d|
10757                 1[0135-9]|
10758                 7[0-79]
10759               )|
10760               2(?:
10761                 [236-9]\d|
10762                 5[1-9]
10763               )|
10764               3(?:
10765                 [0357-9]\d|
10766                 4[1-9]
10767               )|
10768               [45]\d{2}|
10769               6[02457-9]\d|
10770               7[1-69]\d|
10771               8(?:
10772                 [0-26-9]\d|
10773                 44|
10774                 5[2-9]
10775               )|
10776               9(?:
10777                 [035-9]\d|
10778                 2[2-9]|
10779                 4[0-8]
10780               )
10781             )|
10782             9\d{3}
10783           )\d{6}
10784         </nationalNumberPattern>
10785         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10786         <exampleNumber>9123456789</exampleNumber>
10787       </mobile>
10788       <tollFree>
10789         <!-- Information gathered from sites such as
10790              http://www.surfindia.com/india-facts/toll-free-no.html and
10791              http://indmusings.blogspot.com/2008/09/free-help-line-numbersindia.html
10792              http://www.bsnl.co.in/service/telev.htm -->
10793         <nationalNumberPattern>
10794           1(?:
10795             600\d{6}|
10796             80(?:
10797               0\d{4,9}|
10798               3\d{9}
10799             )
10800           )
10801         </nationalNumberPattern>
10802         <possibleNumberPattern>\d{8,13}</possibleNumberPattern>
10803         <exampleNumber>1800123456</exampleNumber>
10804       </tollFree>
10805       <premiumRate>
10806         <!-- Only televoting numbers are covered here for now. The 900 numbers are not covered
10807              because they overlap with mobile, and we haven't found any real numbers online. -->
10808         <nationalNumberPattern>186[12]\d{9}</nationalNumberPattern>
10809         <possibleNumberPattern>\d{13}</possibleNumberPattern>
10810         <exampleNumber>1861123456789</exampleNumber>
10811       </premiumRate>
10812       <sharedCost>
10813         <!-- While described as "universal numbers" in the numbering plan, evidence suggests
10814              that 1860 number are best described as shared cost. See "Call Local Service" in:
10815              http://www.tatadocomo.com/corporates/toll-free.aspx -->
10816         <nationalNumberPattern>1860\d{7}</nationalNumberPattern>
10817         <possibleNumberPattern>\d{11}</possibleNumberPattern>
10818         <exampleNumber>18603451234</exampleNumber>
10819       </sharedCost>
10820       <uan>
10821         <!-- Telemarketing numbers: http://en.wikipedia.org/wiki/Telephone_numbers_in_India -->
10822         <nationalNumberPattern>140\d{7}</nationalNumberPattern>
10823         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10824         <exampleNumber>1409305260</exampleNumber>
10825       </uan>
10826     </territory>
10827
10828     <!-- British Indian Ocean Territory / Diego Garcia -->
10829     <territory id="IO" countryCode="246" internationalPrefix="00">
10830       <references>
10831         <sourceUrl>http://www.itu.int/oth/T0202000039/en</sourceUrl>
10832       </references>
10833       <availableFormats>
10834         <numberFormat pattern="(\d{3})(\d{4})">
10835           <format>$1 $2</format>
10836         </numberFormat>
10837       </availableFormats>
10838       <generalDesc>
10839         <nationalNumberPattern>3\d{6}</nationalNumberPattern>
10840         <possibleNumberPattern>\d{7}</possibleNumberPattern>
10841       </generalDesc>
10842       <fixedLine>
10843         <nationalNumberPattern>37\d{5}</nationalNumberPattern>
10844         <exampleNumber>3709100</exampleNumber>
10845       </fixedLine>
10846       <mobile>
10847         <nationalNumberPattern>38\d{5}</nationalNumberPattern>
10848         <exampleNumber>3801234</exampleNumber>
10849       </mobile>
10850     </territory>
10851
10852     <!-- Iraq -->
10853     <territory id="IQ" countryCode="964" internationalPrefix="00"
10854                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
10855       <references>
10856         <sourceUrl>http://en.wikipedia.org/wiki/%2B964</sourceUrl>
10857         <sourceUrl>http://wtng.info/wtng-964-ik.html</sourceUrl>
10858       </references>
10859       <availableFormats>
10860         <numberFormat pattern="(1)(\d{3})(\d{4})">
10861           <leadingDigits>1</leadingDigits>
10862           <format>$1 $2 $3</format>
10863         </numberFormat>
10864         <numberFormat pattern="([2-6]\d)(\d{3})(\d{3,4})">
10865           <leadingDigits>[2-6]</leadingDigits>
10866           <format>$1 $2 $3</format>
10867         </numberFormat>
10868         <numberFormat pattern="(7\d{2})(\d{3})(\d{4})">
10869           <leadingDigits>7</leadingDigits>
10870           <format>$1 $2 $3</format>
10871         </numberFormat>
10872       </availableFormats>
10873       <generalDesc>
10874         <nationalNumberPattern>[1-7]\d{7,9}</nationalNumberPattern>
10875         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
10876       </generalDesc>
10877       <fixedLine>
10878         <nationalNumberPattern>
10879           1\d{7}|
10880           (?:
10881             2[13-5]|
10882             3[02367]|
10883             4[023]|
10884             5[03]|
10885             6[026]
10886           )\d{6,7}
10887         </nationalNumberPattern>
10888         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
10889         <exampleNumber>12345678</exampleNumber>
10890       </fixedLine>
10891       <mobile>
10892         <nationalNumberPattern>7[3-9]\d{8}</nationalNumberPattern>
10893         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10894         <exampleNumber>7912345678</exampleNumber>
10895       </mobile>
10896       <!-- No tollFree or premiumRate information can be found. -->
10897     </territory>
10898
10899     <!-- Iran, Islamic Republic of -->
10900     <territory id="IR" countryCode="98" internationalPrefix="00"
10901                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
10902       <references>
10903         <sourceUrl>http://en.wikipedia.org/wiki/%2B98</sourceUrl>
10904         <sourceUrl>http://www.itu.int/oth/T0202000066/en</sourceUrl>
10905         <sourceUrl>http://www.tct.ir/?siteid=1&amp;pageid=195</sourceUrl>
10906         <sourceUrl>http://118.tct.ir/citycode.htm</sourceUrl>
10907       </references>
10908       <availableFormats>
10909         <!-- Formatting follows wikipedia. -->
10910         <numberFormat pattern="(21)(\d{3,5})">
10911           <leadingDigits>21</leadingDigits>
10912           <format>$1 $2</format>
10913         </numberFormat>
10914         <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
10915           <leadingDigits>[1-8]</leadingDigits>
10916           <format>$1 $2 $3</format>
10917         </numberFormat>
10918         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
10919           <leadingDigits>9</leadingDigits>
10920           <format>$1 $2 $3</format>
10921         </numberFormat>
10922         <numberFormat pattern="(\d{3})(\d{2})(\d{2,3})">
10923           <leadingDigits>9</leadingDigits>
10924           <format>$1 $2 $3</format>
10925         </numberFormat>
10926         <numberFormat pattern="(\d{3})(\d{3})">
10927           <leadingDigits>9</leadingDigits>
10928           <format>$1 $2</format>
10929         </numberFormat>
10930       </availableFormats>
10931       <generalDesc>
10932         <nationalNumberPattern>
10933           [1-8]\d{9}|
10934           9(?:
10935             [0-4]\d{8}|
10936             9\d{2,8}
10937           )
10938         </nationalNumberPattern>
10939         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
10940       </generalDesc>
10941       <fixedLine>
10942         <!-- In Summer 2014 Iran unified all fixed phone numbers in the following way:
10943              Each province is assigned a two digit prefix (except for North Khorasan which has 3).
10944              Within each province, all numbers are exactly eight digits.  The expression below is
10945              organized by province.  For each province we accept all eight-digit combinations.
10946
10947              11 Mazandaran
10948              13 Gilan
10949              17 Golestan
10950              21 Tehran
10951              23 Semnan
10952              24 Zanjan
10953              25 Qom
10954              26 Alborz
10955              28 Qazvin
10956              31 Isfahan
10957              34 Kerman
10958              35 Yazd
10959              38 Chahar Mahaal and Bakhtiari
10960              41 East Azerbaijan
10961              44 West Azerbaijan
10962              45 Ardabil
10963              51 Razavi Khorasan
10964              54 Sistan and Baluchestan
10965              56 South Khorasan
10966              57 North Khorasan (Extras)
10967              58 North Khorasan
10968              61 Khuzestan
10969              64 North Khorasan (Extras)
10970              66 Lorestan
10971              71 Fars
10972              74 Kohgiluyeh and Boyer-Ahmad
10973              76 Hormozgan
10974              77 Bushehr
10975              81 Hamadan
10976              83 Kermanshah
10977              84 Ilam
10978              86 Markazi
10979              87 Kurdistan
10980              -->
10981         <nationalNumberPattern>
10982           (?:
10983             1[137]|
10984             2[13-68]|
10985             3[1458]|
10986             4[145]|
10987             5[146-8]|
10988             6[146]|
10989             7[1467]|
10990             8[13467]
10991           )\d{8}
10992         </nationalNumberPattern>
10993         <possibleNumberPattern>\d{10}</possibleNumberPattern>
10994         <exampleNumber>2123456789</exampleNumber>
10995       </fixedLine>
10996       <mobile>
10997         <nationalNumberPattern>
10998           9(?:
10999             0[12]|
11000             [1-3]\d
11001           )\d{7}
11002         </nationalNumberPattern>
11003         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11004         <exampleNumber>9123456789</exampleNumber>
11005       </mobile>
11006       <pager>
11007         <nationalNumberPattern>943\d{7}</nationalNumberPattern>
11008         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11009         <exampleNumber>9432123456</exampleNumber>
11010       </pager>
11011       <!-- No tollFree or premiumRate information can be found. -->
11012       <voip>
11013         <!-- Includes VSAT and Boomehen Satellite numbers. -->
11014         <nationalNumberPattern>
11015           (?:
11016             [2-6]0\d|
11017             993
11018           )\d{7}
11019         </nationalNumberPattern>
11020         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11021         <exampleNumber>9932123456</exampleNumber>
11022       </voip>
11023       <uan>
11024         <!-- MCI Public Relations numbers -->
11025         <nationalNumberPattern>9990\d{0,6}</nationalNumberPattern>
11026         <exampleNumber>9990123456</exampleNumber>
11027       </uan>
11028     </territory>
11029
11030     <!-- Iceland -->
11031     <territory id="IS" countryCode="354" internationalPrefix="00" mobileNumberPortableRegion="true">
11032       <references>
11033         <sourceUrl>http://www.pta.is/default.aspx?cat_id=85</sourceUrl>
11034         <sourceUrl>http://www.pfs.is/default.aspx?cat_id=14&amp;module_id=210&amp;element_id=4</sourceUrl>
11035       </references>
11036       <availableFormats>
11037         <numberFormat pattern="(\d{3})(\d{4})">
11038           <leadingDigits>[4-9]</leadingDigits>
11039           <format>$1 $2</format>
11040         </numberFormat>
11041         <numberFormat pattern="(3\d{2})(\d{3})(\d{3})">
11042           <leadingDigits>3</leadingDigits>
11043           <format>$1 $2 $3</format>
11044         </numberFormat>
11045       </availableFormats>
11046       <generalDesc>
11047         <nationalNumberPattern>
11048           [4-9]\d{6}|
11049           38\d{7}
11050         </nationalNumberPattern>
11051         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
11052       </generalDesc>
11053       <fixedLine>
11054         <!-- Including 87[23] XXXX here as it is listed as a fax number. -->
11055         <nationalNumberPattern>
11056           (?:
11057             4(?:
11058               1[0-24-6]|
11059               2[0-7]|
11060               [37][0-8]|
11061               4[0-245]|
11062               5[0-3568]|
11063               6\d|
11064               8[0-36-8]
11065             )|
11066             5(?:
11067               05|
11068               [156]\d|
11069               2[02578]|
11070               3[013-7]|
11071               4[03-7]|
11072               7[0-2578]|
11073               8[0-35-9]|
11074               9[013-689]
11075             )|
11076             87[23]
11077           )\d{4}
11078         </nationalNumberPattern>
11079         <possibleNumberPattern>\d{7}</possibleNumberPattern>
11080         <exampleNumber>4101234</exampleNumber>
11081       </fixedLine>
11082       <mobile>
11083         <!-- TETRA = TErrestrial Trunked RAdio is included under mobile. -->
11084         <nationalNumberPattern>
11085           38[589]\d{6}|
11086           (?:
11087             6(?:
11088               1[1-8]|
11089               3[089]|
11090               4[0167]|
11091               5[019]|
11092               [67][0-69]|
11093               9\d
11094             )|
11095             7(?:
11096               5[057]|
11097               7\d|
11098               8[0-36-8]
11099             )|
11100             8(?:
11101               2[0-5]|
11102               3[0-4]|
11103               [469]\d|
11104               5[1-9]
11105             )
11106           )\d{4}
11107         </nationalNumberPattern>
11108         <exampleNumber>6111234</exampleNumber>
11109       </mobile>
11110       <tollFree>
11111         <!-- The UIFN numbers mentioned in the Excel document are not yet included since no real
11112              numbers can be found online, and it is not clear what these are; the standard
11113              definition would have them under the +800 country code instead of Iceland. -->
11114         <nationalNumberPattern>800\d{4}</nationalNumberPattern>
11115         <possibleNumberPattern>\d{7}</possibleNumberPattern>
11116         <exampleNumber>8001234</exampleNumber>
11117       </tollFree>
11118       <premiumRate>
11119         <nationalNumberPattern>90\d{5}</nationalNumberPattern>
11120         <possibleNumberPattern>\d{7}</possibleNumberPattern>
11121         <exampleNumber>9011234</exampleNumber>
11122       </premiumRate>
11123       <voip>
11124         <nationalNumberPattern>49\d{5}</nationalNumberPattern>
11125         <possibleNumberPattern>\d{7}</possibleNumberPattern>
11126         <exampleNumber>4921234</exampleNumber>
11127       </voip>
11128       <voicemail>
11129         <nationalNumberPattern>
11130           (?:
11131             6(?:
11132               2[0-8]|
11133               49|
11134               8\d
11135             )|
11136             87[0189]|
11137             95[48]
11138           )\d{4}
11139         </nationalNumberPattern>
11140         <possibleNumberPattern>\d{7}</possibleNumberPattern>
11141         <exampleNumber>6201234</exampleNumber>
11142       </voicemail>
11143     </territory>
11144
11145     <!-- Italy -->
11146     <territory id="IT" countryCode="39" internationalPrefix="00" leadingZeroPossible="true"
11147                mobileNumberPortableRegion="true">
11148       <references>
11149         <sourceUrl>http://en.wikipedia.org/wiki/%2B39</sourceUrl>
11150       </references>
11151       <availableFormats>
11152         <!-- The leading zero for fixed numbers will be prepended before the matching of these
11153              regular expressions. -->
11154         <numberFormat pattern="(\d{2})(\d{3,4})(\d{4})">
11155           <leadingDigits>
11156             0[26]|
11157             55
11158           </leadingDigits>
11159           <format>$1 $2 $3</format>
11160         </numberFormat>
11161         <numberFormat pattern="(0[26])(\d{4})(\d{5})">
11162           <leadingDigits>0[26]</leadingDigits>
11163           <format>$1 $2 $3</format>
11164         </numberFormat>
11165         <numberFormat pattern="(0[26])(\d{4,6})">
11166           <leadingDigits>0[26]</leadingDigits>
11167           <format>$1 $2</format>
11168         </numberFormat>
11169         <numberFormat pattern="(0\d{2})(\d{3,4})(\d{4})">
11170           <leadingDigits>0[13-57-9][0159]</leadingDigits>
11171           <format>$1 $2 $3</format>
11172         </numberFormat>
11173         <numberFormat pattern="(\d{3})(\d{3,6})">
11174           <leadingDigits>
11175             0[13-57-9][0159]|
11176             8(?:
11177               03|
11178               4[17]|
11179               9[245]
11180             )
11181           </leadingDigits>
11182           <leadingDigits>
11183             0[13-57-9][0159]|
11184             8(?:
11185               03|
11186               4[17]|
11187               9(?:
11188                 2|
11189                 [45][0-4]
11190               )
11191             )
11192           </leadingDigits>
11193           <format>$1 $2</format>
11194         </numberFormat>
11195         <numberFormat pattern="(0\d{3})(\d{3})(\d{4})">
11196           <leadingDigits>0[13-57-9][2-46-8]</leadingDigits>
11197           <format>$1 $2 $3</format>
11198         </numberFormat>
11199         <numberFormat pattern="(0\d{3})(\d{2,6})">
11200           <leadingDigits>0[13-57-9][2-46-8]</leadingDigits>
11201           <format>$1 $2</format>
11202         </numberFormat>
11203         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
11204           <leadingDigits>
11205             [13]|
11206             8(?:
11207               00|
11208               4[08]|
11209               9[59]
11210             )
11211           </leadingDigits>
11212           <leadingDigits>
11213             [13]|
11214             8(?:
11215               00|
11216               4[08]|
11217               9(?:
11218                 5[5-9]|
11219                 9
11220               )
11221             )
11222           </leadingDigits>
11223           <format>$1 $2 $3</format>
11224         </numberFormat>
11225         <numberFormat pattern="(\d{4})(\d{4})">
11226           <leadingDigits>894</leadingDigits>
11227           <leadingDigits>894[5-9]</leadingDigits>
11228           <format>$1 $2</format>
11229         </numberFormat>
11230         <numberFormat pattern="(\d{3})(\d{4})(\d{4})">
11231           <leadingDigits>3</leadingDigits>
11232           <format>$1 $2 $3</format>
11233         </numberFormat>
11234       </availableFormats>
11235       <generalDesc>
11236         <nationalNumberPattern>
11237           [01589]\d{5,10}|
11238           3(?:
11239             [12457-9]\d{8}|
11240             [36]\d{7,9}
11241           )
11242         </nationalNumberPattern>
11243         <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
11244       </generalDesc>
11245       <noInternationalDialling>
11246         <nationalNumberPattern>848\d{6}</nationalNumberPattern>
11247         <possibleNumberPattern>\d{9}</possibleNumberPattern>
11248         <exampleNumber>848123456</exampleNumber>
11249       </noInternationalDialling>
11250       <fixedLine>
11251         <!-- Maximum lengths in the ITU document are 10, but it states above that for numbers
11252              starting with 01, the maximum length is in fact 11. In fact, online, numbers can be
11253              found with other prefixes that are 11 digits long as well, so we allow it for all the
11254              three and four digit area codes. -->
11255         <nationalNumberPattern>
11256           0(?:
11257             [26]\d{4,9}|
11258             (?:
11259               1(?:
11260                 [0159]\d|
11261                 [27][1-5]|
11262                 31|
11263                 4[1-4]|
11264                 6[1356]|
11265                 8[2-57]
11266               )|
11267               3(?:
11268                 [0159]\d|
11269                 2[1-4]|
11270                 3[12]|
11271                 [48][1-6]|
11272                 6[2-59]|
11273                 7[1-7]
11274               )|
11275               4(?:
11276                 [0159]\d|
11277                 [23][1-9]|
11278                 4[245]|
11279                 6[1-5]|
11280                 7[1-4]|
11281                 81
11282               )|
11283               5(?:
11284                 [0159]\d|
11285                 2[1-5]|
11286                 3[2-6]|
11287                 4[1-79]|
11288                 6[4-6]|
11289                 7[1-578]|
11290                 8[3-8]
11291               )|
11292               7(?:
11293                 [0159]\d|
11294                 2[12]|
11295                 3[1-7]|
11296                 4[2346]|
11297                 6[13569]|
11298                 7[13-6]|
11299                 8[1-59]
11300               )|
11301               8(?:
11302                 [0159]\d|
11303                 2[34578]|
11304                 3[1-356]|
11305                 [6-8][1-5]
11306               )|
11307               9(?:
11308                 [0159]\d|
11309                 [238][1-5]|
11310                 4[12]|
11311                 6[1-8]|
11312                 7[1-6]
11313               )
11314             )\d{2,7}
11315           )
11316         </nationalNumberPattern>
11317         <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
11318         <exampleNumber>0212345678</exampleNumber>
11319       </fixedLine>
11320       <mobile>
11321         <!-- According to wikipedia, TIM mobile numbers can be 9 digits long, but all others are 10
11322              digits long. However, a user reported the existence of new 11 digit long numbers for
11323              TIM with the prefix 33X, so this is supported also. -->
11324         <nationalNumberPattern>
11325           3(?:
11326             [12457-9]\d{8}|
11327             6\d{7,8}|
11328             3\d{7,9}
11329           )
11330         </nationalNumberPattern>
11331         <possibleNumberPattern>\d{9,11}</possibleNumberPattern>
11332         <exampleNumber>3123456789</exampleNumber>
11333       </mobile>
11334       <tollFree>
11335         <nationalNumberPattern>
11336           80(?:
11337             0\d{6}|
11338             3\d{3}
11339           )
11340         </nationalNumberPattern>
11341         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
11342         <exampleNumber>800123456</exampleNumber>
11343       </tollFree>
11344       <premiumRate>
11345         <!-- Adding 0878 numbers, as per
11346              http://www.aduc.it/notizia/polizia+mette+allerta+sul+numero+0878_73136.php. Other
11347              premium prefixes are mentioned here:
11348              http://www.dirittodellinformatica.it/news/telefonia/agcom-blocco-permanente-prefissi-144-166-892-899-20080520241.html -->
11349         <nationalNumberPattern>
11350           0878\d{5}|
11351           1(?:
11352             44|
11353             6[346]
11354           )\d{6}|
11355           89(?:
11356             2\d{3}|
11357             4(?:
11358               [0-4]\d{2}|
11359               [5-9]\d{4}
11360             )|
11361             5(?:
11362               [0-4]\d{2}|
11363               [5-9]\d{6}
11364             )|
11365             9\d{6}
11366           )
11367         </nationalNumberPattern>
11368         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
11369         <exampleNumber>899123456</exampleNumber>
11370       </premiumRate>
11371       <sharedCost>
11372         <nationalNumberPattern>
11373           84(?:
11374             [08]\d{6}|
11375             [17]\d{3}
11376           )
11377         </nationalNumberPattern>
11378         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
11379         <exampleNumber>848123456</exampleNumber>
11380       </sharedCost>
11381       <personalNumber>
11382         <nationalNumberPattern>
11383           1(?:
11384             78\d|
11385             99
11386           )\d{6}
11387         </nationalNumberPattern>
11388         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
11389         <exampleNumber>1781234567</exampleNumber>
11390       </personalNumber>
11391       <voip>
11392         <nationalNumberPattern>55\d{8}</nationalNumberPattern>
11393         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11394         <exampleNumber>5512345678</exampleNumber>
11395       </voip>
11396     </territory>
11397
11398     <!-- Jersey -->
11399     <!-- Inherits formatting rules from the UK. -->
11400     <territory id="JE" countryCode="44" internationalPrefix="00"
11401                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG">
11402       <references>
11403         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom</sourceUrl>
11404         <sourceUrl>http://www.jcra.je/cms3/v2/public/cmsChild.asp?pageID=1024&amp;childID=1036</sourceUrl>
11405       </references>
11406       <generalDesc>
11407         <nationalNumberPattern>[135789]\d{6,9}</nationalNumberPattern>
11408         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
11409       </generalDesc>
11410       <areaCodeOptional>
11411         <nationalNumberPattern>1534[2-9]\d{5}</nationalNumberPattern>
11412         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11413         <exampleNumber>1534250123</exampleNumber>
11414       </areaCodeOptional>
11415       <!-- Specific to JE. -->
11416       <fixedLine>
11417         <!-- 1534 with 10 digits. -->
11418         <nationalNumberPattern>1534\d{6}</nationalNumberPattern>
11419         <exampleNumber>1534456789</exampleNumber>
11420       </fixedLine>
11421       <mobile>
11422         <!-- 7509, 7700, 7797, 7829, 7937 with 10 digits. -->
11423         <nationalNumberPattern>
11424           7(?:
11425             509|
11426             7(?:
11427               00|
11428               97
11429             )|
11430             829|
11431             937
11432           )\d{6}
11433         </nationalNumberPattern>
11434         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11435         <exampleNumber>7797123456</exampleNumber>
11436       </mobile>
11437       <pager>
11438         <!-- Pager numbers as per GB. -->
11439         <nationalNumberPattern>
11440           76(?:
11441             0[012]|
11442             2[356]|
11443             4[0134]|
11444             5[49]|
11445             6[0-369]|
11446             77|
11447             81|
11448             9[39]
11449           )\d{6}
11450         </nationalNumberPattern>
11451         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11452         <exampleNumber>7640123456</exampleNumber>
11453       </pager>
11454       <!-- Specific to JE. -->
11455       <tollFree>
11456         <!-- 800 735, 800 781, 808 901 with 10 digits. -->
11457         <nationalNumberPattern>
11458           80(?:
11459             07(?:
11460               35|
11461               81
11462             )|
11463             8901
11464           )\d{4}
11465         </nationalNumberPattern>
11466         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11467         <exampleNumber>8007354567</exampleNumber>
11468       </tollFree>
11469       <premiumRate>
11470         <!-- 871 206, 900 665, 900 669, 901 810, 907 107, 907 155 with 10 digits. -->
11471         <nationalNumberPattern>
11472           (?:
11473             871206|
11474             90(?:
11475               066[59]|
11476               1810|
11477               71(?:
11478                 07|
11479                 55
11480               )
11481             )
11482           )\d{4}
11483         </nationalNumberPattern>
11484         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11485         <exampleNumber>9018105678</exampleNumber>
11486       </premiumRate>
11487       <sharedCost>
11488         <!-- 844 405, 844 442, 844 469, 844 703, 845 041, 845 800, 870 002 with 10 digits. -->
11489         <nationalNumberPattern>
11490           8(?:
11491             4(?:
11492               4(?:
11493                 4(?:
11494                   05|
11495                   42|
11496                   69
11497                 )|
11498                 703
11499               )|
11500               5(?:
11501                 041|
11502                 800
11503               )
11504             )|
11505             70002
11506           )\d{4}
11507         </nationalNumberPattern>
11508         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11509         <exampleNumber>8447034567</exampleNumber>
11510       </sharedCost>
11511       <personalNumber>
11512         <!-- 70 1511 with 10 digits. -->
11513         <nationalNumberPattern>701511\d{4}</nationalNumberPattern>
11514         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11515         <exampleNumber>7015115678</exampleNumber>
11516       </personalNumber>
11517       <voip>
11518         <!-- VoIP numbers as per GB. -->
11519         <nationalNumberPattern>56\d{8}</nationalNumberPattern>
11520         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11521         <exampleNumber>5612345678</exampleNumber>
11522       </voip>
11523       <uan>
11524         <!-- 300 735, 300 781, 308 901, 33d, 344 405, 344 442, 344 469, 344 703, 345 041, 345 800,
11525              370 002, 371 206, 55 with 10 digits. -->
11526         <nationalNumberPattern>
11527           3(?:
11528             0(?:
11529               07(?:
11530                 35|
11531                 81
11532               )|
11533               8901
11534             )|
11535             3\d{4}|
11536             4(?:
11537               4(?:
11538                 4(?:
11539                   05|
11540                   42|
11541                   69
11542                 )|
11543                 703
11544               )|
11545               5(?:
11546                 041|
11547                 800
11548               )
11549             )|
11550             7(?:
11551               0002|
11552               1206
11553             )
11554           )\d{4}|
11555           55\d{8}
11556         </nationalNumberPattern>
11557         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11558         <exampleNumber>5512345678</exampleNumber>
11559       </uan>
11560     </territory>
11561
11562     <!-- Jamaica -->
11563     <territory id="JM" countryCode="1" leadingDigits="876" nationalPrefix="1"
11564                internationalPrefix="011">
11565       <references>
11566         <sourceUrl>http://www.itu.int/oth/T020200006C/en</sourceUrl>
11567       </references>
11568       <generalDesc>
11569         <!-- NANPA country - uses US formatting rules -->
11570         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
11571         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
11572       </generalDesc>
11573       <fixedLine>
11574         <!-- Numbers have been found online for ranges 62x,63x, 656, 66[2-589]. -->
11575         <nationalNumberPattern>
11576           876(?:
11577             5(?:
11578               0[12]|
11579               1[0-468]|
11580               2[35]|
11581               63
11582             )|
11583             6(?:
11584               0[1-3579]|
11585               1[027-9]|
11586               [23]\d|
11587               40|
11588               5[06]|
11589               6[2-589]|
11590               7[05]|
11591               8[04]|
11592               9[4-9]
11593             )|
11594             7(?:
11595               0[2-689]|
11596               [1-6]\d|
11597               8[056]|
11598               9[45]
11599             )|
11600             9(?:
11601               0[1-8]|
11602               1[02378]|
11603               [2-8]\d|
11604               9[2-468]
11605             )
11606           )\d{4}
11607         </nationalNumberPattern>
11608         <exampleNumber>8765123456</exampleNumber>
11609       </fixedLine>
11610       <mobile>
11611         <!-- Adding 27, 28, 299, 31, 508, 527 and 566 as extra prefixes, as they have been found to
11612              be valid by sending SMSs and looking at online number lookup sites. Also added 50[3-79]
11613              as we have found information online that the 50[3-9] range has been assigned to Digicel.
11614
11615              Numbers have been found online for the following ranges 26x, 29x, 53x, 54x, 55x, 56x.
11616              Most have mobile numbers online so we have put them under mobile but is possible
11617              they are a mixture of fixed line and mobile. -->
11618         <nationalNumberPattern>
11619           876(?:
11620             2[16-9]\d|
11621             [348]\d{2}|
11622             5(?:
11623               0[3-9]|
11624               27|
11625               6[0-24-9]|
11626               [3-578]\d
11627             )|
11628             7(?:
11629               0[07]|
11630               7\d|
11631               8[1-47-9]|
11632               9[0-36-9]
11633             )|
11634             9(?:
11635               [01]9|
11636               9[0579]
11637             )
11638           )\d{4}
11639         </nationalNumberPattern>
11640         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11641         <exampleNumber>8762101234</exampleNumber>
11642       </mobile>
11643       <tollFree>
11644         <nationalNumberPattern>
11645           8(?:
11646             00|
11647             44|
11648             55|
11649             66|
11650             77|
11651             88
11652           )[2-9]\d{6}
11653         </nationalNumberPattern>
11654         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11655         <exampleNumber>8002123456</exampleNumber>
11656       </tollFree>
11657       <premiumRate>
11658         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
11659         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11660         <exampleNumber>9002123456</exampleNumber>
11661       </premiumRate>
11662       <personalNumber>
11663         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
11664         <nationalNumberPattern>
11665           5(?:
11666             00|
11667             33|
11668             44|
11669             66|
11670             77
11671           )[2-9]\d{6}
11672         </nationalNumberPattern>
11673         <possibleNumberPattern>\d{10}</possibleNumberPattern>
11674         <exampleNumber>5002345678</exampleNumber>
11675       </personalNumber>
11676     </territory>
11677
11678     <!-- Jordan -->
11679     <territory id="JO" countryCode="962" internationalPrefix="00"
11680                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
11681                mobileNumberPortableRegion="true">
11682       <references>
11683         <sourceUrl>http://www.trc.gov.jo/images/stories/pdf/NNP_ver200[1].pdf?lang=english</sourceUrl>
11684         <sourceUrl>http://www.itu.int/oth/T020200006E/en</sourceUrl>
11685         <sourceUrl>http://en.wikipedia.org/wiki/%2B962</sourceUrl>
11686       </references>
11687       <availableFormats>
11688         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
11689           pattern="(\d)(\d{3})(\d{4})">
11690           <leadingDigits>
11691             [2356]|
11692             87
11693           </leadingDigits>
11694           <format>$1 $2 $3</format>
11695         </numberFormat>
11696         <numberFormat pattern="(7)(\d{4})(\d{4})">
11697           <leadingDigits>7[457-9]</leadingDigits>
11698           <format>$1 $2 $3</format>
11699         </numberFormat>
11700         <numberFormat pattern="(\d{3})(\d{5,6})">
11701           <leadingDigits>
11702             70|
11703             8[0158]|
11704             9
11705           </leadingDigits>
11706           <format>$1 $2</format>
11707         </numberFormat>
11708       </availableFormats>
11709       <generalDesc>
11710         <nationalNumberPattern>[235-9]\d{7,8}</nationalNumberPattern>
11711         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
11712       </generalDesc>
11713       <fixedLine>
11714         <nationalNumberPattern>
11715           (?:
11716             2(?:
11717               6(?:
11718                 2[0-35-9]|
11719                 3[0-57-8]|
11720                 4[24-7]|
11721                 5[0-24-8]|
11722                 [6-8][02]|
11723                 9[0-2]
11724               )|
11725               7(?:
11726                 0[1-79]|
11727                 10|
11728                 2[014-7]|
11729                 3[0-689]|
11730                 4[019]|
11731                 5[0-3578]
11732               )
11733             )|
11734             32(?:
11735               0[1-69]|
11736               1[1-35-7]|
11737               2[024-7]|
11738               3\d|
11739               4[0-2]|
11740               [57][02]|
11741               60
11742             )|
11743             53(?:
11744               0[0-2]|
11745               [13][02]|
11746               2[0-59]|
11747               49|
11748               5[0-35-9]|
11749               6[15]|
11750               7[45]|
11751               8[1-6]|
11752               9[0-36-9]
11753             )|
11754             6(?:
11755               2[50]0|
11756               300|
11757               4(?:
11758                 0[0125]|
11759                 1[2-7]|
11760                 2[0569]|
11761                 [38][07-9]|
11762                 4[025689]|
11763                 6[0-589]|
11764                 7\d|
11765                 9[0-2]
11766               )|
11767               5(?:
11768                 [01][056]|
11769                 2[034]|
11770                 3[0-57-9]|
11771                 4[17-8]|
11772                 5[0-69]|
11773                 6[0-35-9]|
11774                 7[1-379]|
11775                 8[0-68]|
11776                 9[02-39]
11777               )
11778             )|
11779             87(?:
11780               [02]0|
11781               7[08]|
11782               9[09]
11783             )
11784           )\d{4}
11785         </nationalNumberPattern>
11786         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
11787         <exampleNumber>62001234</exampleNumber>
11788       </fixedLine>
11789       <mobile>
11790         <nationalNumberPattern>
11791           7(?:
11792             55|
11793             7[25-9]|
11794             8[05-9]|
11795             9[0-25-9]
11796           )\d{6}
11797         </nationalNumberPattern>
11798         <possibleNumberPattern>\d{9}</possibleNumberPattern>
11799         <exampleNumber>790123456</exampleNumber>
11800       </mobile>
11801       <pager>
11802         <nationalNumberPattern>
11803           74(?:
11804             66|
11805             77
11806           )\d{5}
11807         </nationalNumberPattern>
11808         <possibleNumberPattern>\d{9}</possibleNumberPattern>
11809         <exampleNumber>746612345</exampleNumber>
11810       </pager>
11811       <tollFree>
11812         <nationalNumberPattern>80\d{6}</nationalNumberPattern>
11813         <possibleNumberPattern>\d{8}</possibleNumberPattern>
11814         <exampleNumber>80012345</exampleNumber>
11815       </tollFree>
11816       <premiumRate>
11817         <nationalNumberPattern>900\d{5}</nationalNumberPattern>
11818         <possibleNumberPattern>\d{8}</possibleNumberPattern>
11819         <exampleNumber>90012345</exampleNumber>
11820       </premiumRate>
11821       <sharedCost>
11822         <nationalNumberPattern>85\d{6}</nationalNumberPattern>
11823         <possibleNumberPattern>\d{8}</possibleNumberPattern>
11824         <exampleNumber>85012345</exampleNumber>
11825       </sharedCost>
11826       <personalNumber>
11827         <nationalNumberPattern>70\d{7}</nationalNumberPattern>
11828         <possibleNumberPattern>\d{9}</possibleNumberPattern>
11829         <exampleNumber>700123456</exampleNumber>
11830       </personalNumber>
11831       <uan>
11832         <!-- These numbers are Location Independent Services / Fixed cost according to
11833              http://www.trc.gov.jo -->
11834         <nationalNumberPattern>
11835           8(?:
11836             10|
11837             8\d
11838           )\d{5}
11839         </nationalNumberPattern>
11840         <possibleNumberPattern>\d{8}</possibleNumberPattern>
11841         <exampleNumber>88101234</exampleNumber>
11842       </uan>
11843     </territory>
11844
11845     <!-- Japan -->
11846     <territory id="JP" countryCode="81" internationalPrefix="010" nationalPrefix="0"
11847                nationalPrefixFormattingRule="$NP$FG" leadingZeroPossible="true"
11848                mobileNumberPortableRegion="true">
11849       <references>
11850         <sourceUrl>http://www.soumu.go.jp/main_sosiki/joho_tsusin/top/tel_number/number_shitei.html</sourceUrl>
11851         <sourceUrl>http://www.numberingplans.com/?page=dialling&amp;sub=areacodes&amp;ac=JP</sourceUrl>
11852       </references>
11853       <availableFormats>
11854         <!-- Toll-free, premium-rate and UAN numbers -->
11855         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
11856           <leadingDigits>
11857             (?:
11858               12|
11859               57|
11860               99
11861             )0
11862           </leadingDigits>
11863           <format>$1-$2-$3</format>
11864         </numberFormat>
11865         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
11866           <leadingDigits>800</leadingDigits>
11867           <format>$1-$2-$3</format>
11868         </numberFormat>
11869         <!-- National-only toll-free numbers (0037, 0066, 0077 and 0088). -->
11870         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{4})">
11871           <leadingDigits>0077</leadingDigits>
11872           <format>$1-$2</format>
11873           <intlFormat>NA</intlFormat>
11874         </numberFormat>
11875         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{2})(\d{3,4})">
11876           <leadingDigits>0077</leadingDigits>
11877           <format>$1-$2-$3</format>
11878           <intlFormat>NA</intlFormat>
11879         </numberFormat>
11880         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{2})(\d{4})">
11881           <leadingDigits>0088</leadingDigits>
11882           <format>$1-$2-$3</format>
11883           <intlFormat>NA</intlFormat>
11884         </numberFormat>
11885         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{3})(\d{3,4})">
11886           <leadingDigits>
11887             00(?:
11888                37|
11889                66
11890             )
11891           </leadingDigits>
11892           <format>$1-$2-$3</format>
11893           <intlFormat>NA</intlFormat>
11894         </numberFormat>
11895         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{4})(\d{4,5})">
11896           <leadingDigits>
11897             00(?:
11898                37|
11899                66
11900             )
11901           </leadingDigits>
11902           <format>$1-$2-$3</format>
11903           <intlFormat>NA</intlFormat>
11904         </numberFormat>
11905         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{5})(\d{5,6})">
11906           <leadingDigits>
11907             00(?:
11908                37|
11909                66
11910             )
11911           </leadingDigits>
11912           <format>$1-$2-$3</format>
11913           <intlFormat>NA</intlFormat>
11914         </numberFormat>
11915         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{6})(\d{6,7})">
11916           <leadingDigits>
11917             00(?:
11918                37|
11919                66
11920             )
11921           </leadingDigits>
11922           <format>$1-$2-$3</format>
11923           <intlFormat>NA</intlFormat>
11924         </numberFormat>
11925         <!-- Some leading digits are explicitly reserved for a particular purpose.
11926              We handle them first in this rule, and let the following rules ignore those exceptions.
11927              Note: The rule here is not in the files we rely on when creating the other rules.
11928                    We would need to manually modify it if the Japanese goverment
11929                    decided to change the rule.
11930
11931              (prefix): purpose
11932              "20": Pagers
11933              "50": IP phone
11934              "70": PHS (Personal Handy-phone System, which has been used in Japan
11935                    with Non-3G, Japanese-specific protocol).
11936                    See also http://ja.wikipedia.org/wiki/PHS (Japanese)
11937              "80" and "90": Mobile phone
11938           -->
11939         <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
11940           <leadingDigits>
11941             [2579]0|
11942             80[1-9]
11943           </leadingDigits>
11944           <format>$1-$2-$3</format>
11945         </numberFormat>
11946         <!-- The order of the reg-exps are important.
11947              Examples (not all):
11948              - "15": 15420 -> 154-20, 15472 -> 1547-2, 15410 -> 15-410,
11949              - "22": 22200 -> 22-200, 22300 -> 22-300, 22320 -> 223-20, 22350 -> 22-350
11950              - "42": 42000 -> 4-2000, 42901 -> 4-2901, 42910 -> 42-910
11951              - "82": 82200 -> 82-200, 82020 -> 820-20, 82400 -> 82-400
11952              - "99": 99400 -> 99-400, 99430 -> 994-30, 99692 -> 9969-2, 99750 -> 997-50
11953              - "993": 99330 -> 993-30, 99331 -> 99-331, 99332 -> 993-32
11954           -->
11955         <numberFormat pattern="(\d{4})(\d)(\d{4})">
11956           <leadingDigits>
11957             1(?:
11958               26|
11959               3[79]|
11960               4[56]|
11961               5[4-68]|
11962               6[3-5]
11963             )|
11964             5(?:
11965               76|
11966               97
11967             )|
11968             499|
11969             746|
11970             8(?:
11971               3[89]|
11972               63|
11973               47|
11974               51
11975             )|
11976             9(?:
11977               49|
11978               80|
11979               9[16]
11980             )
11981           </leadingDigits>
11982           <leadingDigits>
11983             1(?:
11984               267|
11985               3(?:
11986                 7[247]|
11987                 9[278]
11988               )|
11989               4(?:
11990                 5[67]|
11991                 66
11992               )|
11993               5(?:
11994                 47|
11995                 58|
11996                 64|
11997                 8[67]
11998               )|
11999               6(?:
12000                 3[245]|
12001                 48|
12002                 5[4-68]
12003               )
12004             )|
12005             5(?:
12006               76|
12007               97
12008             )9|
12009             499[2468]|
12010             7468|
12011             8(?:
12012               3(?:
12013                 8[78]|
12014                 96
12015               )|
12016               636|
12017               477|
12018               51[24]
12019             )|
12020             9(?:
12021               496|
12022               802|
12023               9(?:
12024                 1[23]|
12025                 69
12026               )
12027             )
12028           </leadingDigits>
12029           <leadingDigits>
12030             1(?:
12031               267|
12032               3(?:
12033                 7[247]|
12034                 9[278]
12035               )|
12036               4(?:
12037                 5[67]|
12038                 66
12039               )|
12040               5(?:
12041                 47|
12042                 58|
12043                 64|
12044                 8[67]
12045               )|
12046               6(?:
12047                 3[245]|
12048                 48|
12049                 5[4-68]
12050               )
12051             )|
12052             5(?:
12053               769|
12054               979[2-69]
12055             )|
12056             499[2468]|
12057             7468|
12058             8(?:
12059               3(?:
12060                 8[78]|
12061                 96[2457-9]
12062               )|
12063               636[2-57-9]|
12064               477|
12065               51[24]
12066             )|
12067             9(?:
12068               496|
12069               802|
12070               9(?:
12071                 1[23]|
12072                 69
12073               )
12074             )
12075           </leadingDigits>
12076           <format>$1-$2-$3</format>
12077         </numberFormat>
12078         <numberFormat pattern="(\d{3})(\d{2})(\d{4})">
12079           <leadingDigits>
12080             1(?:
12081               2[3-6]|
12082               3[3-9]|
12083               4[2-6]|
12084               5[2-8]|
12085               [68][2-7]|
12086               7[2-689]|
12087               9[1-578]
12088             )|
12089             2(?:
12090               2[03-689]|
12091               3[3-58]|
12092               4[0-468]|
12093               5[04-8]|
12094               6[013-8]|
12095               7[06-9]|
12096               8[02-57-9]|
12097               9[13]
12098             )|
12099             4(?:
12100               2[28]|
12101               3[689]|
12102               6[035-7]|
12103               7[05689]|
12104               80|
12105               9[3-5]
12106             )|
12107             5(?:
12108               3[1-36-9]|
12109               4[4578]|
12110               5[013-8]|
12111               6[1-9]|
12112               7[2-8]|
12113               8[14-7]|
12114               9[4-9]
12115             )|
12116             7(?:
12117               2[15]|
12118               3[5-9]|
12119               4[02-9]|
12120               6[135-8]|
12121               7[0-4689]|
12122               9[014-9]
12123             )|
12124             8(?:
12125               2[49]|
12126               3[3-8]|
12127               4[5-8]|
12128               5[2-9]|
12129               6[35-9]|
12130               7[579]|
12131               8[03-579]|
12132               9[2-8]
12133             )|
12134             9(?:
12135               [23]0|
12136               4[02-46-9]|
12137               5[024-79]|
12138               6[4-9]|
12139               7[2-47-9]|
12140               8[02-7]|
12141               9[3-7]
12142             )
12143           </leadingDigits>
12144           <leadingDigits>
12145             1(?:
12146               2[3-6]|
12147               3[3-9]|
12148               4[2-6]|
12149               5(?:
12150                 [236-8]|
12151                 [45][2-69]
12152               )|
12153               [68][2-7]|
12154               7[2-689]|
12155               9[1-578]
12156             )|
12157             2(?:
12158               2(?:
12159                 [04-689]|
12160                 3[23]
12161               )|
12162               3[3-58]|
12163               4[0-468]|
12164               5(?:
12165                 5[78]|
12166                 7[2-4]|
12167                 [0468][2-9]
12168               )|
12169               6(?:
12170                 [0135-8]|
12171                 4[2-5]
12172               )|
12173               7(?:
12174                 [0679]|
12175                 8[2-7]
12176               )|
12177               8(?:
12178                 [024578]|
12179                 3[25-9]|
12180                 9[6-9]
12181               )|
12182               9(?:
12183                 11|
12184                 3[2-4]
12185               )
12186             )|
12187             4(?:
12188               2(?:
12189                 2[2-9]|
12190                 8[237-9]
12191               )|
12192               3[689]|
12193               6[035-7]|
12194               7(?:
12195                 [059][2-8]|
12196                 [68]
12197               )|
12198               80|
12199               9[3-5]
12200             )|
12201             5(?:
12202               3[1-36-9]|
12203               4[4578]|
12204               5[013-8]|
12205               6[1-9]|
12206               7[2-8]|
12207               8[14-7]|
12208               9(?:
12209                 [89][2-8]|
12210                 [4-7]
12211               )
12212             )|
12213             7(?:
12214               2[15]|
12215               3[5-9]|
12216               4[02-9]|
12217               6[135-8]|
12218               7[0-4689]|
12219               9(?:
12220                 [017-9]|
12221                 4[6-8]|
12222                 5[2-478]|
12223                 6[2-589]
12224               )
12225             )|
12226             8(?:
12227               2(?:
12228                 4[4-8]|
12229                 9[2-8]
12230               )|
12231               3(?:
12232                 7[2-6]|
12233                 [3-6][2-9]|
12234                 8[2-5]
12235               )|
12236               4[5-8]|
12237               5[2-9]|
12238               6(?:
12239                 [37]|
12240                 5[4-7]|
12241                 6[2-9]|
12242                 8[2-8]|
12243                 9[236-9]
12244               )|
12245               7[579]|
12246               8[03-579]|
12247               9[2-8]
12248             )|
12249             9(?:
12250               [23]0|
12251               4[02-46-9]|
12252               5[024-79]|
12253               6[4-9]|
12254               7[2-47-9]|
12255               8[02-7]|
12256               9(?:
12257                 3[34]|
12258                 [4-7]
12259               )
12260             )
12261           </leadingDigits>
12262           <leadingDigits>
12263             1(?:
12264               2[3-6]|
12265               3[3-9]|
12266               4[2-6]|
12267               5(?:
12268                 [236-8]|
12269                 [45][2-69]
12270               )|
12271               [68][2-7]|
12272               7[2-689]|
12273               9[1-578]
12274             )|
12275             2(?:
12276               2(?:
12277                 [04-689]|
12278                 3[23]
12279               )|
12280               3[3-58]|
12281               4[0-468]|
12282               5(?:
12283                 5[78]|
12284                 7[2-4]|
12285                 [0468][2-9]
12286               )|
12287               6(?:
12288                 [0135-8]|
12289                 4[2-5]
12290               )|
12291               7(?:
12292                 [0679]|
12293                 8[2-7]
12294               )|
12295               8(?:
12296                 [024578]|
12297                 3[25-9]|
12298                 9[6-9]
12299               )|
12300               9(?:
12301                 11|
12302                 3[2-4]
12303               )
12304             )|
12305             4(?:
12306               2(?:
12307                 2[2-9]|
12308                 8[237-9]
12309               )|
12310               3[689]|
12311               6[035-7]|
12312               7(?:
12313                 [059][2-8]|
12314                 [68]
12315               )|
12316               80|
12317               9[3-5]
12318             )|
12319             5(?:
12320               3[1-36-9]|
12321               4[4578]|
12322               5[013-8]|
12323               6[1-9]|
12324               7[2-8]|
12325               8[14-7]|
12326               9(?:
12327                 [89][2-8]|
12328                 [4-7]
12329               )
12330             )|
12331             7(?:
12332               2[15]|
12333               3[5-9]|
12334               4[02-9]|
12335               6[135-8]|
12336               7[0-4689]|
12337               9(?:
12338                 [017-9]|
12339                 4[6-8]|
12340                 5[2-478]|
12341                 6[2-589]
12342               )
12343             )|
12344             8(?:
12345               2(?:
12346                 4[4-8]|
12347                 9(?:
12348                   [3578]|
12349                   20|
12350                   4[04-9]|
12351                   6[56]
12352                 )
12353               )|
12354               3(?:
12355                 7(?:
12356                   [2-5]|
12357                   6[0-59]
12358                 )|
12359                 [3-6][2-9]|
12360                 8[2-5]
12361               )|
12362               4[5-8]|
12363               5[2-9]|
12364               6(?:
12365                 [37]|
12366                 5(?:
12367                   [467]|
12368                   5[014-9]
12369                 )|
12370                 6(?:
12371                   [2-8]|
12372                   9[02-69]
12373                 )|
12374                 8[2-8]|
12375                 9(?:
12376                   [236-8]|
12377                   9[23]
12378                 )
12379               )|
12380               7[579]|
12381               8[03-579]|
12382               9[2-8]
12383             )|
12384             9(?:
12385               [23]0|
12386               4[02-46-9]|
12387               5[024-79]|
12388               6[4-9]|
12389               7[2-47-9]|
12390               8[02-7]|
12391               9(?:
12392                 3(?:
12393                   3[02-9]|
12394                   4[0-24689]
12395                 )|
12396                 4[2-69]|
12397                 [5-7]
12398               )
12399             )
12400           </leadingDigits>
12401           <leadingDigits>
12402             1(?:
12403               2[3-6]|
12404               3[3-9]|
12405               4[2-6]|
12406               5(?:
12407                 [236-8]|
12408                 [45][2-69]
12409               )|
12410               [68][2-7]|
12411               7[2-689]|
12412               9[1-578]
12413             )|
12414             2(?:
12415               2(?:
12416                 [04-689]|
12417                 3[23]
12418               )|
12419               3[3-58]|
12420               4[0-468]|
12421               5(?:
12422                 5[78]|
12423                 7[2-4]|
12424                 [0468][2-9]
12425               )|
12426               6(?:
12427                 [0135-8]|
12428                 4[2-5]
12429               )|
12430               7(?:
12431                 [0679]|
12432                 8[2-7]
12433               )|
12434               8(?:
12435                 [024578]|
12436                 3[25-9]|
12437                 9[6-9]
12438               )|
12439               9(?:
12440                 11|
12441                 3[2-4]
12442               )
12443             )|
12444             4(?:
12445               2(?:
12446                 2[2-9]|
12447                 8[237-9]
12448               )|
12449               3[689]|
12450               6[035-7]|
12451               7(?:
12452                 [059][2-8]|
12453                 [68]
12454               )|
12455               80|
12456               9[3-5]
12457             )|
12458             5(?:
12459               3[1-36-9]|
12460               4[4578]|
12461               5[013-8]|
12462               6[1-9]|
12463               7[2-8]|
12464               8[14-7]|
12465               9(?:
12466                 [89][2-8]|
12467                 [4-7]
12468               )
12469             )|
12470             7(?:
12471               2[15]|
12472               3[5-9]|
12473               4[02-9]|
12474               6[135-8]|
12475               7[0-4689]|
12476               9(?:
12477                 [017-9]|
12478                 4[6-8]|
12479                 5[2-478]|
12480                 6[2-589]
12481               )
12482             )|
12483             8(?:
12484               2(?:
12485                 4[4-8]|
12486                 9(?:
12487                   [3578]|
12488                   20|
12489                   4[04-9]|
12490                   6(?:
12491                     5[25]|
12492                     60
12493                   )
12494                 )
12495               )|
12496               3(?:
12497                 7(?:
12498                   [2-5]|
12499                   6[0-59]
12500                 )|
12501                 [3-6][2-9]|
12502                 8[2-5]
12503               )|
12504               4[5-8]|
12505               5[2-9]|
12506               6(?:
12507                 [37]|
12508                 5(?:
12509                   [467]|
12510                   5[014-9]
12511                 )|
12512                 6(?:
12513                   [2-8]|
12514                   9[02-69]
12515                 )|
12516                 8[2-8]|
12517                 9(?:
12518                   [236-8]|
12519                   9[23]
12520                 )
12521               )|
12522               7[579]|
12523               8[03-579]|
12524               9[2-8]
12525             )|
12526             9(?:
12527               [23]0|
12528               4[02-46-9]|
12529               5[024-79]|
12530               6[4-9]|
12531               7[2-47-9]|
12532               8[02-7]|
12533               9(?:
12534                 3(?:
12535                   3[02-9]|
12536                   4[0-24689]
12537                 )|
12538                 4[2-69]|
12539                 [5-7]
12540               )
12541             )
12542           </leadingDigits>
12543           <format>$1-$2-$3</format>
12544         </numberFormat>
12545         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
12546           <leadingDigits>
12547             1|
12548             2(?:
12549               2[37]|
12550               5[5-9]|
12551               64|
12552               78|
12553               8[39]|
12554               91
12555             )|
12556             4(?:
12557               2[2689]|
12558               64|
12559               7[347]
12560             )|
12561             5(?:
12562               [2-589]|
12563               39
12564             )|
12565             60|
12566             8(?:
12567               [46-9]|
12568               3[279]|
12569               2[124589]
12570             )|
12571             9(?:
12572               [235-8]|
12573               93
12574             )
12575           </leadingDigits>
12576           <leadingDigits>
12577             1|
12578             2(?:
12579               2[37]|
12580               5(?:
12581                 [57]|
12582                 [68]0|
12583                 9[19]
12584               )|
12585               64|
12586               78|
12587               8[39]|
12588               917
12589             )|
12590             4(?:
12591               2(?:
12592                 [68]|
12593                 20|
12594                 9[178]
12595               )|
12596               64|
12597               7[347]
12598             )|
12599             5(?:
12600               [2-589]|
12601               39[67]
12602             )|
12603             60|
12604             8(?:
12605               [46-9]|
12606               3[279]|
12607               2[124589]
12608             )|
12609             9(?:
12610               [235-8]|
12611               93[34]
12612             )
12613           </leadingDigits>
12614           <leadingDigits>
12615             1|
12616             2(?:
12617               2[37]|
12618               5(?:
12619                 [57]|
12620                 [68]0|
12621                 9(?:
12622                   17|
12623                   99
12624                 )
12625               )|
12626               64|
12627               78|
12628               8[39]|
12629               917
12630             )|
12631             4(?:
12632               2(?:
12633                 [68]|
12634                 20|
12635                 9[178]
12636               )|
12637               64|
12638               7[347]
12639             )|
12640             5(?:
12641               [2-589]|
12642               39[67]
12643             )|
12644             60|
12645             8(?:
12646               [46-9]|
12647               3[279]|
12648               2[124589]
12649             )|
12650             9(?:
12651               [235-8]|
12652               93(?:
12653                 31|
12654                 4
12655               )
12656             )
12657           </leadingDigits>
12658           <format>$1-$2-$3</format>
12659         </numberFormat>
12660         <numberFormat pattern="(\d{3})(\d{2})(\d{4})">
12661           <leadingDigits>
12662             2(?:
12663               9[14-79]|
12664               74|
12665               [34]7|
12666               [56]9
12667             )|
12668             82|
12669             993
12670           </leadingDigits>
12671           <format>$1-$2-$3</format>
12672         </numberFormat>
12673         <numberFormat pattern="(\d)(\d{4})(\d{4})">
12674           <leadingDigits>
12675             3|
12676             4(?:
12677               2[09]|
12678               7[01]
12679             )|
12680             6[1-9]
12681           </leadingDigits>
12682           <format>$1-$2-$3</format>
12683         </numberFormat>
12684         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
12685           <leadingDigits>[2479][1-9]</leadingDigits>
12686           <format>$1-$2-$3</format>
12687         </numberFormat>
12688       </availableFormats>
12689       <generalDesc>
12690         <nationalNumberPattern>
12691           [1-9]\d{8,9}|
12692           00(?:
12693              [36]\d{7,14}|
12694              7\d{5,7}|
12695              8\d{7}
12696           )
12697         </nationalNumberPattern>
12698         <possibleNumberPattern>\d{8,17}</possibleNumberPattern>
12699       </generalDesc>
12700       <noInternationalDialling>
12701         <!-- Toll-free numbers with a leading "00" cannot be dialled internationally. -->
12702         <nationalNumberPattern>
12703           00(?:
12704              37\d{6,13}|
12705              66\d{6,13}|
12706              777(?:
12707                [01]\d{2}|
12708                5\d{3}|
12709                8\d{4}
12710              )|
12711              882[1245]\d{4}
12712           )
12713         </nationalNumberPattern>
12714         <exampleNumber>00777012</exampleNumber>
12715       </noInternationalDialling>
12716       <fixedLine>
12717         <nationalNumberPattern>
12718           (?:
12719             1(?:
12720               1[235-8]|
12721               2[3-6]|
12722               3[3-9]|
12723               4[2-6]|
12724               [58][2-8]|
12725               6[2-7]|
12726               7[2-9]|
12727               9[1-9]
12728             )|
12729             2[2-9]\d|
12730             [36][1-9]\d|
12731             4(?:
12732               6[02-8]|
12733               [2-578]\d|
12734               9[2-59]
12735             )|
12736             5(?:
12737               6[1-9]|
12738               7[2-8]|
12739               [2-589]\d
12740             )|
12741             7(?:
12742               3[4-9]|
12743               4[02-9]|
12744               [25-9]\d
12745             )|
12746             8(?:
12747               3[2-9]|
12748               4[5-9]|
12749               5[1-9]|
12750               8[03-9]|
12751               [2679]\d
12752             )|
12753             9(?:
12754               [679][1-9]|
12755               [2-58]\d
12756             )
12757           )\d{6}
12758         </nationalNumberPattern>
12759         <possibleNumberPattern>\d{9}</possibleNumberPattern>
12760         <exampleNumber>312345678</exampleNumber>
12761       </fixedLine>
12762       <mobile>
12763         <nationalNumberPattern>[7-9]0[1-9]\d{7}</nationalNumberPattern>
12764         <possibleNumberPattern>\d{10}</possibleNumberPattern>
12765         <exampleNumber>7012345678</exampleNumber>
12766       </mobile>
12767       <pager>
12768         <nationalNumberPattern>20\d{8}</nationalNumberPattern>
12769         <possibleNumberPattern>\d{10}</possibleNumberPattern>
12770         <exampleNumber>2012345678</exampleNumber>
12771       </pager>
12772       <tollFree>
12773         <!-- http://www.kddi.com/english/business/free_call_dx/number.html and
12774              http://tm.softbank.jp/english/business/phone_service/freecall_sp/index.html
12775              http://eonet.jp/home/denwa/service/access.html
12776              http://ci.fusioncom.co.jp/feature/
12777              http://www.auhikari.jp/service/tel/connection/index.html -->
12778         <!-- Note that in fact, the number length for 0037 and 0066 numbers should extend to 21
12779              digits, confirmed with Yahoo JP. However, this extends well beyond the maximum number
12780              length allowed by ITU and hence our library, so we only allow numbers up to 17 digits
12781              for now (including both leading 00s). -->
12782         <nationalNumberPattern>
12783           120\d{6}|
12784           800\d{7}|
12785           00(?:
12786              37\d{6,13}|
12787              66\d{6,13}|
12788              777(?:
12789                [01]\d{2}|
12790                5\d{3}|
12791                8\d{4}
12792              )|
12793              882[1245]\d{4}
12794           )
12795         </nationalNumberPattern>
12796         <exampleNumber>120123456</exampleNumber>
12797       </tollFree>
12798       <premiumRate>
12799         <nationalNumberPattern>990\d{6}</nationalNumberPattern>
12800         <possibleNumberPattern>\d{9}</possibleNumberPattern>
12801         <exampleNumber>990123456</exampleNumber>
12802       </premiumRate>
12803       <personalNumber>
12804         <nationalNumberPattern>60\d{7}</nationalNumberPattern>
12805         <possibleNumberPattern>\d{9}</possibleNumberPattern>
12806         <exampleNumber>601234567</exampleNumber>
12807       </personalNumber>
12808       <voip>
12809         <nationalNumberPattern>50[1-9]\d{7}</nationalNumberPattern>
12810         <possibleNumberPattern>\d{10}</possibleNumberPattern>
12811         <exampleNumber>5012345678</exampleNumber>
12812       </voip>
12813       <!-- Storing "unified number service" as UAN. -->
12814       <uan>
12815         <nationalNumberPattern>570\d{6}</nationalNumberPattern>
12816         <possibleNumberPattern>\d{9}</possibleNumberPattern>
12817         <exampleNumber>570123456</exampleNumber>
12818       </uan>
12819     </territory>
12820
12821     <!-- Kenya -->
12822     <territory id="KE" countryCode="254" internationalPrefix="000"
12823                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
12824                mobileNumberPortableRegion="true">
12825       <references>
12826         <sourceUrl>http://www.cck.go.ke/licensing/numbering/plan.html</sourceUrl>
12827         <sourceUrl>http://en.wikipedia.org/wiki/+254</sourceUrl>
12828       </references>
12829       <availableFormats>
12830         <numberFormat pattern="(\d{2})(\d{5,7})">
12831           <leadingDigits>[24-6]</leadingDigits>
12832           <format>$1 $2</format>
12833         </numberFormat>
12834         <numberFormat pattern="(\d{3})(\d{6,7})">
12835           <leadingDigits>7</leadingDigits>
12836           <format>$1 $2</format>
12837         </numberFormat>
12838         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
12839           <leadingDigits>[89]</leadingDigits>
12840           <format>$1 $2 $3</format>
12841         </numberFormat>
12842       </availableFormats>
12843       <generalDesc>
12844         <nationalNumberPattern>
12845           20\d{6,7}|
12846           [4-9]\d{6,9}
12847         </nationalNumberPattern>
12848         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
12849       </generalDesc>
12850       <fixedLine>
12851         <!-- The prefixes 046, 050, 058, and 066 may appear online in less than 9 digits but
12852              calling them has confirmed these are outdated. However a 7-digit 068 number was
12853              dialed successfully so we consider these valid despite the plan. -->
12854         <nationalNumberPattern>
12855           20\d{6,7}|
12856           4(?:
12857             [0136]\d{7}|
12858             [245]\d{5,7}
12859           )|
12860           5(?:
12861             [08]\d{7}|
12862             [1-79]\d{5,7}
12863           )|
12864           6(?:
12865             [01457-9]\d{5,7}|
12866             [26]\d{7}
12867           )
12868         </nationalNumberPattern>
12869         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
12870         <exampleNumber>202012345</exampleNumber>
12871       </fixedLine>
12872       <mobile>
12873         <nationalNumberPattern>
12874           7(?:
12875             [0-36]\d|
12876             5[0-6]|
12877             7[0-5]|
12878             8[0-25-9]
12879           )\d{6}
12880         </nationalNumberPattern>
12881         <possibleNumberPattern>\d{9}</possibleNumberPattern>
12882         <exampleNumber>712123456</exampleNumber>
12883       </mobile>
12884       <tollFree>
12885         <!-- Longer numbers have been found than the plan suggests, so we support them here too. -->
12886         <!-- The plan suggests 0844 and 0845 may belong here, but these are short numbers rather
12887              than prefixes:
12888              http://www.telkomkenya.8k.com/Products/v/2.html
12889              http://www.kenya-advisor.com/phone-calls-kenya.html
12890              http://www.telkom.co.ke/index.php?option=com_content&view=article&id=64&Itemid=98 -->
12891         <nationalNumberPattern>800[24-8]\d{5,6}</nationalNumberPattern>
12892         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
12893         <exampleNumber>800223456</exampleNumber>
12894       </tollFree>
12895       <premiumRate>
12896         <nationalNumberPattern>900[02-9]\d{5}</nationalNumberPattern>
12897         <possibleNumberPattern>\d{9}</possibleNumberPattern>
12898         <exampleNumber>900223456</exampleNumber>
12899       </premiumRate>
12900     </territory>
12901
12902     <!-- Kyrgyzstan -->
12903     <territory id="KG" countryCode="996" internationalPrefix="00"
12904                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
12905       <references>
12906         <sourceUrl>http://www.itu.int/oth/T0202000074/en</sourceUrl>
12907       </references>
12908       <availableFormats>
12909         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
12910           <leadingDigits>
12911             [25-7]|
12912             31[25]
12913           </leadingDigits>
12914           <format>$1 $2 $3</format>
12915         </numberFormat>
12916         <numberFormat pattern="(\d{4})(\d{5})">
12917           <leadingDigits>
12918             3(?:
12919               1[36]|
12920               [2-9]
12921             )
12922           </leadingDigits>
12923           <format>$1 $2</format>
12924         </numberFormat>
12925         <numberFormat pattern="(\d{3})(\d{3})(\d)(\d{3})">
12926           <leadingDigits>8</leadingDigits>
12927           <format>$1 $2 $3 $4</format>
12928         </numberFormat>
12929       </availableFormats>
12930       <generalDesc>
12931         <nationalNumberPattern>[235-8]\d{8,9}</nationalNumberPattern>
12932         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
12933       </generalDesc>
12934       <fixedLine>
12935         <!-- Extra area codes found on Web Search: 3147. -->
12936         <nationalNumberPattern>
12937           (?:
12938             3(?:
12939               1(?:
12940                 [256]\d|
12941                 3[1-9]|
12942                 47
12943               )|
12944               2(?:
12945                 22|
12946                 3[0-479]|
12947                 6[0-7]
12948               )|
12949               4(?:
12950                 22|
12951                 5[6-9]|
12952                 6\d
12953               )|
12954               5(?:
12955                 22|
12956                 3[4-7]|
12957                 59|
12958                 6\d
12959               )|
12960               6(?:
12961                 22|
12962                 5[35-7]|
12963                 6\d
12964               )|
12965               7(?:
12966                 22|
12967                 3[468]|
12968                 4[1-9]|
12969                 59|
12970                 [67]\d
12971               )|
12972               9(?:
12973                 22|
12974                 4[1-8]|
12975                 6\d
12976               )
12977             )|
12978             6(?:
12979               09|
12980               12|
12981               2[2-4]
12982             )\d
12983           )\d{5}
12984         </nationalNumberPattern>
12985         <exampleNumber>312123456</exampleNumber>
12986       </fixedLine>
12987       <mobile>
12988         <nationalNumberPattern>
12989           (?:
12990             20[0-35]|
12991             5[124-7]\d|
12992             7[07]\d
12993           )\d{6}
12994         </nationalNumberPattern>
12995         <possibleNumberPattern>\d{9}</possibleNumberPattern>
12996         <exampleNumber>700123456</exampleNumber>
12997       </mobile>
12998       <tollFree>
12999         <!-- Add an extra digit to the number pattern since the only toll-free number found on Web
13000              Search contains 10 digits instead of the 9 digits specified in the ITU document. -->
13001         <nationalNumberPattern>800\d{6,7}</nationalNumberPattern>
13002         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
13003         <exampleNumber>800123456</exampleNumber>
13004       </tollFree>
13005       <!-- No premiumRate information can be found. -->
13006       <!-- http://www.iru-nelti.org/index/info-app/id.216 -->
13007     </territory>
13008
13009     <!-- Cambodia -->
13010     <territory id="KH" countryCode="855" internationalPrefix="00[14-9]"
13011                nationalPrefix="0">
13012       <references>
13013         <sourceUrl>http://www.itu.int/oth/T0202000023/en</sourceUrl>
13014         <sourceUrl>http://en.wikipedia.org/wiki/+855</sourceUrl>
13015       </references>
13016       <availableFormats>
13017         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})" nationalPrefixFormattingRule="$NP$FG">
13018           <leadingDigits>
13019             1\d[1-9]|
13020             [2-9]
13021           </leadingDigits>
13022           <format>$1 $2 $3</format>
13023         </numberFormat>
13024         <numberFormat pattern="(1[89]00)(\d{3})(\d{3})">
13025           <leadingDigits>1[89]0</leadingDigits>
13026           <format>$1 $2 $3</format>
13027         </numberFormat>
13028       </availableFormats>
13029       <generalDesc>
13030         <nationalNumberPattern>[1-9]\d{7,9}</nationalNumberPattern>
13031         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
13032       </generalDesc>
13033       <fixedLine>
13034         <!-- Allowing subscriber numbers beginning with 5 since Mobitel have informed us they have
13035              started issuing fixed-line numbers like this. Apparently, mobile-company-issued
13036              fixed-line numbers are one digit longer than government-issued numbers. Moreover, the
13037              range beginning with 6 seems to include some numbers that are one digit longer as well.
13038              Allowing 238\d{6} and 234[234]\d{4} based on information from Cambodia Yellow Pages.
13039              Note that numbers beginning with 234 are split across two patterns. -->
13040         <nationalNumberPattern>
13041           (?:
13042             2[3-6]|
13043             3[2-6]|
13044             4[2-4]|
13045             [5-7][2-5]
13046           )(?:
13047             [237-9]|
13048             4[56]|
13049             5\d|
13050             6\d?
13051           )\d{5}|
13052           23(?:
13053             4[234]|
13054             8\d{2}
13055           )\d{4}
13056         </nationalNumberPattern>
13057         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
13058         <exampleNumber>23756789</exampleNumber>
13059       </fixedLine>
13060       <mobile>
13061         <!-- SMART uses prefixes 01[056], 070, 08[167] and 09[368].
13062              Beeline uses 060.
13063              Mobitel uses 01[1247].
13064              Cellcard uses 0857 and 061.
13065              Extra prefixes found online: 088, 097.
13066              Allowing 9-digit 12, 31, 38 and 76 numbers based on information from Cambodia Yellow
13067              Pages and online search. Allowing 71 based on open-source report and online search. -->
13068         <nationalNumberPattern>
13069           (?:
13070             1(?:
13071               [013-9]|
13072               2\d?
13073             )|
13074             3[18]\d|
13075             6[016-9]|
13076             7(?:
13077               [07-9]|
13078               [16]\d
13079             )|
13080             8(?:
13081               [013-79]|
13082               8\d
13083             )|
13084             9(?:
13085               6\d|
13086               7\d?|
13087               [0-589]
13088             )
13089           )\d{6}
13090         </nationalNumberPattern>
13091         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
13092         <exampleNumber>91234567</exampleNumber>
13093       </mobile>
13094       <tollFree>
13095         <!-- Adding extra prefix 180021 used by tollfreetc.com.kh. -->
13096         <nationalNumberPattern>
13097           1800(?:
13098             1\d|
13099             2[019]
13100           )\d{4}
13101         </nationalNumberPattern>
13102         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13103         <exampleNumber>1800123456</exampleNumber>
13104       </tollFree>
13105       <premiumRate>
13106         <nationalNumberPattern>
13107           1900(?:
13108             1\d|
13109             2[09]
13110           )\d{4}
13111         </nationalNumberPattern>
13112         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13113         <exampleNumber>1900123456</exampleNumber>
13114       </premiumRate>
13115     </territory>
13116
13117     <!-- Kiribati -->
13118     <!-- We include the national prefix for parsing here just in case numbers can be dialled with a
13119          leading 0 - no numbers online have been found formatted this way, but the ITU document
13120          lists it as a national dialling prefix. -->
13121     <territory id="KI" countryCode="686" internationalPrefix="00"
13122                nationalPrefixForParsing="0">
13123       <references>
13124         <sourceUrl>http://www.itu.int/oth/T0202000071/en</sourceUrl>
13125       </references>
13126       <!-- Numbers should be formatted as a block." -->
13127       <generalDesc>
13128         <nationalNumberPattern>
13129           [2458]\d{4}|
13130           3\d{4,7}|
13131           7\d{7}
13132         </nationalNumberPattern>
13133         <possibleNumberPattern>\d{5,8}</possibleNumberPattern>
13134       </generalDesc>
13135       <fixedLine>
13136         <nationalNumberPattern>
13137           (?:
13138             [24]\d|
13139             3[1-9]|
13140             50|
13141             8[0-5]
13142           )\d{3}
13143         </nationalNumberPattern>
13144         <possibleNumberPattern>\d{5}</possibleNumberPattern>
13145         <exampleNumber>31234</exampleNumber>
13146       </fixedLine>
13147       <mobile>
13148         <!-- North Tarawa is listed as 720XXXXX-729XXXXX but considering that this deviates from the
13149              pattern followed by every other place, we are assuming 731XXXXX-732XXXXX for now. -->
13150         <nationalNumberPattern>
13151           7(?:
13152             [24]\d|
13153             3[1-9]|
13154             8[0-5]
13155           )\d{5}
13156         </nationalNumberPattern>
13157         <possibleNumberPattern>\d{8}</possibleNumberPattern>
13158         <exampleNumber>72012345</exampleNumber>
13159       </mobile>
13160       <premiumRate>
13161         <!-- ITU refers to these as "Telemedia and audiotext". -->
13162         <nationalNumberPattern>3001\d{4}</nationalNumberPattern>
13163         <exampleNumber>30010000</exampleNumber>
13164       </premiumRate>
13165     </territory>
13166
13167     <!-- Comoros -->
13168     <territory id="KM" countryCode="269" internationalPrefix="00">
13169       <references>
13170         <sourceUrl>http://www.itu.int/oth/T020200002D/en</sourceUrl>
13171       </references>
13172       <availableFormats>
13173         <numberFormat pattern="(\d{3})(\d{2})(\d{2})">
13174           <format>$1 $2 $3</format>
13175         </numberFormat>
13176       </availableFormats>
13177       <generalDesc>
13178         <nationalNumberPattern>[379]\d{6}</nationalNumberPattern>
13179         <possibleNumberPattern>\d{7}</possibleNumberPattern>
13180       </generalDesc>
13181       <fixedLine>
13182         <!-- CDMA phones are included here, as they are considered as an extension of fixed line:
13183              http://www.comorestelecom.km/presentationcdma.php -->
13184         <nationalNumberPattern>
13185           7(?:
13186             6[0-37-9]|
13187             7[0-57-9]
13188           )\d{4}
13189         </nationalNumberPattern>
13190         <exampleNumber>7712345</exampleNumber>
13191       </fixedLine>
13192       <mobile>
13193         <nationalNumberPattern>3[234]\d{5}</nationalNumberPattern>
13194         <exampleNumber>3212345</exampleNumber>
13195       </mobile>
13196       <premiumRate>
13197         <!-- These are referred to as value-added services in the plan and no further information
13198              can be found. -->
13199         <nationalNumberPattern>
13200           (?:
13201             39[01]|
13202             9[01]0
13203           )\d{4}
13204         </nationalNumberPattern>
13205         <exampleNumber>9001234</exampleNumber>
13206       </premiumRate>
13207     </territory>
13208
13209     <!-- Saint Kitts and Nevis -->
13210     <territory id="KN" countryCode="1" leadingDigits="869" nationalPrefix="1"
13211                internationalPrefix="011">
13212       <references>
13213         <sourceUrl>http://www.itu.int/oth/T02020000B0/en</sourceUrl>
13214       </references>
13215       <generalDesc>
13216         <!-- NANPA country - uses US formatting rules -->
13217         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
13218         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
13219       </generalDesc>
13220       <fixedLine>
13221         <!-- Adding the 869 302 prefix as it is used by Marriott Hotels, even though no other record
13222              of it can be found. -->
13223         <nationalNumberPattern>
13224           869(?:
13225             2(?:
13226               29|
13227               36
13228             )|
13229             302|
13230             4(?:
13231               6[015-9]|
13232               70
13233             )
13234           )\d{4}
13235         </nationalNumberPattern>
13236         <exampleNumber>8692361234</exampleNumber>
13237       </fixedLine>
13238       <mobile>
13239         <!-- Added some more prefixes in the 66 and 76 range from online numbers. -->
13240         <nationalNumberPattern>
13241           869(?:
13242             5(?:
13243               5[6-8]|
13244               6[5-7]
13245             )|
13246             66\d|
13247             76[02-6]
13248           )\d{4}
13249         </nationalNumberPattern>
13250         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13251         <!-- Example number from the ITU document. -->
13252         <exampleNumber>8697652917</exampleNumber>
13253       </mobile>
13254       <tollFree>
13255         <nationalNumberPattern>
13256           8(?:
13257             00|
13258             44|
13259             55|
13260             66|
13261             77|
13262             88
13263           )[2-9]\d{6}
13264         </nationalNumberPattern>
13265         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13266         <exampleNumber>8002123456</exampleNumber>
13267       </tollFree>
13268       <premiumRate>
13269         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
13270         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13271         <exampleNumber>9002123456</exampleNumber>
13272       </premiumRate>
13273       <personalNumber>
13274         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
13275         <nationalNumberPattern>
13276           5(?:
13277             00|
13278             33|
13279             44|
13280             66|
13281             77
13282           )[2-9]\d{6}
13283         </nationalNumberPattern>
13284         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13285         <exampleNumber>5002345678</exampleNumber>
13286       </personalNumber>
13287     </territory>
13288
13289     <!-- Korea, Dem. People's Rep. of -->
13290     <territory id="KP" countryCode="850" internationalPrefix="00|99"
13291                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
13292       <references>
13293         <sourceUrl>http://en.wikipedia.org/wiki/%2B850</sourceUrl>
13294       </references>
13295       <availableFormats>
13296         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
13297           <leadingDigits>1</leadingDigits>
13298           <format>$1 $2 $3</format>
13299         </numberFormat>
13300         <numberFormat pattern="(\d)(\d{3})(\d{4})">
13301           <leadingDigits>2</leadingDigits>
13302           <format>$1 $2 $3</format>
13303         </numberFormat>
13304         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
13305           <leadingDigits>8</leadingDigits>
13306           <format>$1 $2 $3</format>
13307         </numberFormat>
13308       </availableFormats>
13309       <generalDesc>
13310         <nationalNumberPattern>
13311           1\d{9}|
13312           [28]\d{7}
13313         </nationalNumberPattern>
13314         <possibleNumberPattern>
13315           \d{6,8}|
13316           \d{10}
13317         </possibleNumberPattern>
13318       </generalDesc>
13319       <noInternationalDialling>
13320         <!-- For numbers starting with 2, only the 2381 range can be dialed internationally. -->
13321         <nationalNumberPattern>
13322           2(?:
13323             [0-24-9]\d{2}|
13324             3(?:
13325               [0-79]\d|
13326               8[02-9]
13327             )
13328           )\d{4}
13329         </nationalNumberPattern>
13330         <possibleNumberPattern>\d{8}</possibleNumberPattern>
13331         <exampleNumber>23821234</exampleNumber>
13332       </noInternationalDialling>
13333       <fixedLine>
13334         <!-- Covers only numbers from Pyongyang and Rason Economic Special Zone. According to
13335              wikipedia, other ranges of phone numbers are top secret, unpublished, and not dialable
13336              from overseas. Also, there is conflicting information about the length of fixed-line
13337              numbers, so here we are following Wikipedia. -->
13338         <nationalNumberPattern>
13339           2\d{7}|
13340           85\d{6}
13341         </nationalNumberPattern>
13342         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
13343         <exampleNumber>21234567</exampleNumber>
13344       </fixedLine>
13345       <mobile>
13346         <nationalNumberPattern>19[123]\d{7}</nationalNumberPattern>
13347         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13348         <exampleNumber>1921234567</exampleNumber>
13349       </mobile>
13350     </territory>
13351
13352     <!-- Korea (Rep. of) -->
13353     <!-- Exceptions :
13354         internationalPrefix
13355             0031, 0033, 0071, 0073 - Special services of KT and DACOM, ignorable
13356         nationalPrefix
13357             1[4-6]XX-YYYY - Country-wide common number services, display as it is without hyphens -->
13358     <territory id="KR" countryCode="82" internationalPrefix="00(?:[124-68]|[37]\d{2})"
13359                nationalPrefix="0" nationalPrefixForParsing="0(8[1-46-8]|85\d{2})?"
13360                nationalPrefixFormattingRule="$NP$FG" carrierCodeFormattingRule="$NP$CC-$FG"
13361                mobileNumberPortableRegion="true">
13362       <references>
13363         <sourceUrl>http://www.itu.int/oth/T0202000072/en</sourceUrl>
13364         <sourceUrl>http://en.wikipedia.org/wiki/%2B82</sourceUrl>
13365         <sourceUrl>http://www.kcc.go.kr/user.do?mode=view&amp;page=P02030300&amp;dc=K02030300&amp;boardId=1074&amp;boardSeq=2349</sourceUrl>
13366         <sourceUrl>http://www.kcc.go.kr/user.do?mode=view&amp;page=P02030300&amp;dc=K02030300&amp;boardId=1074&amp;boardSeq=2240</sourceUrl>
13367         <sourceUrl>http://www.telecentro.co.kr/sub/index.php?job=detail&amp;ebcf_id=faq&amp;page=1&amp;mid=0503&amp;eb_seq=36</sourceUrl>
13368       </references>
13369       <availableFormats>
13370         <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
13371           <leadingDigits>
13372             1(?:
13373               0|
13374               1[19]|
13375               [69]9|
13376               5[458]
13377             )|
13378             [57]0
13379           </leadingDigits>
13380           <leadingDigits>
13381             1(?:
13382               0|
13383               1[19]|
13384               [69]9|
13385               5(?:
13386                 44|
13387                 59|
13388                 8
13389               )
13390             )|
13391             [57]0
13392           </leadingDigits>
13393           <format>$1-$2-$3</format>
13394         </numberFormat>
13395         <numberFormat pattern="(\d{2})(\d{3,4})(\d{4})">
13396           <leadingDigits>
13397             1(?:
13398               [169][2-8]|
13399               [78]|
13400               5[1-4]
13401             )|
13402             [68]0|
13403             [3-6][1-9][1-9]
13404           </leadingDigits>
13405           <leadingDigits>
13406             1(?:
13407               [169][2-8]|
13408               [78]|
13409               5(?:
13410                 [1-3]|
13411                 4[56]
13412               )
13413             )|
13414             [68]0|
13415             [3-6][1-9][1-9]
13416           </leadingDigits>
13417           <format>$1-$2-$3</format>
13418         </numberFormat>
13419         <numberFormat pattern="(\d{3})(\d)(\d{4})">
13420           <leadingDigits>131</leadingDigits>
13421           <leadingDigits>1312</leadingDigits>
13422           <format>$1-$2-$3</format>
13423         </numberFormat>
13424         <numberFormat pattern="(\d{3})(\d{2})(\d{4})">
13425           <leadingDigits>131</leadingDigits>
13426           <leadingDigits>131[13-9]</leadingDigits>
13427           <format>$1-$2-$3</format>
13428         </numberFormat>
13429         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
13430           <leadingDigits>13[2-9]</leadingDigits>
13431           <format>$1-$2-$3</format>
13432         </numberFormat>
13433         <!-- 030 numbers are used for Unified Messaging Services, according to the plan. There is a
13434              limit of what digits may follow the 030, but we ignore that here. These numbers are
13435              actually not supported for validation purposes by the library at the moment as no
13436              online examples can be found, but we leave theme here so formatting continues to work
13437              if they are entered. -->
13438         <numberFormat pattern="(\d{2})(\d{2})(\d{3})(\d{4})">
13439           <leadingDigits>30</leadingDigits>
13440           <format>$1-$2-$3-$4</format>
13441         </numberFormat>
13442         <numberFormat pattern="(\d)(\d{3,4})(\d{4})">
13443           <leadingDigits>2[1-9]</leadingDigits>
13444           <format>$1-$2-$3</format>
13445         </numberFormat>
13446         <numberFormat pattern="(\d)(\d{3,4})">
13447           <leadingDigits>21[0-46-9]</leadingDigits>
13448           <format>$1-$2</format>
13449         </numberFormat>
13450         <numberFormat pattern="(\d{2})(\d{3,4})">
13451           <leadingDigits>[3-6][1-9]1</leadingDigits>
13452           <leadingDigits>
13453             [3-6][1-9]1(?:
13454               [0-46-9]
13455             )
13456           </leadingDigits>
13457           <format>$1-$2</format>
13458         </numberFormat>
13459         <!-- Company numbers. -->
13460         <numberFormat pattern="(\d{4})(\d{4})"
13461           nationalPrefixFormattingRule="$FG">
13462           <leadingDigits>
13463             1(?:
13464               5[46-9]|
13465               6[04678]|
13466               8[0579]
13467             )
13468           </leadingDigits>
13469           <leadingDigits>
13470             1(?:
13471               5(?:
13472                 44|
13473                 66|
13474                 77|
13475                 88|
13476                 99
13477               )|
13478               6(?:
13479                 00|
13480                 44|
13481                 6[16]|
13482                 70|
13483                 88
13484               )|
13485               8(?:
13486                 00|
13487                 55|
13488                 77|
13489                 99
13490               )
13491             )
13492           </leadingDigits>
13493           <format>$1-$2</format>
13494         </numberFormat>
13495       </availableFormats>
13496       <generalDesc>
13497         <nationalNumberPattern>
13498           [1-7]\d{3,9}|
13499           8\d{8}
13500         </nationalNumberPattern>
13501         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
13502       </generalDesc>
13503       <fixedLine>
13504         <!-- We omit 049, supposedly for Kaesong Industrial Region, since real numbers can't be
13505              found, and it is in North Korea anyway. We support 7-8 digits long subscriber numbers
13506              starting with 1 based on evidence of real numbers found online. -->
13507         <nationalNumberPattern>
13508           (?:
13509             2|
13510             3[1-3]|
13511             [46][1-4]|
13512             5[1-5]
13513           )(?:
13514             1\d{2,3}|
13515             [1-9]\d{6,7}
13516           )
13517         </nationalNumberPattern>
13518         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
13519         <exampleNumber>22123456</exampleNumber>
13520       </fixedLine>
13521       <mobile>
13522         <nationalNumberPattern>1[0-26-9]\d{7,8}</nationalNumberPattern>
13523         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
13524         <exampleNumber>1000000000</exampleNumber>
13525       </mobile>
13526       <pager>
13527         <nationalNumberPattern>15\d{7,8}</nationalNumberPattern>
13528         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
13529         <exampleNumber>1523456789</exampleNumber>
13530       </pager>
13531       <tollFree>
13532         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
13533         <possibleNumberPattern>\d{9}</possibleNumberPattern>
13534         <exampleNumber>801234567</exampleNumber>
13535       </tollFree>
13536       <!-- The information below is provided by a Korean person. -->
13537       <premiumRate>
13538         <nationalNumberPattern>60[2-9]\d{6}</nationalNumberPattern>
13539         <possibleNumberPattern>\d{9}</possibleNumberPattern>
13540         <exampleNumber>602345678</exampleNumber>
13541       </premiumRate>
13542       <personalNumber>
13543         <nationalNumberPattern>50\d{8}</nationalNumberPattern>
13544         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13545         <exampleNumber>5012345678</exampleNumber>
13546       </personalNumber>
13547       <voip>
13548         <nationalNumberPattern>70\d{8}</nationalNumberPattern>
13549         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13550         <exampleNumber>7012345678</exampleNumber>
13551       </voip>
13552       <uan>
13553         <!-- Prefix 18 added from numbers found online. -->
13554         <nationalNumberPattern>
13555           1(?:
13556             5(?:
13557               44|
13558               66|
13559               77|
13560               88|
13561               99
13562             )|
13563             6(?:
13564               00|
13565               44|
13566               6[16]|
13567               70|
13568               88
13569             )|
13570             8(?:
13571               00|
13572               55|
13573               77|
13574               99
13575             )
13576           )\d{4}
13577         </nationalNumberPattern>
13578         <possibleNumberPattern>\d{8}</possibleNumberPattern>
13579         <exampleNumber>15441234</exampleNumber>
13580       </uan>
13581     </territory>
13582
13583     <!-- Kuwait -->
13584     <territory id="KW" countryCode="965" internationalPrefix="00" mobileNumberPortableRegion="true">
13585       <references>
13586         <sourceUrl>http://www.itu.int/oth/T0202000073/en</sourceUrl>
13587       </references>
13588       <availableFormats>
13589         <!-- Format is from ITU. -->
13590         <numberFormat pattern="(\d{4})(\d{3,4})">
13591           <leadingDigits>[1269]</leadingDigits>
13592           <format>$1 $2</format>
13593         </numberFormat>
13594         <numberFormat pattern="(5[015]\d)(\d{5})">
13595           <leadingDigits>5</leadingDigits>
13596           <format>$1 $2</format>
13597         </numberFormat>
13598       </availableFormats>
13599       <generalDesc>
13600         <nationalNumberPattern>[12569]\d{6,7}</nationalNumberPattern>
13601         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
13602       </generalDesc>
13603       <fixedLine>
13604         <nationalNumberPattern>
13605           (?:
13606             18\d|
13607             2(?:
13608               [23]\d{2}|
13609               4(?:
13610                 [1-35-9]\d|
13611                 44
13612               )|
13613               5(?:
13614                 0[034]|
13615                 [2-46]\d|
13616                 5[1-3]|
13617                 7[1-7]
13618               )
13619             )
13620           )\d{4}
13621         </nationalNumberPattern>
13622         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
13623         <exampleNumber>22345678</exampleNumber>
13624       </fixedLine>
13625       <mobile>
13626         <nationalNumberPattern>
13627           (?:
13628             5(?:
13629               [05]\d|
13630               1[0-7]
13631             )|
13632             6(?:
13633               0[034679]|
13634               5[015-9]|
13635               6\d|
13636               7[067]|
13637               9[0369]
13638             )|
13639             9(?:
13640               0[09]|
13641               4[049]|
13642               55|
13643               6[069]|
13644               [79]\d|
13645               8[07-9]
13646             )
13647           )\d{5}
13648         </nationalNumberPattern>
13649         <possibleNumberPattern>\d{8}</possibleNumberPattern>
13650         <exampleNumber>50012345</exampleNumber>
13651       </mobile>
13652       <!-- No tollFree or premiumRate information can be found. -->
13653     </territory>
13654
13655     <!-- Cayman Islands -->
13656     <territory id="KY" countryCode="1" leadingDigits="345" nationalPrefix="1"
13657                internationalPrefix="011">
13658       <references>
13659         <sourceUrl>http://www.itu.int/oth/T0202000027/en</sourceUrl>
13660       </references>
13661       <generalDesc>
13662         <!-- NANPA country - uses US formatting rules -->
13663         <nationalNumberPattern>[3589]\d{9}</nationalNumberPattern>
13664         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
13665       </generalDesc>
13666       <!-- The 800 NXX code is listed as being "national only", but we successfully reached numbers
13667            from Switzerland with this prefix so do not list it as noInternationalDialling. -->
13668       <fixedLine>
13669         <!-- The Westtel numbers in the plan seem now to be live and assigned to fixed-line phones,
13670              as per numbers found online and their website http://www.logic.ky. -->
13671         <nationalNumberPattern>
13672           345(?:
13673             2(?:
13674               22|
13675               44
13676             )|
13677             444|
13678             6(?:
13679               23|
13680               38|
13681               40
13682             )|
13683             7(?:
13684               4[35-79]|
13685               6[6-9]|
13686               77
13687             )|
13688             8(?:
13689               00|
13690               1[45]|
13691               25|
13692               [48]8
13693             )|
13694             9(?:
13695               14|
13696               4[035-9]
13697             )
13698           )\d{4}
13699         </nationalNumberPattern>
13700         <exampleNumber>3452221234</exampleNumber>
13701       </fixedLine>
13702       <mobile>
13703         <!-- Adding central office codes 321, 322, 328, 576, 923 & 936 from numbers found online.
13704              Most central office codes that were surrendered have not been included, with the
13705              exception of 546 where numbers have been found. -->
13706         <nationalNumberPattern>
13707           345(?:
13708             32[1-9]|
13709             5(?:
13710               1[67]|
13711               2[5-7]|
13712               4[6-8]|
13713               76
13714             )|
13715             9(?:
13716               1[67]|
13717               2[3-9]|
13718               3[689]
13719             )
13720           )\d{4}
13721         </nationalNumberPattern>
13722         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13723         <exampleNumber>3453231234</exampleNumber>
13724       </mobile>
13725       <pager>
13726         <nationalNumberPattern>345849\d{4}</nationalNumberPattern>
13727         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13728         <exampleNumber>3458491234</exampleNumber>
13729       </pager>
13730       <tollFree>
13731         <nationalNumberPattern>
13732           8(?:
13733             00|
13734             44|
13735             55|
13736             66|
13737             77|
13738             88
13739           )[2-9]\d{6}
13740         </nationalNumberPattern>
13741         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13742         <exampleNumber>8002345678</exampleNumber>
13743       </tollFree>
13744       <premiumRate>
13745         <nationalNumberPattern>
13746           900[2-9]\d{6}|
13747           345976\d{4}
13748         </nationalNumberPattern>
13749         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13750         <exampleNumber>9002345678</exampleNumber>
13751       </premiumRate>
13752       <personalNumber>
13753         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
13754         <nationalNumberPattern>
13755           5(?:
13756             00|
13757             33|
13758             44|
13759             66|
13760             77
13761           )[2-9]\d{6}
13762         </nationalNumberPattern>
13763         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13764         <exampleNumber>5002345678</exampleNumber>
13765       </personalNumber>
13766     </territory>
13767
13768     <!-- Kazakhstan -->
13769     <territory id="KZ" countryCode="7" preferredInternationalPrefix="8~10"
13770                internationalPrefix="810" nationalPrefix="8">
13771       <references>
13772         <sourceUrl>http://www.itu.int/oth/T020200006F/en</sourceUrl>
13773       </references>
13774        <!-- Formatting rules obtained from Russia. -->
13775       <generalDesc>
13776         <!-- We make this as specific as possible to overlap as little as possible with Russia, so
13777              determining the country is faster. -->
13778         <nationalNumberPattern>
13779           (?:
13780             33\d|
13781             7\d{2}|
13782             80[09]
13783           )\d{7}
13784         </nationalNumberPattern>
13785         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13786       </generalDesc>
13787       <noInternationalDialling>
13788         <nationalNumberPattern>751\d{7}</nationalNumberPattern>
13789         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13790         <exampleNumber>7511234567</exampleNumber>
13791       </noInternationalDialling>
13792       <fixedLine>
13793         <!-- VSAT numbers are also included here. We also include the area code for Baikonur (336
13794              22), which is within Kazakhstan but in fact rented and administered by Russia at the
13795              moment. -->
13796         <nationalNumberPattern>
13797           33622\d{5}|
13798           7(?:
13799             1(?:
13800               0(?:
13801                 [23]\d|
13802                 4[023]|
13803                 59|
13804                 63
13805               )|
13806               1(?:
13807                 [23]\d|
13808                 4[0-79]|
13809                 59
13810               )|
13811               2(?:
13812                 [23]\d|
13813                 59
13814               )|
13815               3(?:
13816                 2\d|
13817                 3[1-79]|
13818                 4[0-35-9]|
13819                 59
13820               )|
13821               4(?:
13822                 2\d|
13823                 3[013-79]|
13824                 4[0-8]|
13825                 5[1-79]
13826               )|
13827               5(?:
13828                 2\d|
13829                 3[1-8]|
13830                 4[1-7]|
13831                 59
13832               )|
13833               6(?:
13834                 [234]\d|
13835                 5[19]|
13836                 61
13837               )|
13838               72\d|
13839               8(?:
13840                 [27]\d|
13841                 3[1-46-9]|
13842                 4[0-5]
13843               )
13844             )|
13845             2(?:
13846               1(?:
13847                 [23]\d|
13848                 4[46-9]|
13849                 5[3469]
13850               )|
13851               2(?:
13852                 2\d|
13853                 3[0679]|
13854                 46|
13855                 5[12679]
13856               )|
13857               3(?:
13858                 [234]\d|
13859                 5[139]
13860               )|
13861               4(?:
13862                 2\d|
13863                 3[1235-9]|
13864                 59
13865               )|
13866               5(?:
13867                 [23]\d|
13868                 4[01246-8]|
13869                 59|
13870                 61
13871               )|
13872               6(?:
13873                 2\d|
13874                 3[1-9]|
13875                 4[0-4]|
13876                 59
13877               )|
13878               7(?:
13879                 [237]\d|
13880                 40|
13881                 5[279]
13882               )|
13883               8(?:
13884                 [23]\d|
13885                 4[0-3]|
13886                 59
13887               )|
13888               9(?:
13889                 2\d|
13890                 3[124578]|
13891                 59
13892               )
13893             )
13894           )\d{5}
13895         </nationalNumberPattern>
13896         <exampleNumber>7123456789</exampleNumber>
13897       </fixedLine>
13898       <mobile>
13899         <!-- Added 708 for Altel, 776 for Beeline, 747 for Tele2. -->
13900         <nationalNumberPattern>
13901           7(?:
13902             0[012578]|
13903             47|
13904             6[02-4]|
13905             7[15-8]|
13906             85
13907           )\d{7}
13908         </nationalNumberPattern>
13909         <exampleNumber>7710009998</exampleNumber>
13910       </mobile>
13911       <tollFree>
13912         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
13913         <exampleNumber>8001234567</exampleNumber>
13914       </tollFree>
13915       <premiumRate>
13916         <nationalNumberPattern>809\d{7}</nationalNumberPattern>
13917         <exampleNumber>8091234567</exampleNumber>
13918       </premiumRate>
13919       <voip>
13920         <nationalNumberPattern>751\d{7}</nationalNumberPattern>
13921         <exampleNumber>7511234567</exampleNumber>
13922       </voip>
13923     </territory>
13924
13925     <!-- Lao People's Dem. Rep. -->
13926     <territory id="LA" countryCode="856" internationalPrefix="00"
13927                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
13928       <references>
13929         <!-- Seems incomplete -->
13930         <sourceUrl>http://www.itu.int/oth/T0202000075/en</sourceUrl>
13931         <sourceUrl>http://en.wikipedia.org/wiki/+856</sourceUrl>
13932       </references>
13933       <availableFormats>
13934         <numberFormat pattern="(20)(\d{2})(\d{3})(\d{3})">
13935           <leadingDigits>20</leadingDigits>
13936           <format>$1 $2 $3 $4</format>
13937         </numberFormat>
13938         <numberFormat pattern="([2-8]\d)(\d{3})(\d{3})">
13939           <leadingDigits>
13940             2[13]|
13941             3[14]|
13942             [4-8]
13943           </leadingDigits>
13944           <format>$1 $2 $3</format>
13945         </numberFormat>
13946         <numberFormat pattern="(30)(\d{2})(\d{2})(\d{3})">
13947           <leadingDigits>30</leadingDigits>
13948           <format>$1 $2 $3 $4</format>
13949         </numberFormat>
13950       </availableFormats>
13951       <generalDesc>
13952         <nationalNumberPattern>[2-8]\d{7,9}</nationalNumberPattern>
13953         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
13954       </generalDesc>
13955       <fixedLine>
13956         <!-- The Lonely Planet says that newer WIN phones (fixed phones without a physical landline)
13957              start with 030 (and are longer). There are plenty of examples online. -->
13958         <nationalNumberPattern>
13959           (?:
13960             2[13]|
13961             3(?:
13962               0\d|
13963               [14]
13964             )|
13965             [5-7][14]|
13966             41|
13967             8[1468]
13968           )\d{6}
13969         </nationalNumberPattern>
13970         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
13971         <exampleNumber>21212862</exampleNumber>
13972       </fixedLine>
13973       <mobile>
13974         <!-- Adding 202[89], 205[89], 207[68] and 209[15-7] from numbers found online. -->
13975         <nationalNumberPattern>
13976           20(?:
13977             2[2389]|
13978             5[4-689]|
13979             7[6-8]|
13980             9[15-9]
13981           )\d{6}
13982         </nationalNumberPattern>
13983         <possibleNumberPattern>\d{10}</possibleNumberPattern>
13984         <exampleNumber>2023123456</exampleNumber>
13985       </mobile>
13986       <!-- No information on other types of phone numbers for Lao P.D.R. has been found. -->
13987     </territory>
13988
13989     <!-- Lebanon -->
13990     <territory id="LB" countryCode="961" internationalPrefix="00" nationalPrefix="0">
13991       <references>
13992         <sourceUrl>http://www.itu.int/oth/T0202000077/en</sourceUrl>
13993         <sourceUrl>http://en.wikipedia.org/wiki/%2B961</sourceUrl>
13994       </references>
13995       <availableFormats>
13996         <numberFormat pattern="(\d)(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
13997           <leadingDigits>
13998             [13-6]|
13999             7(?:
14000               [2-579]|
14001               62|
14002               8[0-7]
14003             )|
14004             [89][2-9]
14005             </leadingDigits>
14006           <format>$1 $2 $3</format>
14007         </numberFormat>
14008         <numberFormat pattern="([7-9]\d)(\d{3})(\d{3})">
14009           <leadingDigits>
14010             [89][01]|
14011             7(?:
14012               [019]|
14013               6[013-9]|
14014               8[89]
14015             )
14016           </leadingDigits>
14017           <format>$1 $2 $3</format>
14018         </numberFormat>
14019       </availableFormats>
14020       <generalDesc>
14021         <nationalNumberPattern>[13-9]\d{6,7}</nationalNumberPattern>
14022         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
14023       </generalDesc>
14024       <fixedLine>
14025         <!-- The ITU document from October 2012 seems to have accidentally dropped the 79 prefix for
14026              fixed-line numbers, which had been in the version from July 2012. We consider these
14027              valid since we successfully dialed such a number in July 2014. -->
14028         <nationalNumberPattern>
14029           (?:
14030             [14-6]\d{2}|
14031             7(?:
14032               [2-579]\d|
14033               62|
14034               8[0-7]
14035             )|
14036             [89][2-9]\d
14037           )\d{4}
14038         </nationalNumberPattern>
14039         <possibleNumberPattern>\d{7}</possibleNumberPattern>
14040         <exampleNumber>1123456</exampleNumber>
14041       </fixedLine>
14042       <mobile>
14043         <!-- We only validate the first three digits here, since the ranges are growing rapidly.
14044              The 79[02-9] prefixes were added from bug reports and numbers found online. -->
14045         <nationalNumberPattern>
14046           (?:
14047             3\d|
14048             7(?:
14049               [019]\d|
14050               6[013-9]|
14051               8[89]
14052             )
14053           )\d{5}
14054         </nationalNumberPattern>
14055         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
14056         <exampleNumber>71123456</exampleNumber>
14057       </mobile>
14058       <premiumRate>
14059         <nationalNumberPattern>9[01]\d{6}</nationalNumberPattern>
14060         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14061         <exampleNumber>90123456</exampleNumber>
14062       </premiumRate>
14063       <sharedCost>
14064         <nationalNumberPattern>8[01]\d{6}</nationalNumberPattern>
14065         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14066         <exampleNumber>80123456</exampleNumber>
14067       </sharedCost>
14068     </territory>
14069
14070     <!-- Saint Lucia -->
14071     <territory id="LC" countryCode="1" leadingDigits="758" nationalPrefix="1"
14072                internationalPrefix="011">
14073       <references>
14074         <sourceUrl>http://www.itu.int/oth/T02020000B1/en</sourceUrl>
14075       </references>
14076       <generalDesc>
14077         <!-- NANPA country - uses US formatting rules -->
14078         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
14079         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
14080       </generalDesc>
14081       <fixedLine>
14082         <!-- Adding 430 since numbers have been found with these prefixes online. -->
14083         <nationalNumberPattern>
14084           758(?:
14085             4(?:
14086               30|
14087               5[0-9]|
14088               6[2-9]|
14089               8[0-2]
14090             )|
14091             57[0-2]|
14092             638
14093           )\d{4}
14094         </nationalNumberPattern>
14095         <exampleNumber>7584305678</exampleNumber>
14096       </fixedLine>
14097       <mobile>
14098         <nationalNumberPattern>
14099           758(?:
14100             28[4-7]|
14101             384|
14102             4(?:
14103               6[01]|
14104               8[4-9]
14105             )|
14106             5(?:
14107               1[89]|
14108               20|
14109               84
14110             )|
14111             7(?:
14112               1[2-9]|
14113               2[0-8]
14114             )
14115           )\d{4}
14116         </nationalNumberPattern>
14117         <possibleNumberPattern>\d{10}</possibleNumberPattern>
14118         <exampleNumber>7582845678</exampleNumber>
14119       </mobile>
14120       <tollFree>
14121         <nationalNumberPattern>
14122           8(?:
14123             00|
14124             44|
14125             55|
14126             66|
14127             77|
14128             88
14129           )[2-9]\d{6}
14130         </nationalNumberPattern>
14131         <possibleNumberPattern>\d{10}</possibleNumberPattern>
14132         <exampleNumber>8002123456</exampleNumber>
14133       </tollFree>
14134       <premiumRate>
14135         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
14136         <possibleNumberPattern>\d{10}</possibleNumberPattern>
14137         <exampleNumber>9002123456</exampleNumber>
14138       </premiumRate>
14139       <personalNumber>
14140         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
14141         <nationalNumberPattern>
14142           5(?:
14143             00|
14144             33|
14145             44|
14146             66|
14147             77
14148           )[2-9]\d{6}
14149         </nationalNumberPattern>
14150         <possibleNumberPattern>\d{10}</possibleNumberPattern>
14151         <exampleNumber>5002345678</exampleNumber>
14152       </personalNumber>
14153     </territory>
14154
14155     <!-- Liechtenstein -->
14156     <!-- The national prefix of "0" is only used for 0800 and 0900 numbers. -->
14157     <territory id="LI" countryCode="423" internationalPrefix="00" nationalPrefix="0">
14158       <references>
14159         <sourceUrl>http://www.llv.li/#/11193</sourceUrl>
14160         <sourceUrl>https://www.itu.int/oth/T020200007B/en</sourceUrl>
14161       </references>
14162       <availableFormats>
14163         <!-- Some different patterns for tollfree and shared cost numbers may be found by searching
14164              for "Mehrwertnummer" at http://www.telecom.li. -->
14165         <!-- Number format for National mobile services ,  Fixed line , Toll Free , uan and Premium rate services -->
14166         <numberFormat pattern="(\d{3})(\d{4})">
14167           <leadingDigits>[23789]</leadingDigits>
14168           <format>$1 $2</format>
14169         </numberFormat>
14170         <!-- Number format for International mobile services -->
14171         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
14172           <leadingDigits>6[56]</leadingDigits>
14173           <format>$1 $2 $3</format>
14174         </numberFormat>
14175         <!-- Number format for Voicemail services -->
14176         <numberFormat pattern="(69)(7\d{2})(\d{4})">
14177           <leadingDigits>697</leadingDigits>
14178           <format>$1 $2 $3</format>
14179         </numberFormat>
14180       </availableFormats>
14181       <generalDesc>
14182         <nationalNumberPattern>
14183           6\d{8}|
14184           [23789]\d{6}
14185         </nationalNumberPattern>
14186         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
14187       </generalDesc>
14188       <fixedLine>
14189         <nationalNumberPattern>
14190           (?:
14191             2(?:
14192               01|
14193               1[27]|
14194               3\d|
14195               6[02-578]|
14196               96
14197             )|
14198             3(?:
14199               7[0135-7]|
14200               8[048]|
14201               9[0269]
14202             )
14203           )\d{4}
14204         </nationalNumberPattern>
14205         <possibleNumberPattern>\d{7}</possibleNumberPattern>
14206         <exampleNumber>2345678</exampleNumber>
14207       </fixedLine>
14208       <mobile>
14209         <nationalNumberPattern>
14210           6(?:
14211             51[01]|
14212             6(?:
14213               0[0-6]|
14214               2[016-9]|
14215               39
14216             )
14217           )\d{5}|
14218           7(?:
14219             [37-9]\d|
14220             42|
14221             56
14222           )\d{4}
14223         </nationalNumberPattern>
14224         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
14225         <exampleNumber>660234567</exampleNumber>
14226       </mobile>
14227       <!-- The prefix 809 seems to be used for AT&T and Verizon access lines from Liechtenstein,
14228            even though it doesn't appear in the plan. -->
14229       <tollFree>
14230         <nationalNumberPattern>
14231           80(?:
14232             02[28]|
14233             9\d{2}
14234           )\d{2}
14235         </nationalNumberPattern>
14236         <possibleNumberPattern>\d{7}</possibleNumberPattern>
14237         <exampleNumber>8002222</exampleNumber>
14238       </tollFree>
14239       <premiumRate>
14240         <nationalNumberPattern>
14241           90(?:
14242             02[258]|
14243             1(?:
14244               23|
14245               3[14]
14246             )|
14247             66[136]
14248           )\d{2}
14249         </nationalNumberPattern>
14250         <possibleNumberPattern>\d{7}</possibleNumberPattern>
14251         <exampleNumber>9002222</exampleNumber>
14252       </premiumRate>
14253       <uan>
14254         <nationalNumberPattern>
14255           870(?:
14256             28|
14257             87
14258           )\d{2}
14259         </nationalNumberPattern>
14260         <possibleNumberPattern>\d{7}</possibleNumberPattern>
14261         <exampleNumber>8702812</exampleNumber>
14262       </uan>
14263       <voicemail>
14264         <nationalNumberPattern>
14265           697(?:
14266             42|
14267             56|
14268             [7-9]\d
14269           )\d{4}
14270         </nationalNumberPattern>
14271         <possibleNumberPattern>\d{9}</possibleNumberPattern>
14272         <exampleNumber>697861234</exampleNumber>
14273       </voicemail>
14274     </territory>
14275
14276     <!-- Sri Lanka -->
14277     <territory id="LK" countryCode="94" internationalPrefix="00"
14278                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
14279       <references>
14280         <sourceUrl>http://en.wikipedia.org/wiki/%2B94</sourceUrl>
14281         <sourceUrl>http://www.itu.int/oth/T02020000C3/en</sourceUrl>
14282       </references>
14283       <availableFormats>
14284         <numberFormat pattern="(\d{2})(\d{1})(\d{6})">
14285           <leadingDigits>[1-689]</leadingDigits>
14286           <format>$1 $2 $3</format>
14287         </numberFormat>
14288         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
14289           <leadingDigits>7</leadingDigits>
14290           <format>$1 $2 $3</format>
14291         </numberFormat>
14292       </availableFormats>
14293       <generalDesc>
14294         <nationalNumberPattern>[1-9]\d{8}</nationalNumberPattern>
14295         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
14296       </generalDesc>
14297       <fixedLine>
14298         <nationalNumberPattern>
14299           (?:
14300             [189]1|
14301             2[13-7]|
14302             3[1-8]|
14303             4[157]|
14304             5[12457]|
14305             6[35-7]
14306           )[2-57]\d{6}
14307         </nationalNumberPattern>
14308         <exampleNumber>112345678</exampleNumber>
14309       </fixedLine>
14310       <mobile>
14311         <!-- Adding the prefix 76 for Dialog, based on information from open-source users. -->
14312         <nationalNumberPattern>7[125-8]\d{7}</nationalNumberPattern>
14313         <possibleNumberPattern>\d{9}</possibleNumberPattern>
14314         <exampleNumber>712345678</exampleNumber>
14315       </mobile>
14316     </territory>
14317
14318     <!-- Liberia -->
14319     <territory id="LR" countryCode="231" internationalPrefix="00"
14320                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
14321       <references>
14322         <sourceUrl>http://www.itu.int/oth/T0202000079/en</sourceUrl>
14323       </references>
14324       <availableFormats>
14325         <!-- Formatting from Ministry of Agriculture,
14326         http://www.moa.gov.lr/content.php?sub=Email&?related=Contacts -->
14327         <numberFormat pattern="(2\d)(\d{3})(\d{3})">
14328           <leadingDigits>2</leadingDigits>
14329           <format>$1 $2 $3</format>
14330         </numberFormat>
14331         <numberFormat pattern="([79]\d{2})(\d{3})(\d{3})">
14332           <leadingDigits>[79]</leadingDigits>
14333           <format>$1 $2 $3</format>
14334         </numberFormat>
14335         <numberFormat pattern="([4-6])(\d{3})(\d{3})">
14336           <leadingDigits>[4-6]</leadingDigits>
14337           <format>$1 $2 $3</format>
14338         </numberFormat>
14339         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
14340           <leadingDigits>[38]</leadingDigits>
14341           <format>$1 $2 $3</format>
14342         </numberFormat>
14343       </availableFormats>
14344       <generalDesc>
14345         <nationalNumberPattern>
14346           2\d{7}|
14347           [37-9]\d{8}|
14348           [45]\d{6}
14349         </nationalNumberPattern>
14350         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
14351       </generalDesc>
14352       <fixedLine>
14353         <nationalNumberPattern>2\d{7}</nationalNumberPattern>
14354         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14355         <exampleNumber>21234567</exampleNumber>
14356       </fixedLine>
14357       <mobile>
14358         <!-- West Africa Telecom seems to be a mobile company from their website. Adding Atlantic
14359              Wireless from the document, even though from online news reports it is not clear they
14360              are still operating. -->
14361         <nationalNumberPattern>
14362           (?:
14363             330\d|
14364             4[67]|
14365             5\d|
14366             77\d{2}|
14367             88\d{2}|
14368             994\d
14369           )\d{5}
14370         </nationalNumberPattern>
14371         <exampleNumber>770123456</exampleNumber>
14372       </mobile>
14373       <premiumRate>
14374         <!-- Telelinks and Interactive media service are listed under premium rate. -->
14375         <nationalNumberPattern>90[03]\d{6}</nationalNumberPattern>
14376         <possibleNumberPattern>\d{9}</possibleNumberPattern>
14377         <exampleNumber>900123456</exampleNumber>
14378       </premiumRate>
14379       <voip>
14380         <!-- The plan lists the following range as being assigned to TEMAS. On their homepage they
14381              say they are involved in the VoIP sector. Adding WASSCOM and Atlantic Realty &
14382              Investment Corporation here as well; no numbers can be found online, nor company
14383              information. -->
14384         <nationalNumberPattern>
14385           332(?:
14386             0[02]|
14387             5\d
14388           )\d{4}
14389         </nationalNumberPattern>
14390         <possibleNumberPattern>\d{9}</possibleNumberPattern>
14391         <exampleNumber>332001234</exampleNumber>
14392       </voip>
14393     </territory>
14394
14395     <!-- Lesotho -->
14396     <territory id="LS" countryCode="266" internationalPrefix="00">
14397       <references>
14398         <sourceUrl>http://www.itu.int/oth/T0202000078/en</sourceUrl>
14399       </references>
14400       <availableFormats>
14401         <!-- Formatting following yellow pages: http://www.yellowpages.co.ls -->
14402         <numberFormat pattern="(\d{4})(\d{4})">
14403           <format>$1 $2</format>
14404         </numberFormat>
14405       </availableFormats>
14406       <generalDesc>
14407         <nationalNumberPattern>[2568]\d{7}</nationalNumberPattern>
14408         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14409       </generalDesc>
14410       <fixedLine>
14411         <nationalNumberPattern>2\d{7}</nationalNumberPattern>
14412         <exampleNumber>22123456</exampleNumber>
14413       </fixedLine>
14414       <mobile>
14415         <nationalNumberPattern>[56]\d{7}</nationalNumberPattern>
14416         <exampleNumber>50123456</exampleNumber>
14417       </mobile>
14418       <tollFree>
14419         <nationalNumberPattern>800[256]\d{4}</nationalNumberPattern>
14420         <exampleNumber>80021234</exampleNumber>
14421       </tollFree>
14422     </territory>
14423
14424     <!-- Lithuania -->
14425     <!-- Note that Lithuania is switching to a national prefix of 0. We support
14426          both 0 and 8 when parsing until this switch is complete. -->
14427     <territory id="LT" countryCode="370" internationalPrefix="00"
14428                nationalPrefix="8" nationalPrefixForParsing="[08]"
14429                nationalPrefixFormattingRule="($NP-$FG)"
14430                nationalPrefixOptionalWhenFormatting="true" mobileNumberPortableRegion="true">
14431       <references>
14432         <sourceUrl>http://www.itu.int/oth/T020200007C/en</sourceUrl>
14433       </references>
14434       <!-- National Prefix formatting rule from http://www.yellowpages.lt -->
14435       <availableFormats>
14436         <!-- Two-digit area codes -->
14437         <numberFormat pattern="([34]\d)(\d{6})">
14438           <leadingDigits>
14439             37|
14440             4(?:
14441               1|
14442               5[45]|
14443               6[2-4]
14444             )
14445           </leadingDigits>
14446           <format>$1 $2</format>
14447         </numberFormat>
14448         <!-- Three-digit area codes -->
14449         <numberFormat pattern="([3-6]\d{2})(\d{5})">
14450           <leadingDigits>
14451             3[148]|
14452             4(?:
14453               [24]|
14454               6[09]
14455             )|
14456             528|
14457             6
14458           </leadingDigits>
14459           <format>$1 $2</format>
14460         </numberFormat>
14461         <numberFormat pattern="([7-9]\d{2})(\d{2})(\d{3})"
14462           nationalPrefixFormattingRule="$NP $FG">
14463           <leadingDigits>[7-9]</leadingDigits>
14464           <format>$1 $2 $3</format>
14465         </numberFormat>
14466         <numberFormat pattern="(5)(2\d{2})(\d{4})">
14467           <leadingDigits>52[0-79]</leadingDigits>
14468           <format>$1 $2 $3</format>
14469         </numberFormat>
14470       </availableFormats>
14471       <generalDesc>
14472         <nationalNumberPattern>[3-9]\d{7}</nationalNumberPattern>
14473         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14474       </generalDesc>
14475       <fixedLine>
14476         <nationalNumberPattern>
14477           (?:
14478             3[1478]|
14479             4[124-6]|
14480             52
14481           )\d{6}
14482         </nationalNumberPattern>
14483         <exampleNumber>31234567</exampleNumber>
14484       </fixedLine>
14485       <mobile>
14486         <nationalNumberPattern>6\d{7}</nationalNumberPattern>
14487         <exampleNumber>61234567</exampleNumber>
14488       </mobile>
14489       <tollFree>
14490         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
14491         <exampleNumber>80012345</exampleNumber>
14492       </tollFree>
14493       <premiumRate>
14494         <nationalNumberPattern>
14495           9(?:
14496             0[0239]|
14497             10
14498           )\d{5}
14499         </nationalNumberPattern>
14500         <exampleNumber>90012345</exampleNumber>
14501       </premiumRate>
14502       <personalNumber>
14503         <nationalNumberPattern>700\d{5}</nationalNumberPattern>
14504         <exampleNumber>70012345</exampleNumber>
14505       </personalNumber>
14506       <sharedCost>
14507         <nationalNumberPattern>808\d{5}</nationalNumberPattern>
14508         <exampleNumber>80812345</exampleNumber>
14509       </sharedCost>
14510       <uan>
14511         <!-- Including government service numbers here too. -->
14512         <nationalNumberPattern>70[67]\d{5}</nationalNumberPattern>
14513         <exampleNumber>70712345</exampleNumber>
14514       </uan>
14515     </territory>
14516
14517     <!-- Luxembourg -->
14518     <territory id="LU" countryCode="352" internationalPrefix="00"
14519                nationalPrefixForParsing="(15(?:0[06]|1[12]|35|4[04]|55|6[26]|77|88|99)\d)"
14520                carrierCodeFormattingRule="$CC $FG" mobileNumberPortableRegion="true">
14521       <references>
14522         <sourceUrl>http://www.ilr.public.lu/communications_electroniques/numerotation/index.html</sourceUrl>
14523       </references>
14524       <availableFormats>
14525         <!-- Patterns overlap because of variable number length. -->
14526         <numberFormat pattern="(\d{2})(\d{3})">
14527           <leadingDigits>
14528             [2-5]|
14529             7[1-9]|
14530             [89](?:
14531               [1-9]|
14532               0[2-9]
14533             )
14534           </leadingDigits>
14535           <format>$1 $2</format>
14536         </numberFormat>
14537         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
14538           <leadingDigits>
14539             [2-5]|
14540             7[1-9]|
14541             [89](?:
14542               [1-9]|
14543               0[2-9]
14544             )
14545           </leadingDigits>
14546           <format>$1 $2 $3</format>
14547         </numberFormat>
14548         <numberFormat pattern="(\d{2})(\d{2})(\d{3})">
14549           <leadingDigits>20</leadingDigits>
14550           <format>$1 $2 $3</format>
14551         </numberFormat>
14552         <!-- The pattern for 7-digit numbers starting with 20 here will never be reached - but since
14553              we want this pattern to apply for 8-digit numbers with a 20 prefix, we include 20 in
14554              the leading digits. This is also done for 9-10 digit numbers starting with 20 below.
14555              -->
14556         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{1,2})">
14557           <leadingDigits>
14558             2(?:
14559               [0367]|
14560               4[3-8]
14561             )
14562           </leadingDigits>
14563           <format>$1 $2 $3 $4</format>
14564         </numberFormat>
14565         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{3})">
14566           <leadingDigits>20</leadingDigits>
14567           <format>$1 $2 $3 $4</format>
14568         </numberFormat>
14569         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})(\d{1,2})">
14570           <leadingDigits>
14571             2(?:
14572               [0367]|
14573               4[3-8]
14574             )
14575           </leadingDigits>
14576           <format>$1 $2 $3 $4 $5</format>
14577         </numberFormat>
14578         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{1,4})">
14579           <leadingDigits>
14580             2(?:
14581               [12589]|
14582               4[12]
14583             )|
14584             [3-5]|
14585             7[1-9]|
14586             8(?:
14587               [1-9]|
14588               0[2-9]
14589             )|
14590             9(?:
14591               [1-9]|
14592               0[2-46-9]
14593             )
14594           </leadingDigits>
14595           <format>$1 $2 $3 $4</format>
14596         </numberFormat>
14597         <numberFormat pattern="(\d{3})(\d{2})(\d{3})">
14598           <leadingDigits>
14599             70|
14600             80[01]|
14601             90[015]
14602           </leadingDigits>
14603           <format>$1 $2 $3</format>
14604         </numberFormat>
14605         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
14606           <leadingDigits>6</leadingDigits>
14607           <format>$1 $2 $3</format>
14608         </numberFormat>
14609       </availableFormats>
14610       <generalDesc>
14611         <!-- The country-code is an impossible number prefix, so has been excluded here. This is
14612              necessary since the numbers have a variable number length. -->
14613         <nationalNumberPattern>
14614           [24-9]\d{3,10}|
14615           3(?:
14616             [0-46-9]\d{2,9}|
14617             5[013-9]\d{1,8}
14618           )
14619         </nationalNumberPattern>
14620         <possibleNumberPattern>\d{4,11}</possibleNumberPattern>
14621       </generalDesc>
14622       <fixedLine>
14623         <!-- Even though 20 is listed in the fixed-line plan, other documentation clarify that it is
14624              for VOIP. Furthermore, even though the plan says that numbers beginning with 2[346-8]
14625              by default are 8 digits, from information found online it seems that they can actually
14626              be 5, 6 or 7 digits long. -->
14627         <nationalNumberPattern>
14628           (?:
14629             2(?:
14630               [259]\d{2,9}|
14631               [346-8]\d{3,6}
14632             )|
14633             (?:
14634               [3457]\d{2}|
14635               8(?:
14636                 0[2-9]|
14637                 [13-9]\d
14638               )|
14639               9(?:
14640                 0[89]|
14641                 [2-579]\d
14642               )
14643             )\d{1,8}
14644           )
14645         </nationalNumberPattern>
14646         <exampleNumber>27123456</exampleNumber>
14647       </fixedLine>
14648       <mobile>
14649         <nationalNumberPattern>6[2679][18]\d{6}</nationalNumberPattern>
14650         <possibleNumberPattern>\d{9}</possibleNumberPattern>
14651         <exampleNumber>628123456</exampleNumber>
14652       </mobile>
14653       <tollFree>
14654         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
14655         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14656         <exampleNumber>80012345</exampleNumber>
14657       </tollFree>
14658       <premiumRate>
14659         <nationalNumberPattern>90[015]\d{5}</nationalNumberPattern>
14660         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14661         <exampleNumber>90012345</exampleNumber>
14662       </premiumRate>
14663       <sharedCost>
14664         <nationalNumberPattern>801\d{5}</nationalNumberPattern>
14665         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14666         <exampleNumber>80112345</exampleNumber>
14667       </sharedCost>
14668       <personalNumber>
14669         <nationalNumberPattern>70\d{6}</nationalNumberPattern>
14670         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14671         <exampleNumber>70123456</exampleNumber>
14672       </personalNumber>
14673       <voip>
14674         <!-- The document says the normal length will be 8 digits, but many numbers found online
14675              deviate from that. The prefixes from the following document have been added:
14676              http://www.ilr.public.lu/communications_electroniques/numerotation/plan_nat_num/numeros_geographiques_geo.pdf
14677              201 has also been added since a diallable number was found online, and it says in
14678              http://www.ilr.public.lu/communications_electroniques/decisions/2004/0479.pdf that no
14679              numbers will be issued that begin with 200, numbers beginning with 201 will be issued
14680              one at a time, and 202-209 in blocks. -->
14681         <nationalNumberPattern>
14682           20(?:
14683             1\d{5}|
14684             [2-689]\d{1,7}
14685           )
14686         </nationalNumberPattern>
14687         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
14688         <exampleNumber>20201234</exampleNumber>
14689       </voip>
14690     </territory>
14691
14692     <!-- Latvia -->
14693     <territory id="LV" countryCode="371" internationalPrefix="00" mobileNumberPortableRegion="true">
14694       <references>
14695         <sourceUrl>http://www.itu.int/oth/T0202000076/en</sourceUrl>
14696         <sourceUrl>http://en.wikipedia.org/wiki/+371</sourceUrl>
14697       </references>
14698       <availableFormats>
14699         <numberFormat pattern="([2689]\d)(\d{3})(\d{3})">
14700           <format>$1 $2 $3</format>
14701         </numberFormat>
14702       </availableFormats>
14703       <generalDesc>
14704         <nationalNumberPattern>[2689]\d{7}</nationalNumberPattern>
14705         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14706       </generalDesc>
14707       <fixedLine>
14708         <nationalNumberPattern>6[3-8]\d{6}</nationalNumberPattern>
14709         <exampleNumber>63123456</exampleNumber>
14710       </fixedLine>
14711       <mobile>
14712         <nationalNumberPattern>2\d{7}</nationalNumberPattern>
14713         <exampleNumber>21234567</exampleNumber>
14714       </mobile>
14715       <tollFree>
14716         <nationalNumberPattern>80\d{6}</nationalNumberPattern>
14717         <exampleNumber>80123456</exampleNumber>
14718       </tollFree>
14719       <premiumRate>
14720         <nationalNumberPattern>90\d{6}</nationalNumberPattern>
14721         <exampleNumber>90123456</exampleNumber>
14722       </premiumRate>
14723       <sharedCost>
14724         <nationalNumberPattern>81\d{6}</nationalNumberPattern>
14725         <exampleNumber>81123456</exampleNumber>
14726       </sharedCost>
14727     </territory>
14728
14729     <!-- Libya (Soc. People’s Libyan Arab Jamahiriya) -->
14730     <!-- Status as of 21 Jan 2011: a lot of outdated information on the web including on wikipedia
14731          and itu.int. The new area codes are on the Arabic website of the main telecommunication
14732          operator (Hatef Libya). A new mobile operator Aljeel Aljadeed for Technology will start
14733          using 096 (they are allowing customers to register numbers currently), so their code has
14734          also been added. -->
14735     <territory id="LY" countryCode="218" internationalPrefix="00"
14736                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
14737       <references>
14738         <sourceUrl>http://hlc.ly/price.php</sourceUrl>
14739       </references>
14740       <availableFormats>
14741         <numberFormat pattern="([25679]\d)(\d{7})">
14742           <format>$1-$2</format>
14743         </numberFormat>
14744       </availableFormats>
14745       <generalDesc>
14746         <nationalNumberPattern>[25679]\d{8}</nationalNumberPattern>
14747         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
14748       </generalDesc>
14749       <fixedLine>
14750         <nationalNumberPattern>
14751           (?:
14752             2[1345]|
14753             5[1347]|
14754             6[123479]|
14755             71
14756           )\d{7}
14757         </nationalNumberPattern>
14758         <exampleNumber>212345678</exampleNumber>
14759       </fixedLine>
14760       <mobile>
14761         <!-- The prefix 094 has been added on the strength of numbers found online, and numbers
14762              where SMS messages have been apparently successfully received. -->
14763         <nationalNumberPattern>9[1-6]\d{7}</nationalNumberPattern>
14764         <possibleNumberPattern>\d{9}</possibleNumberPattern>
14765         <exampleNumber>912345678</exampleNumber>
14766       </mobile>
14767     </territory>
14768
14769     <!-- Morocco -->
14770     <!-- Shares formatting and some metadata with Western Sahara. -->
14771     <territory id="MA" countryCode="212" internationalPrefix="00" nationalPrefix="0"
14772                nationalPrefixFormattingRule="$NP$FG" mainCountryForCode="true"
14773                mobileNumberPortableRegion="true">
14774       <references>
14775         <sourceUrl>http://www.itu.int/oth/T0202000090/en</sourceUrl>
14776         <sourceUrl>http://en.wikipedia.org/wiki/+212</sourceUrl>
14777       </references>
14778       <availableFormats>
14779         <numberFormat pattern="([56]\d{2})(\d{6})">
14780           <leadingDigits>
14781             5(?:
14782               2[015-7]|
14783               3[0-4]
14784             )|
14785             6
14786           </leadingDigits>
14787           <format>$1-$2</format>
14788         </numberFormat>
14789         <numberFormat pattern="([58]\d{3})(\d{5})">
14790           <leadingDigits>
14791             5(?:
14792               2[2-489]|
14793               3[5-9]
14794             )|
14795             892
14796           </leadingDigits>
14797           <leadingDigits>
14798             5(?:
14799               2(?:
14800                 [2-48]|
14801                 90
14802               )|
14803               3(?:
14804                 [5-79]|
14805                 80
14806               )
14807             )|
14808             892
14809           </leadingDigits>
14810           <format>$1-$2</format>
14811         </numberFormat>
14812         <numberFormat pattern="(5\d{4})(\d{4})">
14813           <leadingDigits>
14814             5(?:
14815               29|
14816               38
14817             )
14818           </leadingDigits>
14819           <leadingDigits>
14820             5(?:
14821               29|
14822               38
14823             )[89]
14824           </leadingDigits>
14825           <format>$1-$2</format>
14826         </numberFormat>
14827         <numberFormat pattern="(8[09])(\d{7})">
14828           <leadingDigits>
14829             8(?:
14830               0|
14831               9[013-9]
14832             )
14833           </leadingDigits>
14834           <format>$1-$2</format>
14835         </numberFormat>
14836       </availableFormats>
14837       <generalDesc>
14838         <nationalNumberPattern>[5689]\d{8}</nationalNumberPattern>
14839         <!-- Closed numbering plan. -->
14840         <possibleNumberPattern>\d{9}</possibleNumberPattern>
14841       </generalDesc>
14842       <fixedLine>
14843         <nationalNumberPattern>
14844           5(?:
14845             2(?:
14846               (?:
14847                 [015-7]\d|
14848                 2[2-9]|
14849                 3[2-57]|
14850                 4[2-8]|
14851                 8[235-7]
14852               )\d|
14853               9(?:
14854                 0\d|
14855                 [89]0
14856               )
14857             )|
14858             3(?:
14859               (?:
14860                 [0-4]\d|
14861                 [57][2-9]|
14862                 6[235-8]|
14863                 9[3-9]
14864               )\d|
14865               8(?:
14866                 0\d|
14867                 [89]0
14868               )
14869             )
14870           )\d{4}
14871         </nationalNumberPattern>
14872         <exampleNumber>520123456</exampleNumber>
14873       </fixedLine>
14874       <!-- Also duplicated in Western Sahara, please ensure you update both. -->
14875       <mobile>
14876         <!-- http://www.anrt.ma/sites/default/files/Blocs_de_numeros_par_operateur.pdf
14877              Prefixes 69[0136] added based on numbers found online. -->
14878         <nationalNumberPattern>
14879           6(?:
14880             0[0-8]|
14881             [12-79]\d|
14882             8[01]
14883           )\d{6}
14884         </nationalNumberPattern>
14885         <exampleNumber>650123456</exampleNumber>
14886       </mobile>
14887       <tollFree>
14888         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
14889         <exampleNumber>801234567</exampleNumber>
14890       </tollFree>
14891       <premiumRate>
14892         <nationalNumberPattern>89\d{7}</nationalNumberPattern>
14893         <exampleNumber>891234567</exampleNumber>
14894       </premiumRate>
14895     </territory>
14896
14897     <!-- Monaco -->
14898     <!-- We support Kosovo mobile numbers (044, 045) with a Monaco country-code here, as we do not
14899          support Kosovo at the moment. Kosovo seems to use a variety of country codes currently. It
14900          also seems that the national prefix is only used for mobile numbers, not fixed-line. -->
14901     <territory id="MC" countryCode="377" internationalPrefix="00"
14902                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
14903       <references>
14904         <sourceUrl>http://www.itu.int/oth/T020200008D/en</sourceUrl>
14905       </references>
14906       <availableFormats>
14907         <!-- Following formatting found online rather than in the ITU document example. -->
14908         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="$FG">
14909           <leadingDigits>9</leadingDigits>
14910           <format>$1 $2 $3 $4</format>
14911         </numberFormat>
14912         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
14913           <leadingDigits>4</leadingDigits>
14914           <format>$1 $2 $3</format>
14915         </numberFormat>
14916         <numberFormat pattern="(6)(\d{2})(\d{2})(\d{2})(\d{2})">
14917           <leadingDigits>6</leadingDigits>
14918           <format>$1 $2 $3 $4 $5</format>
14919         </numberFormat>
14920         <numberFormat pattern="(\d{3})(\d{3})(\d{2})" nationalPrefixFormattingRule="$FG">
14921           <leadingDigits>8</leadingDigits>
14922           <format>$1 $2 $3</format>
14923         </numberFormat>
14924       </availableFormats>
14925       <generalDesc>
14926         <nationalNumberPattern>[4689]\d{7,8}</nationalNumberPattern>
14927         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
14928       </generalDesc>
14929       <noInternationalDialling>
14930         <nationalNumberPattern>8\d{7}</nationalNumberPattern>
14931         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14932       </noInternationalDialling>
14933       <fixedLine>
14934         <!-- Restricted to this as no numbers with the prefix of 91, 95 or 96 have been found. -->
14935         <nationalNumberPattern>
14936           870\d{5}|
14937           9[2-47-9]\d{6}
14938         </nationalNumberPattern>
14939         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14940         <exampleNumber>99123456</exampleNumber>
14941       </fixedLine>
14942       <mobile>
14943         <!-- 4X mobile numbers are actually used by Kosovo. -->
14944         <nationalNumberPattern>
14945           6\d{8}|
14946           4(?:
14947             4\d|
14948             5[2-9]
14949           )\d{5}
14950         </nationalNumberPattern>
14951         <exampleNumber>612345678</exampleNumber>
14952       </mobile>
14953       <tollFree>
14954         <nationalNumberPattern>90\d{6}</nationalNumberPattern>
14955         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14956         <exampleNumber>90123456</exampleNumber>
14957       </tollFree>
14958     </territory>
14959
14960     <!-- Moldova, Rep. of -->
14961     <territory id="MD" countryCode="373" internationalPrefix="00"
14962                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
14963                mobileNumberPortableRegion="true">
14964       <references>
14965         <sourceUrl>http://www.itu.int/oth/T020200008C/en</sourceUrl>
14966         <!-- Announcements -->
14967         <sourceUrl>http://anrceti.md/fileupload/58</sourceUrl>
14968         <!-- Mobile ranges -->
14969         <sourceUrl>http://en.anrceti.md/resurse_numerotare_tel_mobila</sourceUrl>
14970       </references>
14971       <availableFormats>
14972         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
14973           <leadingDigits>
14974             22|
14975             3
14976           </leadingDigits>
14977           <format>$1 $2 $3</format>
14978         </numberFormat>
14979         <numberFormat pattern="([25-7]\d{2})(\d{2})(\d{3})">
14980           <leadingDigits>
14981             2[13-79]|
14982             [5-7]
14983           </leadingDigits>
14984           <format>$1 $2 $3</format>
14985         </numberFormat>
14986         <numberFormat pattern="([89]\d{2})(\d{5})">
14987           <leadingDigits>[89]</leadingDigits>
14988           <format>$1 $2</format>
14989         </numberFormat>
14990       </availableFormats>
14991       <generalDesc>
14992         <nationalNumberPattern>[235-9]\d{7}</nationalNumberPattern>
14993         <possibleNumberPattern>\d{8}</possibleNumberPattern>
14994       </generalDesc>
14995       <fixedLine>
14996         <nationalNumberPattern>
14997           (?:
14998             2(?:
14999               1[0569]|
15000               2\d|
15001               3[015-7]|
15002               4[1-46-9]|
15003               5[0-24689]|
15004               6[2-589]|
15005               7[1-37]|
15006               9[1347-9]
15007             )|
15008             5(?:
15009               33|
15010               5[257]
15011             )
15012           )\d{5}
15013         </nationalNumberPattern>
15014         <exampleNumber>22212345</exampleNumber>
15015       </fixedLine>
15016       <mobile>
15017         <!-- Includes prefixes for Interdnestrcom, http://www.idknet.com/. -->
15018         <nationalNumberPattern>
15019           (?:
15020             562\d|
15021             6(?:
15022               [089]\d{2}|
15023               1[01]\d|
15024               21\d|
15025               50\d|
15026               7(?:
15027                 [1-6]\d|
15028                 7[0-4]
15029               )
15030             )|
15031             7(?:
15032               6[07]|
15033               7[457-9]|
15034               [89]\d
15035             )\d
15036           )\d{4}
15037         </nationalNumberPattern>
15038         <exampleNumber>65012345</exampleNumber>
15039       </mobile>
15040       <tollFree>
15041         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
15042         <exampleNumber>80012345</exampleNumber>
15043       </tollFree>
15044       <premiumRate>
15045         <nationalNumberPattern>90[056]\d{5}</nationalNumberPattern>
15046         <exampleNumber>90012345</exampleNumber>
15047       </premiumRate>
15048       <!-- Information came from en.anrceti.md/node/81 -->
15049       <sharedCost>
15050         <nationalNumberPattern>808\d{5}</nationalNumberPattern>
15051         <exampleNumber>80812345</exampleNumber>
15052       </sharedCost>
15053       <uan>
15054         <!-- Includes numbers used for access to different transport directory services of general
15055              interest, since these are charged at the same rate as fixed-line numbers. -->
15056         <nationalNumberPattern>
15057           8(?:
15058             03|
15059             14
15060           )\d{5}
15061         </nationalNumberPattern>
15062         <exampleNumber>80312345</exampleNumber>
15063       </uan>
15064       <voip>
15065         <!-- Used for "nomadic numbers". -->
15066         <nationalNumberPattern>3[08]\d{6}</nationalNumberPattern>
15067         <exampleNumber>30123456</exampleNumber>
15068       </voip>
15069     </territory>
15070
15071     <!-- Montenegro -->
15072     <!-- According to EKIP, the detailed phone number assignments are published on their
15073          website (regulation:
15074          http://www.ekip.me/download/Law%20on%20Electronic%20Communications%20(updated)%204.9.2013%20(1)nova%20verzija.pdf
15075          ). Thus ITU updates always need to be combined with the information at the below ekip.me source URL. -->
15076     <territory id="ME" countryCode="382" internationalPrefix="00" nationalPrefix="0"
15077                nationalPrefixFormattingRule="$NP$FG">
15078       <references>
15079         <sourceUrl>http://www.itu.int/oth/T02020000DA/en</sourceUrl>
15080         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Montenegro</sourceUrl>
15081         <sourceUrl>http://www.ekip.me/numeracija/dodijeljena.php</sourceUrl>
15082       </references>
15083       <availableFormats>
15084          <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
15085           <leadingDigits>[2-57-9]|6[036-9]</leadingDigits>
15086           <leadingDigits>
15087             [2-57-9]|
15088             6(?:
15089               [03689]|
15090               7(?:
15091                 [0-8]|
15092                 9[3-9]
15093               )
15094             )
15095           </leadingDigits>
15096           <format>$1 $2 $3</format>
15097         </numberFormat>
15098         <numberFormat pattern="(67)(9)(\d{3})(\d{3})">
15099           <leadingDigits>679</leadingDigits>
15100           <leadingDigits>679[0-2]</leadingDigits>
15101           <format>$1 $2 $3 $4</format>
15102         </numberFormat>
15103       </availableFormats>
15104       <generalDesc>
15105         <nationalNumberPattern>[2-9]\d{7,8}</nationalNumberPattern>
15106         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
15107       </generalDesc>
15108       <fixedLine>
15109         <!-- Fixed line numbers have prefix 20,30,31,32,33,40,41,50,51,52 followed by 6 digits.
15110              The valid options for the third digit were from
15111              http://www.ekip.me/numeracija/dodijeljena.php -->
15112         <nationalNumberPattern>
15113           (?:
15114             20[2-8]|
15115             3(?:
15116               0[2-7]|
15117               [12][35-7]|
15118               3[4-7]
15119             )|
15120             4(?:
15121               0[2367]|
15122               1[267]
15123             )|
15124             5(?:
15125               0[467]|
15126               1[267]|
15127               2[367]
15128             )
15129           )\d{5}
15130         </nationalNumberPattern>
15131         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
15132         <exampleNumber>30234567</exampleNumber>
15133       </fixedLine>
15134       <mobile>
15135         <!-- Mobile numbers start with 600, 632, 661, 67, 68 or 69. -->
15136         <nationalNumberPattern>
15137           6(?:
15138             00\d|
15139             32\d|
15140             [89]\d{2}|
15141             61\d|
15142             7(?:
15143               [0-8]\d|
15144               9(?:
15145                 [3-9]|
15146                 [0-2]\d
15147               )
15148             )
15149           )\d{4}
15150         </nationalNumberPattern>
15151         <!-- According to ITU it is possible for the numbers to be between length 4-12
15152              (http://www.itu.int/oth/T02020000DA/en). However, in reality they seem to be 8 or 9
15153              digits long, based on the Montenegro document. -->
15154         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
15155         <exampleNumber>67622901</exampleNumber>
15156       </mobile>
15157       <tollFree>
15158         <!-- All toll free numbers have prefix 80. -->
15159         <nationalNumberPattern>80\d{6}</nationalNumberPattern>
15160         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15161         <exampleNumber>80080002</exampleNumber>
15162       </tollFree>
15163       <premiumRate>
15164         <!-- Numbers with prefix 94 or 95 are services with additional charges. -->
15165         <nationalNumberPattern>
15166           (?:
15167             9(?:
15168               4[1568]|
15169               5[178]
15170             )
15171           )\d{5}
15172         </nationalNumberPattern>
15173         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15174         <exampleNumber>94515151</exampleNumber>
15175       </premiumRate>
15176       <voip>
15177         <!-- VOIP are prefixed with 78. -->
15178         <nationalNumberPattern>78[1-9]\d{5}</nationalNumberPattern>
15179         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15180         <exampleNumber>78108780</exampleNumber>
15181       </voip>
15182       <uan>
15183         <!-- Corporate Telephony are prefixed with 77. -->
15184         <nationalNumberPattern>77\d{6}</nationalNumberPattern>
15185         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15186         <exampleNumber>77273012</exampleNumber>
15187       </uan>
15188     </territory>
15189
15190     <!-- Saint-Martin, French Antilles -->
15191     <territory id="MF" countryCode="590" internationalPrefix="00" nationalPrefix="0">
15192       <references>
15193         <sourceUrl>http://www.itu.int/oth/T0202000058/en</sourceUrl>
15194         <!-- Linked from http://www.arcep.fr/index.php?id=interactivenumeros -->
15195         <sourceUrl>http://www.arcep.fr/fileadmin/reprise/dossiers/numero/ZABPQ-ZNE.xls</sourceUrl>
15196       </references>
15197       <!-- Formatting rules borrowed from Guadeloupe. -->
15198       <generalDesc>
15199         <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
15200         <possibleNumberPattern>\d{9}</possibleNumberPattern>
15201       </generalDesc>
15202       <fixedLine>
15203         <nationalNumberPattern>
15204           590(?:
15205             [02][79]|
15206             13|
15207             5[0-268]|
15208             [78]7
15209           )\d{4}
15210         </nationalNumberPattern>
15211         <exampleNumber>590271234</exampleNumber>
15212       </fixedLine>
15213       <mobile>
15214         <!-- Any ranges assigned from
15215              http://www.arcep.fr/index.php?id=interactivenumeros have been listed as belonging to
15216              Guadeloupe, St Martin and St Barthélemy, since we can't reliably distinguish between
15217              them. -->
15218         <nationalNumberPattern>
15219           690(?:
15220             0[0-7]|
15221             [1-9]\d
15222           )\d{4}
15223         </nationalNumberPattern>
15224         <exampleNumber>690301234</exampleNumber>
15225       </mobile>
15226     </territory>
15227
15228     <!-- Madagascar -->
15229     <territory id="MG" countryCode="261" internationalPrefix="00"
15230                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
15231       <references>
15232         <sourceUrl>http://www.itu.int/oth/T020200007F/en</sourceUrl>
15233       </references>
15234       <availableFormats>
15235         <numberFormat pattern="([23]\d)(\d{2})(\d{3})(\d{2})">
15236           <format>$1 $2 $3 $4</format>
15237         </numberFormat>
15238       </availableFormats>
15239       <generalDesc>
15240         <nationalNumberPattern>[23]\d{8}</nationalNumberPattern>
15241         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
15242       </generalDesc>
15243       <fixedLine>
15244         <!-- Added the prefixes 20 44 and 20 47 as they seem popular on the internet - the plan says
15245              20 4 is for the rest of the province of Antanarivo, but then fails to mention any area
15246              codes beginning with 4. -->
15247         <nationalNumberPattern>
15248           20(?:
15249             2\d{2}|
15250             4[47]\d|
15251             5[3467]\d|
15252             6[279]\d|
15253             7(?:
15254               2[29]|
15255               [35]\d
15256             )|
15257             8[268]\d|
15258             9[245]\d
15259           )\d{4}
15260         </nationalNumberPattern>
15261         <exampleNumber>202123456</exampleNumber>
15262       </fixedLine>
15263       <mobile>
15264         <!-- The numbering plan suggests the third digit, Z, should be 24-9, but this is not borne
15265              out by reality. -->
15266         <nationalNumberPattern>3[2-49]\d{7}</nationalNumberPattern>
15267         <possibleNumberPattern>\d{9}</possibleNumberPattern>
15268         <exampleNumber>321234567</exampleNumber>
15269       </mobile>
15270       <!-- Putting VSAT numbers here. -->
15271       <voip>
15272         <nationalNumberPattern>22\d{7}</nationalNumberPattern>
15273         <possibleNumberPattern>\d{9}</possibleNumberPattern>
15274         <exampleNumber>221234567</exampleNumber>
15275       </voip>
15276     </territory>
15277
15278     <!-- Marshall Islands -->
15279     <territory id="MH" countryCode="692" internationalPrefix="011" nationalPrefix="1">
15280       <references>
15281         <sourceUrl>http://www.itu.int/oth/T0202000085/en</sourceUrl>
15282       </references>
15283       <availableFormats>
15284         <numberFormat pattern="(\d{3})(\d{4})">
15285           <format>$1-$2</format>
15286         </numberFormat>
15287       </availableFormats>
15288       <generalDesc>
15289         <nationalNumberPattern>[2-6]\d{6}</nationalNumberPattern>
15290         <possibleNumberPattern>\d{7}</possibleNumberPattern>
15291       </generalDesc>
15292       <fixedLine>
15293         <nationalNumberPattern>
15294           (?:
15295             247|
15296             528|
15297             625
15298           )\d{4}
15299         </nationalNumberPattern>
15300         <exampleNumber>2471234</exampleNumber>
15301       </fixedLine>
15302       <mobile>
15303         <nationalNumberPattern>
15304           (?:
15305             235|
15306             329|
15307             45[56]|
15308             545
15309           )\d{4}
15310         </nationalNumberPattern>
15311         <exampleNumber>2351234</exampleNumber>
15312       </mobile>
15313       <voip>
15314         <!-- VSAT prefixes are here. -->
15315         <nationalNumberPattern>635\d{4}</nationalNumberPattern>
15316         <exampleNumber>6351234</exampleNumber>
15317       </voip>
15318     </territory>
15319
15320     <!-- Macedonia, Former Yugoslav Rep. of -->
15321     <territory id="MK" countryCode="389" internationalPrefix="00"
15322                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
15323                mobileNumberPortableRegion="true">
15324       <references>
15325         <sourceUrl>http://www.itu.int/oth/T02020000CE/en</sourceUrl>
15326       </references>
15327       <availableFormats>
15328         <!-- Formats follow wikipedia. -->
15329         <numberFormat pattern="(2)(\d{3})(\d{4})">
15330           <leadingDigits>2</leadingDigits>
15331           <format>$1 $2 $3</format>
15332         </numberFormat>
15333         <numberFormat pattern="([347]\d)(\d{3})(\d{3})">
15334           <leadingDigits>[347]</leadingDigits>
15335           <format>$1 $2 $3</format>
15336         </numberFormat>
15337         <numberFormat pattern="([58]\d{2})(\d)(\d{2})(\d{2})">
15338           <leadingDigits>[58]</leadingDigits>
15339           <format>$1 $2 $3 $4</format>
15340         </numberFormat>
15341       </availableFormats>
15342       <generalDesc>
15343         <nationalNumberPattern>[2-578]\d{7}</nationalNumberPattern>
15344         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15345       </generalDesc>
15346       <fixedLine>
15347         <nationalNumberPattern>
15348           (?:
15349             2(?:
15350               [23]\d|
15351               5[124578]|
15352               6[01]
15353             )|
15354             3(?:
15355               1[3-6]|
15356               [23][2-6]|
15357               4[2356]
15358             )|
15359             4(?:
15360               [23][2-6]|
15361               4[3-6]|
15362               5[256]|
15363               6[25-8]|
15364               7[24-6]|
15365               8[4-6]
15366             )
15367           )\d{5}
15368         </nationalNumberPattern>
15369         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
15370         <exampleNumber>22212345</exampleNumber>
15371       </fixedLine>
15372       <mobile>
15373         <nationalNumberPattern>
15374           7(?:
15375             [0-25-8]\d{2}|
15376             32\d|
15377             421
15378           )\d{4}
15379         </nationalNumberPattern>
15380         <exampleNumber>72345678</exampleNumber>
15381       </mobile>
15382       <tollFree>
15383         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
15384         <exampleNumber>80012345</exampleNumber>
15385       </tollFree>
15386       <premiumRate>
15387         <nationalNumberPattern>5[02-9]\d{6}</nationalNumberPattern>
15388         <exampleNumber>50012345</exampleNumber>
15389       </premiumRate>
15390       <sharedCost>
15391         <nationalNumberPattern>
15392           8(?:
15393             0[1-9]|
15394             [1-9]\d
15395           )\d{5}
15396         </nationalNumberPattern>
15397         <exampleNumber>80123456</exampleNumber>
15398       </sharedCost>
15399     </territory>
15400
15401     <!-- Mali -->
15402     <territory id="ML" countryCode="223" internationalPrefix="00">
15403       <references>
15404         <sourceUrl>http://www.itu.int/oth/T0202000083/en</sourceUrl>
15405         <sourceUrl>http://crt-mali.org/pdf/plan_num</sourceUrl>
15406       </references>
15407       <availableFormats>
15408         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
15409           <leadingDigits>[246-9]</leadingDigits>
15410           <format>$1 $2 $3 $4</format>
15411         </numberFormat>
15412         <!-- Formatting some short numbers as a block. -->
15413         <numberFormat pattern="(\d{4})">
15414           <leadingDigits>
15415             67|
15416             74
15417           </leadingDigits>
15418           <intlFormat>NA</intlFormat>
15419           <format>$1</format>
15420         </numberFormat>
15421       </availableFormats>
15422       <generalDesc>
15423         <nationalNumberPattern>[246-9]\d{7}</nationalNumberPattern>
15424         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15425       </generalDesc>
15426       <fixedLine>
15427         <!-- Patterns from ITU with extra ranges 20 25, 20 7[13-9] and 217 provided by Sotelma and
15428              confirmed by searches online. -->
15429         <nationalNumberPattern>
15430           (?:
15431             2(?:
15432               0(?:
15433                 2[0-589]|
15434                 7\d
15435               )|
15436               1(?:
15437                 2[5-7]|
15438                 [3-689]\d|
15439                 7[2-4689]
15440               )
15441             )|
15442             44[239]\d
15443           )\d{4}
15444         </nationalNumberPattern>
15445         <exampleNumber>20212345</exampleNumber>
15446       </fixedLine>
15447       <mobile>
15448         <!-- Orange Mali have updated their numbering plan, though this is not reflected in the ITU
15449              document (which is very stale). All mobile numbers starting with 7 are now Orange.
15450              Includes 6x from Malitel IR21. Numbers beginning with 9 have been found online and
15451              reported by open-source users, although the exact possible second digits are uncertain.
15452              -->
15453         <nationalNumberPattern>
15454           [67]\d{7}|
15455           9[0-25-9]\d{6}
15456         </nationalNumberPattern>
15457         <exampleNumber>65012345</exampleNumber>
15458       </mobile>
15459       <tollFree>
15460         <!-- Online examples have not been found, but this seems to follow the prescriptions in the
15461              plan. -->
15462         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
15463         <exampleNumber>80012345</exampleNumber>
15464       </tollFree>
15465    </territory>
15466
15467     <!-- Myanmar -->
15468     <territory id="MM" countryCode="95" internationalPrefix="00" nationalPrefix="0"
15469                nationalPrefixFormattingRule="$NP$FG">
15470       <references>
15471         <sourceUrl>http://www.itu.int/oth/T0202000092/en</sourceUrl>
15472       </references>
15473       <availableFormats>
15474         <numberFormat pattern="(\d)(\d{3})(\d{3,4})">
15475           <leadingDigits>
15476             1|
15477             2[45]
15478           </leadingDigits>
15479           <format>$1 $2 $3</format>
15480         </numberFormat>
15481         <numberFormat pattern="(2)(\d{4})(\d{4})">
15482           <leadingDigits>251</leadingDigits>
15483           <format>$1 $2 $3</format>
15484         </numberFormat>
15485         <numberFormat pattern="(\d)(\d{2})(\d{3})">
15486           <leadingDigits>
15487             16|
15488             2
15489           </leadingDigits>
15490           <format>$1 $2 $3</format>
15491         </numberFormat>
15492         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})">
15493           <leadingDigits>
15494             67|
15495             81
15496           </leadingDigits>
15497           <format>$1 $2 $3</format>
15498         </numberFormat>
15499         <numberFormat pattern="(\d{2})(\d{2})(\d{3,4})">
15500           <leadingDigits>[4-8]</leadingDigits>
15501           <format>$1 $2 $3</format>
15502         </numberFormat>
15503         <numberFormat pattern="(9)(\d{3})(\d{4,6})">
15504           <leadingDigits>
15505             9(?:
15506               2[0-4]|
15507               [35-9]|
15508               4[13789]
15509             )
15510           </leadingDigits>
15511           <format>$1 $2 $3</format>
15512         </numberFormat>
15513         <numberFormat pattern="(9)(4\d{4})(\d{4})">
15514           <leadingDigits>94[0245]</leadingDigits>
15515           <format>$1 $2 $3</format>
15516         </numberFormat>
15517         <!-- Following majority of numbers found online. -->
15518         <numberFormat pattern="(9)(\d{3})(\d{3})(\d{3})">
15519           <leadingDigits>925</leadingDigits>
15520           <format>$1 $2 $3 $4</format>
15521         </numberFormat>
15522       </availableFormats>
15523       <generalDesc>
15524         <nationalNumberPattern>
15525           [14578]\d{5,7}|
15526           [26]\d{5,8}|
15527           9(?:
15528             2\d{0,2}|
15529             [58]|
15530             3\d|
15531             4\d{1,2}|
15532             6\d?|
15533             [79]\d{0,2}
15534           )\d{6}
15535         </nationalNumberPattern>
15536         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
15537       </generalDesc>
15538       <fixedLine>
15539         <nationalNumberPattern>
15540           1(?:
15541             2\d{1,2}|
15542             [3-5]\d|
15543             6\d?|
15544             [89][0-6]\d
15545           )\d{4}|
15546           2(?:
15547             [236-9]\d{4}|
15548             4(?:
15549               0\d{5}|
15550               \d{4}
15551             )|
15552             5(?:
15553               1\d{3,6}|
15554               [02-9]\d{3,5}
15555             )
15556           )|
15557           4(?:
15558             2[245-8]|
15559             [346][2-6]|
15560             5[3-5]
15561           )\d{4}|
15562           5(?:
15563             2(?:
15564               20?|
15565               [3-8]
15566             )|
15567             3[2-68]|
15568             4(?:
15569               21?|
15570               [4-8]
15571             )|
15572             5[23]|
15573             6[2-4]|
15574             7[2-8]|
15575             8[24-7]|
15576             9[2-7]
15577           )\d{4}|
15578           6(?:
15579             0[23]|
15580             1[2356]|
15581             [24][2-6]|
15582             3[24-6]|
15583             5[2-4]|
15584             6[2-8]|
15585             7(?:
15586               [2367]|
15587               4\d|
15588               5\d?|
15589               8[145]\d
15590             )|
15591             8[245]|
15592             9[24]
15593           )\d{4}|
15594           7(?:
15595             [04][24-8]|
15596             [15][2-7]|
15597             22|
15598             3[2-4]
15599           )\d{4}|
15600           8(?:
15601             1(?:
15602               2\d?|
15603               [3-689]
15604             )|
15605             2[2-8]|
15606             3[24]|
15607             4[24-7]|
15608             5[245]|
15609             6[23]
15610           )\d{4}
15611         </nationalNumberPattern>
15612         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
15613         <exampleNumber>1234567</exampleNumber>
15614       </fixedLine>
15615       <mobile>
15616         <!-- Added 99[089] (8 digits), 961 (9 digits), and 979 & 997 (10 digits) from bug
15617              reports/numbers found online. -->
15618         <nationalNumberPattern>
15619           17[01]\d{4}|
15620           9(?:
15621             2(?:
15622               [0-4]|
15623               5\d{2}
15624             )|
15625             3[136]\d|
15626             4(?:
15627               0[0-4]\d|
15628               [1379]\d|
15629               [24][0-589]\d|
15630               5\d{2}|
15631               88
15632             )|
15633             5[0-6]|
15634             61?\d|
15635             7(?:
15636               3\d|
15637               9\d{2}
15638             )|
15639             8\d|
15640             9(?:
15641               1\d|
15642               7\d{2}|
15643               [089]
15644             )
15645           )\d{5}
15646         </nationalNumberPattern>
15647         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
15648         <exampleNumber>92123456</exampleNumber>
15649       </mobile>
15650       <voip>
15651         <nationalNumberPattern>1333\d{4}</nationalNumberPattern>
15652         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15653         <exampleNumber>13331234</exampleNumber>
15654       </voip>
15655       <!-- No information on other types of phone numbers for Myanmar has been found. -->
15656     </territory>
15657
15658     <!-- Mongolia -->
15659     <territory id="MN" countryCode="976" internationalPrefix="001"
15660                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
15661       <references>
15662         <sourceUrl>http://www.itu.int/oth/T020200008E/en</sourceUrl>
15663       </references>
15664       <availableFormats>
15665         <numberFormat pattern="([12]\d)(\d{2})(\d{4})">
15666           <leadingDigits>[12]1</leadingDigits>
15667           <format>$1 $2 $3</format>
15668         </numberFormat>
15669         <numberFormat pattern="([12]2\d)(\d{5,6})">
15670           <leadingDigits>[12]2[1-3]</leadingDigits>
15671           <format>$1 $2</format>
15672         </numberFormat>
15673         <numberFormat pattern="([12]\d{3})(\d{5})">
15674           <leadingDigits>
15675             [12](?:
15676               27|
15677               [3-5]
15678             )
15679           </leadingDigits>
15680           <leadingDigits>
15681             [12](?:
15682               27|
15683               [3-5]\d
15684             )2
15685           </leadingDigits>
15686           <format>$1 $2</format>
15687         </numberFormat>
15688         <!-- It seems from online formatting that the national prefix is not written (or perhaps
15689              needed?) for numbers in these ranges. -->
15690         <numberFormat pattern="(\d{4})(\d{4})"
15691           nationalPrefixFormattingRule="$FG">
15692           <leadingDigits>[57-9]</leadingDigits>
15693           <format>$1 $2</format>
15694         </numberFormat>
15695         <numberFormat pattern="([12]\d{4})(\d{4,5})">
15696           <leadingDigits>
15697             [12](?:
15698               27|
15699               [3-5]
15700             )
15701           </leadingDigits>
15702           <leadingDigits>
15703             [12](?:
15704               27|
15705               [3-5]\d
15706             )[4-9]
15707           </leadingDigits>
15708           <format>$1 $2</format>
15709         </numberFormat>
15710       </availableFormats>
15711       <generalDesc>
15712         <nationalNumberPattern>
15713           [12]\d{7,9}|
15714           [57-9]\d{7}
15715         </nationalNumberPattern>
15716         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
15717       </generalDesc>
15718       <fixedLine>
15719         <!-- Note the leading digit is the access code: 1 is used by Mongolia Telecom subscribers
15720              and 2 is used by Mongolian Railway subscribers. The area code then follows the access
15721              code, and could be 1 to 4 digits long. We also cover wireless local loop numbers here
15722              as well, even though we are not certain whether they are in fact fixed or mobile in
15723              this country. 5-digit subscriber numbers for 4-digit area codes have been added due to
15724              online numbers being found. -->
15725         <nationalNumberPattern>
15726           [12](?:
15727             1\d|
15728             2(?:
15729               [1-3]\d?|
15730               7\d
15731             )|
15732             3[2-8]\d{1,2}|
15733             4[2-68]\d{1,2}|
15734             5[1-4689]\d{1,2}
15735           )\d{5}|
15736           5[0568]\d{6}
15737         </nationalNumberPattern>
15738         <exampleNumber>50123456</exampleNumber>
15739       </fixedLine>
15740       <mobile>
15741         <nationalNumberPattern>
15742           (?:
15743             8[689]|
15744             9[013-9]
15745           )\d{6}
15746         </nationalNumberPattern>
15747         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15748         <exampleNumber>88123456</exampleNumber>
15749       </mobile>
15750       <!-- No tollFree or premiumRate information can be found. -->
15751       <voip>
15752         <!-- According to the document this could be stricter, but there are counter examples
15753              online. -->
15754         <nationalNumberPattern>7[05-8]\d{6}</nationalNumberPattern>
15755         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15756         <exampleNumber>75123456</exampleNumber>
15757       </voip>
15758     </territory>
15759
15760     <!-- Macao, China -->
15761     <territory id="MO" countryCode="853" internationalPrefix="00">
15762       <references>
15763         <sourceUrl>http://www.itu.int/oth/T020200007E/en</sourceUrl>
15764       </references>
15765       <availableFormats>
15766         <numberFormat pattern="([268]\d{3})(\d{4})">
15767           <format>$1 $2</format>
15768         </numberFormat>
15769       </availableFormats>
15770       <generalDesc>
15771         <nationalNumberPattern>[268]\d{7}</nationalNumberPattern>
15772         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15773       </generalDesc>
15774       <fixedLine>
15775         <nationalNumberPattern>
15776           (?:
15777             28[2-57-9]|
15778             8[2-57-9]\d
15779           )\d{5}
15780         </nationalNumberPattern>
15781         <exampleNumber>28212345</exampleNumber>
15782       </fixedLine>
15783       <mobile>
15784         <!-- The 6[23] prefixes are added as SMS messages have been successfully delivered to these
15785              numbers, and they are also widely present on the Internet. -->
15786         <nationalNumberPattern>6[236]\d{6}</nationalNumberPattern>
15787         <exampleNumber>66123456</exampleNumber>
15788       </mobile>
15789       <!-- No tollFree or premiumRate information can be found. -->
15790     </territory>
15791
15792     <!-- Northern Mariana Islands -->
15793     <territory id="MP" countryCode="1" leadingDigits="670" nationalPrefix="1"
15794                internationalPrefix="011">
15795       <references>
15796         <sourceUrl>http://www.itu.int/oth/T02020000EE/en</sourceUrl>
15797         <sourceUrl>http://www.cnmiphonebook.com/</sourceUrl>
15798       </references>
15799       <generalDesc>
15800         <!-- NANPA country - uses US formatting rules -->
15801         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
15802         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
15803       </generalDesc>
15804       <fixedLine>
15805         <!-- Extra exchange codes 232, 289, 355, 472, 633, 637, 646, 647, 649, 653, 687, 734 and 828
15806              were seen in the white and yellow pages, but no numbers with these exchange codes have
15807              proved to be diallable so we exclude them for now.. -->
15808         <nationalNumberPattern>
15809           670(?:
15810             2(?:
15811               3[3-7]|
15812               56|
15813               8[5-8]
15814             )|
15815             32[1238]|
15816             4(?:
15817               33|
15818               8[348]
15819             )|
15820             5(?:
15821               32|
15822               55|
15823               88
15824             )|
15825             6(?:
15826               64|
15827               70|
15828               82
15829             )|
15830             78[589]|
15831             8[3-9]8|
15832             989
15833           )\d{4}
15834         </nationalNumberPattern>
15835         <exampleNumber>6702345678</exampleNumber>
15836       </fixedLine>
15837       <mobile>
15838         <nationalNumberPattern>
15839           670(?:
15840             2(?:
15841               3[3-7]|
15842               56|
15843               8[5-8]
15844             )|
15845             32[1238]|
15846             4(?:
15847               33|
15848               8[348]
15849             )|
15850             5(?:
15851               32|
15852               55|
15853               88
15854             )|
15855             6(?:
15856               64|
15857               70|
15858               82
15859             )|
15860             78[589]|
15861             8[3-9]8|
15862             989
15863           )\d{4}
15864         </nationalNumberPattern>
15865         <exampleNumber>6702345678</exampleNumber>
15866       </mobile>
15867       <tollFree>
15868         <nationalNumberPattern>
15869           8(?:
15870             00|
15871             44|
15872             55|
15873             66|
15874             77|
15875             88
15876           )[2-9]\d{6}
15877         </nationalNumberPattern>
15878         <possibleNumberPattern>\d{10}</possibleNumberPattern>
15879         <exampleNumber>8002123456</exampleNumber>
15880       </tollFree>
15881       <premiumRate>
15882         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
15883         <possibleNumberPattern>\d{10}</possibleNumberPattern>
15884         <exampleNumber>9002123456</exampleNumber>
15885       </premiumRate>
15886       <personalNumber>
15887         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
15888         <nationalNumberPattern>
15889           5(?:
15890             00|
15891             33|
15892             44|
15893             66|
15894             77
15895           )[2-9]\d{6}
15896         </nationalNumberPattern>
15897         <possibleNumberPattern>\d{10}</possibleNumberPattern>
15898         <exampleNumber>5002345678</exampleNumber>
15899       </personalNumber>
15900     </territory>
15901
15902     <!-- Martinique (French Dept. of) -->
15903     <territory id="MQ" countryCode="596" internationalPrefix="00"
15904                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
15905       <references>
15906         <sourceUrl>http://www.itu.int/oth/T0202000086/en</sourceUrl>
15907         <sourceUrl>http://www.arcep.fr/index.php?id=2137&amp;bloc=0596&amp;CMD=RESULTS_NUMEROTATION</sourceUrl>
15908       </references>
15909       <availableFormats>
15910         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
15911           <format>$1 $2 $3 $4</format>
15912         </numberFormat>
15913       </availableFormats>
15914       <generalDesc>
15915         <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
15916         <possibleNumberPattern>\d{9}</possibleNumberPattern>
15917       </generalDesc>
15918       <fixedLine>
15919         <nationalNumberPattern>
15920           596(?:
15921             0[2-5]|
15922             [12]0|
15923             3[05-9]|
15924             4[024-8]|
15925             [5-7]\d|
15926             89|
15927             9[4-8]
15928           )\d{4}
15929         </nationalNumberPattern>
15930         <exampleNumber>596301234</exampleNumber>
15931       </fixedLine>
15932       <mobile>
15933         <nationalNumberPattern>
15934           696(?:
15935             [0-479]\d|
15936             5[01]|
15937             8[0-689]
15938           )\d{4}
15939         </nationalNumberPattern>
15940         <exampleNumber>696201234</exampleNumber>
15941       </mobile>
15942       <!-- The 876 prefix is mentioned in the plan, but the plan is from 2006 and in France VOIP
15943            numbers were changed from 087 to the 09 prefix in 2009. It is likely this occurred here
15944            too. -->
15945     </territory>
15946
15947     <!-- Mauritania -->
15948     <territory id="MR" countryCode="222" internationalPrefix="00" >
15949       <references>
15950         <sourceUrl>http://www.itu.int/oth/T0202000087/en</sourceUrl>
15951         <sourceUrl>http://are.mr/pdfs/pnn2010.pdf</sourceUrl>
15952       </references>
15953       <availableFormats>
15954         <numberFormat pattern="([2-48]\d)(\d{2})(\d{2})(\d{2})">
15955           <format>$1 $2 $3 $4</format>
15956         </numberFormat>
15957       </availableFormats>
15958       <generalDesc>
15959         <nationalNumberPattern>[2-48]\d{7}</nationalNumberPattern>
15960         <possibleNumberPattern>\d{8}</possibleNumberPattern>
15961       </generalDesc>
15962       <fixedLine>
15963         <nationalNumberPattern>
15964           25[08]\d{5}|
15965           35\d{6}|
15966           45[1-7]\d{5}
15967         </nationalNumberPattern>
15968         <exampleNumber>35123456</exampleNumber>
15969       </fixedLine>
15970       <!-- Added "49\d" in response to https://github.com/googlei18n/libphonenumber/issues/529
15971            which might be overly permissive, but we don't have an official documentation for this
15972            and only a small number of numbers were found online. At least 492 and 495 are valid.
15973            -->
15974       <mobile>
15975         <nationalNumberPattern>
15976           (?:
15977             2(?:
15978               2\d|
15979               70
15980             )|
15981             3(?:
15982               3\d|
15983               6[1-36]|
15984               7[1-3]
15985             )|
15986             4(?:
15987               [49]\d|
15988               6[0457-9]|
15989               7[4-9]|
15990               8[01346-8]
15991             )
15992           )\d{5}
15993         </nationalNumberPattern>
15994         <exampleNumber>22123456</exampleNumber>
15995       </mobile>
15996       <tollFree>
15997         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
15998         <exampleNumber>80012345</exampleNumber>
15999       </tollFree>
16000     </territory>
16001
16002     <!-- Montserrat -->
16003     <territory id="MS" countryCode="1" leadingDigits="664" nationalPrefix="1"
16004                internationalPrefix="011">
16005       <references>
16006         <sourceUrl>http://www.itu.int/oth/T020200008F/en</sourceUrl>
16007       </references>
16008       <generalDesc>
16009         <!-- NANPA country - uses US formatting rules -->
16010         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
16011         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
16012       </generalDesc>
16013       <fixedLine>
16014         <nationalNumberPattern>664491\d{4}</nationalNumberPattern>
16015         <exampleNumber>6644912345</exampleNumber>
16016       </fixedLine>
16017       <mobile>
16018         <nationalNumberPattern>66449[2-6]\d{4}</nationalNumberPattern>
16019         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16020         <exampleNumber>6644923456</exampleNumber>
16021       </mobile>
16022       <tollFree>
16023         <nationalNumberPattern>
16024           8(?:
16025             00|
16026             44|
16027             55|
16028             66|
16029             77|
16030             88
16031           )[2-9]\d{6}
16032         </nationalNumberPattern>
16033         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16034         <exampleNumber>8002123456</exampleNumber>
16035       </tollFree>
16036       <premiumRate>
16037         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
16038         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16039         <exampleNumber>9002123456</exampleNumber>
16040       </premiumRate>
16041       <personalNumber>
16042         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
16043         <nationalNumberPattern>
16044           5(?:
16045             00|
16046             33|
16047             44|
16048             66|
16049             77
16050           )[2-9]\d{6}
16051         </nationalNumberPattern>
16052         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16053         <exampleNumber>5002345678</exampleNumber>
16054       </personalNumber>
16055     </territory>
16056
16057     <!-- Malta -->
16058     <territory id="MT" countryCode="356" internationalPrefix="00" mobileNumberPortableRegion="true">
16059       <references>
16060         <sourceUrl>http://www.itu.int/oth/T0202000084/en</sourceUrl>
16061         <!-- Numbering link in the LHS menu - has more up-to-date allocations -->
16062         <sourceUrl>http://www.mca.org.mt</sourceUrl>
16063       </references>
16064       <availableFormats>
16065         <numberFormat pattern="(\d{4})(\d{4})">
16066           <format>$1 $2</format>
16067         </numberFormat>
16068       </availableFormats>
16069       <generalDesc>
16070         <nationalNumberPattern>[2357-9]\d{7}</nationalNumberPattern>
16071         <possibleNumberPattern>\d{8}</possibleNumberPattern>
16072       </generalDesc>
16073       <fixedLine>
16074         <nationalNumberPattern>
16075           2(?:
16076             0(?:
16077               1[0-6]|
16078               3[1-4]|
16079               [69]\d
16080             )|
16081             [1-357]\d{2}
16082           )\d{4}
16083         </nationalNumberPattern>
16084         <exampleNumber>21001234</exampleNumber>
16085       </fixedLine>
16086       <mobile>
16087         <!-- 7210 and 92XX come from the allocations listed on http://www.mca.org.mt, but they are
16088              not listed in the latest ITU document. -->
16089         <nationalNumberPattern>
16090           (?:
16091             7(?:
16092               210|
16093               [79]\d{2}
16094             )|
16095             9(?:
16096               2(?:
16097                1[01]|
16098                31
16099               )|
16100               696|
16101               8(?:
16102                 1[1-3]|
16103                 89|
16104                 97
16105               )|
16106               9\d{2}
16107             )
16108           )\d{4}
16109         </nationalNumberPattern>
16110         <exampleNumber>96961234</exampleNumber>
16111       </mobile>
16112       <pager>
16113         <nationalNumberPattern>7117\d{4}</nationalNumberPattern>
16114         <exampleNumber>71171234</exampleNumber>
16115       </pager>
16116       <tollFree>
16117         <nationalNumberPattern>800[3467]\d{4}</nationalNumberPattern>
16118         <exampleNumber>80071234</exampleNumber>
16119       </tollFree>
16120       <premiumRate>
16121         <nationalNumberPattern>
16122           5(?:
16123             0(?:
16124               0(?:
16125                 37|
16126                 43
16127               )|
16128               6\d{2}|
16129               70\d|
16130               9[0168]
16131             )|
16132             [12]\d0[1-5]
16133           )\d{3}
16134         </nationalNumberPattern>
16135         <exampleNumber>50037123</exampleNumber>
16136       </premiumRate>
16137       <voip>
16138         <!-- In the plan as Non-PATS ECS. -->
16139         <nationalNumberPattern>3550\d{4}</nationalNumberPattern>
16140         <exampleNumber>35501234</exampleNumber>
16141       </voip>
16142       <uan>
16143         <!-- Using this for governmental numbers. -->
16144         <nationalNumberPattern>501\d{5}</nationalNumberPattern>
16145         <exampleNumber>50112345</exampleNumber>
16146       </uan>
16147     </territory>
16148
16149     <!-- Mauritius -->
16150     <!-- Preferred international prefix is expected to standardize on just '00' -->
16151     <territory id="MU" countryCode="230" internationalPrefix="0(?:0|[2-7]0|33)"
16152                preferredInternationalPrefix="020">
16153       <references>
16154         <sourceUrl>http://www.icta.mu/telecommunications/numbering.htm</sourceUrl>
16155       </references>
16156       <availableFormats>
16157         <numberFormat pattern="([2-46-9]\d{2})(\d{4})">
16158           <leadingDigits>[2-46-9]</leadingDigits>
16159           <format>$1 $2</format>
16160         </numberFormat>
16161         <numberFormat pattern="(5\d{3})(\d{4})">
16162           <leadingDigits>5</leadingDigits>
16163           <format>$1 $2</format>
16164         </numberFormat>
16165       </availableFormats>
16166       <generalDesc>
16167         <nationalNumberPattern>[2-9]\d{6,7}</nationalNumberPattern>
16168         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
16169       </generalDesc>
16170       <fixedLine>
16171         <!-- See also: http://www.wtng.info/wtng-230-mu.html for additional detail. -->
16172         <nationalNumberPattern>
16173           (?:
16174             2(?:
16175               [03478]\d|
16176               1[0-7]|
16177               6[1-69]
16178             )|
16179             4(?:
16180               [013568]\d|
16181               2[4-7]
16182             )|
16183             5(?:
16184               44\d|
16185               471
16186             )|
16187             6\d{2}|
16188             8(?:
16189               14|
16190               3[129]
16191             )
16192           )\d{4}
16193         </nationalNumberPattern>
16194         <exampleNumber>2012345</exampleNumber>
16195       </fixedLine>
16196       <mobile>
16197         <nationalNumberPattern>
16198           5(?:
16199             2[59]\d|
16200             4(?:
16201               2[1-389]|
16202               4\d|
16203               7[1-9]|
16204               9\d
16205             )|
16206             7\d{2}|
16207             8(?:
16208               [2568]\d|
16209               7[15-8]
16210             )|
16211             9[0-8]\d
16212           )\d{4}
16213         </nationalNumberPattern>
16214         <possibleNumberPattern>\d{8}</possibleNumberPattern>
16215         <exampleNumber>52512345</exampleNumber>
16216       </mobile>
16217       <tollFree>
16218         <nationalNumberPattern>80[012]\d{4}</nationalNumberPattern>
16219         <possibleNumberPattern>\d{7}</possibleNumberPattern>
16220         <exampleNumber>8001234</exampleNumber>
16221       </tollFree>
16222       <premiumRate>
16223         <nationalNumberPattern>30\d{5}</nationalNumberPattern>
16224         <possibleNumberPattern>\d{7}</possibleNumberPattern>
16225         <exampleNumber>3012345</exampleNumber>
16226       </premiumRate>
16227       <voip>
16228         <nationalNumberPattern>
16229           3(?:
16230             20|
16231             9\d
16232           )\d{4}
16233         </nationalNumberPattern>
16234         <possibleNumberPattern>\d{7}</possibleNumberPattern>
16235         <exampleNumber>3201234</exampleNumber>
16236       </voip>
16237     </territory>
16238
16239     <!-- Maldives -->
16240     <territory id="MV" countryCode="960" internationalPrefix="0(?:0|19)"
16241                preferredInternationalPrefix="00">
16242       <references>
16243         <sourceUrl>http://www.itu.int/oth/T0202000082/en</sourceUrl>
16244         <sourceUrl>http://www.dhiraagu.com.mv</sourceUrl>
16245       </references>
16246       <availableFormats>
16247         <numberFormat pattern="(\d{3})(\d{4})">
16248           <leadingDigits>
16249             [3467]|
16250             9(?:
16251               [1-9]|
16252               0[1-9]
16253             )
16254           </leadingDigits>
16255           <format>$1-$2</format>
16256         </numberFormat>
16257         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
16258           <leadingDigits>900</leadingDigits>
16259           <format>$1 $2 $3</format>
16260         </numberFormat>
16261       </availableFormats>
16262       <generalDesc>
16263         <nationalNumberPattern>
16264           [3467]\d{6}|
16265           9(?:
16266             00\d{7}|
16267             \d{6}
16268           )
16269         </nationalNumberPattern>
16270         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
16271       </generalDesc>
16272       <fixedLine>
16273         <!-- 300 has been added as prefixes from online searches, since the numbers seemed to be
16274              diallable. -->
16275         <nationalNumberPattern>
16276           (?:
16277             3(?:
16278               0[01]|
16279               3[0-59]
16280             )|
16281             6(?:
16282               [567][02468]|
16283               8[024689]|
16284               90
16285             )
16286           )\d{4}
16287         </nationalNumberPattern>
16288         <possibleNumberPattern>\d{7}</possibleNumberPattern>
16289         <exampleNumber>6701234</exampleNumber>
16290       </fixedLine>
16291       <mobile>
16292         <!-- 7[45] has been added as many numbers online have been found with this prefix. 46[46]
16293              are new prefixes for Dhiraagu and Wataniya, used currently for SMS-based services.
16294              91 was added based on information from Wataniya Telecom. -->
16295         <nationalNumberPattern>
16296           (?:
16297             46[46]|
16298             7[3-9]\d|
16299             9[16-9]\d
16300           )\d{4}
16301         </nationalNumberPattern>
16302         <possibleNumberPattern>\d{7}</possibleNumberPattern>
16303         <exampleNumber>7712345</exampleNumber>
16304       </mobile>
16305       <pager>
16306         <nationalNumberPattern>781\d{4}</nationalNumberPattern>
16307         <possibleNumberPattern>\d{7}</possibleNumberPattern>
16308         <exampleNumber>7812345</exampleNumber>
16309       </pager>
16310       <premiumRate>
16311         <nationalNumberPattern>900\d{7}</nationalNumberPattern>
16312         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16313         <exampleNumber>9001234567</exampleNumber>
16314       </premiumRate>
16315     </territory>
16316
16317     <!-- Malawi -->
16318     <!-- The plan doesn't state that a national prefix exists, but numbers found on the internet are
16319          consistent in having one. -->
16320     <territory id="MW" countryCode="265" internationalPrefix="00"
16321                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
16322       <references>
16323         <sourceUrl>http://www.itu.int/oth/T0202000080/en</sourceUrl>
16324       </references>
16325       <availableFormats>
16326         <numberFormat pattern="(\d)(\d{3})(\d{3})">
16327           <leadingDigits>1</leadingDigits>
16328           <format>$1 $2 $3</format>
16329         </numberFormat>
16330         <numberFormat pattern="(2\d{2})(\d{3})(\d{3})">
16331           <leadingDigits>2</leadingDigits>
16332           <format>$1 $2 $3</format>
16333         </numberFormat>
16334         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
16335           <leadingDigits>[1789]</leadingDigits>
16336           <format>$1 $2 $3 $4</format>
16337         </numberFormat>
16338       </availableFormats>
16339       <generalDesc>
16340         <nationalNumberPattern>
16341           (?:
16342             1(?:
16343               \d{2}
16344             )?|
16345             [2789]\d{2}
16346           )\d{6}
16347         </nationalNumberPattern>
16348         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
16349       </generalDesc>
16350       <fixedLine>
16351         <!-- 14 is no longer mentioned in the plan as a prefix, but plenty of online numbers have
16352              been found so this is being retained for now. It is possible however that these may be
16353              old-format mobile numbers. -->
16354         <nationalNumberPattern>
16355           (?:
16356             1[2-9]|
16357             21\d{2}
16358           )\d{5}
16359         </nationalNumberPattern>
16360         <exampleNumber>1234567</exampleNumber>
16361       </fixedLine>
16362       <mobile>
16363         <nationalNumberPattern>
16364           (?:
16365             111|
16366             77\d|
16367             88\d|
16368             99\d
16369           )\d{6}
16370         </nationalNumberPattern>
16371         <possibleNumberPattern>\d{9}</possibleNumberPattern>
16372         <exampleNumber>991234567</exampleNumber>
16373       </mobile>
16374     </territory>
16375
16376     <!-- Mexico -->
16377     <territory id="MX" countryCode="52" internationalPrefix="0[09]"
16378                nationalPrefix="01"
16379                nationalPrefixForParsing="0[12]|04[45](\d{10})"
16380                nationalPrefixTransformRule="1$1"
16381                nationalPrefixFormattingRule="$NP $FG"
16382                nationalPrefixOptionalWhenFormatting="true"
16383                leadingZeroPossible="true" mobileNumberPortableRegion="true">
16384       <references>
16385         <sourceUrl>http://www.itu.int/oth/T020200008A/en</sourceUrl>
16386         <sourceUrl>http://en.wikipedia.org/wiki/%2B52</sourceUrl>
16387         <sourceUrl>http://en.wikipedia.org/wiki/Premium-rate_telephone_number#Mexico</sourceUrl>
16388         <sourceUrl>http://en.wikipedia.org/wiki/Toll-free_telephone_number</sourceUrl>
16389       </references>
16390       <!-- When a number starts with 01 or 02, we remove the prefixes; when a number starts with 044
16391            or 045 followed by 10 digits, we replace the prefixes with 1. This way all the mobile
16392            numbers, regardless of whether they are written in international format (leading 1) or
16393            national format (leading 044/045), will be parsed into the same form. -->
16394       <availableFormats>
16395         <numberFormat pattern="([358]\d)(\d{4})(\d{4})">
16396           <leadingDigits>
16397             33|
16398             55|
16399             81
16400           </leadingDigits>
16401           <format>$1 $2 $3</format>
16402         </numberFormat>
16403         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
16404           <leadingDigits>
16405             [2467]|
16406             3[12457-9]|
16407             5[89]|
16408             8[02-9]|
16409             9[0-35-9]
16410           </leadingDigits>
16411           <format>$1 $2 $3</format>
16412         </numberFormat>
16413         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(1)([358]\d)(\d{4})(\d{4})">
16414           <leadingDigits>
16415             1(?:
16416               33|
16417               55|
16418               81
16419             )
16420           </leadingDigits>
16421           <format>044 $2 $3 $4</format>
16422           <intlFormat>$1 $2 $3 $4</intlFormat>
16423         </numberFormat>
16424         <numberFormat nationalPrefixFormattingRule="$FG" pattern="(1)(\d{3})(\d{3})(\d{4})">
16425           <leadingDigits>
16426             1(?:
16427               [2467]|
16428               3[12457-9]|
16429               5[89]|
16430               8[2-9]|
16431               9[1-35-9]
16432             )
16433           </leadingDigits>
16434           <format>044 $2 $3 $4</format>
16435           <intlFormat>$1 $2 $3 $4</intlFormat>
16436         </numberFormat>
16437       </availableFormats>
16438       <generalDesc>
16439         <nationalNumberPattern>[1-9]\d{9,10}</nationalNumberPattern>
16440         <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
16441       </generalDesc>
16442       <fixedLine>
16443         <!-- http://en.wikipedia.org/wiki/Area_codes_in_Mexico_by_code -->
16444         <nationalNumberPattern>
16445           (?:
16446             33|
16447             55|
16448             81
16449           )\d{8}|
16450           (?:
16451             2(?:
16452               2[2-9]|
16453               3[1-35-8]|
16454               4[13-9]|
16455               7[1-689]|
16456               8[1-578]|
16457               9[467]
16458             )|
16459             3(?:
16460               1[1-79]|
16461               [2458][1-9]|
16462               7[1-8]|
16463               9[1-5]
16464             )|
16465             4(?:
16466               1[1-57-9]|
16467               [24-6][1-9]|
16468               [37][1-8]|
16469               8[1-35-9]|
16470               9[2-689]
16471             )|
16472             5(?:
16473               88|
16474               9[1-79]
16475             )|
16476             6(?:
16477               1[2-68]|
16478               [234][1-9]|
16479               5[1-3689]|
16480               6[12457-9]|
16481               7[1-7]|
16482               8[67]|
16483               9[4-8]
16484             )|
16485             7(?:
16486               [13467][1-9]|
16487               2[1-8]|
16488               5[13-9]|
16489               8[1-69]|
16490               9[17]
16491             )|
16492             8(?:
16493               2[13-689]|
16494               3[1-6]|
16495               4[124-6]|
16496               6[1246-9]|
16497               7[1-378]|
16498               9[12479]
16499             )|
16500             9(?:
16501               1[346-9]|
16502               2[1-4]|
16503               3[2-46-8]|
16504               5[1348]|
16505               [69][1-9]|
16506               7[12]|
16507               8[1-8]
16508             )
16509           )\d{7}
16510         </nationalNumberPattern>
16511         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
16512         <exampleNumber>2221234567</exampleNumber>
16513       </fixedLine>
16514       <mobile>
16515         <nationalNumberPattern>
16516           1(?:
16517             (?:
16518               33|
16519               55|
16520               81
16521             )\d{8}|
16522             (?:
16523               2(?:
16524                 2[2-9]|
16525                 3[1-35-8]|
16526                 4[13-9]|
16527                 7[1-689]|
16528                 8[1-578]|
16529                 9[467]
16530               )|
16531               3(?:
16532                 1[1-79]|
16533                 [2458][1-9]|
16534                 7[1-8]|
16535                 9[1-5]
16536               )|
16537               4(?:
16538                 1[1-57-9]|
16539                 [24-6][1-9]|
16540                 [37][1-8]|
16541                 8[1-35-9]|
16542                 9[2-689]
16543               )|
16544               5(?:
16545                 88|
16546                 9[1-79]
16547               )|
16548               6(?:
16549                 1[2-68]|
16550                 [2-4][1-9]|
16551                 5[1-3689]|
16552                 6[12457-9]|
16553                 7[1-7]|
16554                 8[67]|
16555                 9[4-8]
16556               )|
16557               7(?:
16558                 [13467][1-9]|
16559                 2[1-8]|
16560                 5[13-9]|
16561                 8[1-69]|
16562                 9[17]
16563               )|
16564               8(?:
16565                 2[13-689]|
16566                 3[1-6]|
16567                 4[124-6]|
16568                 6[1246-9]|
16569                 7[1-378]|
16570                 9[12479]
16571               )|
16572               9(?:
16573                 1[346-9]|
16574                 2[1-4]|
16575                 3[2-46-8]|
16576                 5[1348]|
16577                 [69][1-9]|
16578                 7[12]|
16579                 8[1-8]
16580               )
16581             )\d{7}
16582           )
16583         </nationalNumberPattern>
16584         <possibleNumberPattern>\d{11}</possibleNumberPattern>
16585         <exampleNumber>12221234567</exampleNumber>
16586       </mobile>
16587       <tollFree>
16588         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
16589         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16590         <exampleNumber>8001234567</exampleNumber>
16591       </tollFree>
16592       <premiumRate>
16593         <nationalNumberPattern>900\d{7}</nationalNumberPattern>
16594         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16595         <exampleNumber>9001234567</exampleNumber>
16596       </premiumRate>
16597     </territory>
16598
16599     <!-- Malaysia -->
16600     <territory id="MY" countryCode="60" internationalPrefix="00"
16601                nationalPrefix="0" mobileNumberPortableRegion="true">
16602       <references>
16603         <sourceUrl>http://en.wikipedia.org/wiki/%2B60</sourceUrl>
16604         <sourceUrl>http://www.skmm.gov.my</sourceUrl>
16605       </references>
16606       <availableFormats>
16607         <numberFormat nationalPrefixFormattingRule="$NP$FG"
16608           pattern="([4-79])(\d{3})(\d{4})">
16609           <leadingDigits>[4-79]</leadingDigits>
16610           <format>$1-$2 $3</format>
16611         </numberFormat>
16612         <numberFormat nationalPrefixFormattingRule="$NP$FG"
16613           pattern="(3)(\d{4})(\d{4})">
16614           <leadingDigits>3</leadingDigits>
16615           <format>$1-$2 $3</format>
16616         </numberFormat>
16617         <numberFormat nationalPrefixFormattingRule="$NP$FG"
16618           pattern="([18]\d)(\d{3})(\d{3,4})">
16619           <leadingDigits>
16620             1[02-46-9][1-9]|
16621             8
16622           </leadingDigits>
16623           <format>$1-$2 $3</format>
16624         </numberFormat>
16625         <numberFormat pattern="(1)([36-8]00)(\d{2})(\d{4})">
16626           <leadingDigits>1[36-8]0</leadingDigits>
16627           <format>$1-$2-$3-$4</format>
16628         </numberFormat>
16629         <numberFormat nationalPrefixFormattingRule="$NP$FG"
16630           pattern="(11)(\d{4})(\d{4})">
16631           <leadingDigits>11</leadingDigits>
16632           <format>$1-$2 $3</format>
16633         </numberFormat>
16634         <numberFormat nationalPrefixFormattingRule="$NP$FG"
16635           pattern="(15[49])(\d{3})(\d{4})">
16636           <leadingDigits>15</leadingDigits>
16637           <format>$1-$2 $3</format>
16638         </numberFormat>
16639       </availableFormats>
16640       <generalDesc>
16641         <nationalNumberPattern>[13-9]\d{7,9}</nationalNumberPattern>
16642         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
16643       </generalDesc>
16644       <fixedLine>
16645         <nationalNumberPattern>
16646           (?:
16647             3[2-9]\d|
16648             [4-9][2-9]
16649           )\d{6}
16650         </nationalNumberPattern>
16651         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
16652         <exampleNumber>323456789</exampleNumber>
16653       </fixedLine>
16654       <mobile>
16655         <!-- Although the plan lists the prefix 159 as broadband services (data only), apparently it
16656              is possible to send SMSs (and receive them) from numbers in this block, so we are
16657              listing them as mobile. 115 was added based on numbers found online. -->
16658         <nationalNumberPattern>
16659           1(?:
16660             1[1-35]\d{2}|
16661             [02-4679][2-9]\d|
16662             59\d{2}|
16663             8(?:
16664               1[23]|
16665               [2-9]\d
16666             )
16667           )\d{5}
16668         </nationalNumberPattern>
16669         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
16670         <exampleNumber>123456789</exampleNumber>
16671       </mobile>
16672       <tollFree>
16673         <!-- http://www.skmm.gov.my/skmmgovmy/media/General/pdf/Special_Service_Number.pdf -->
16674         <nationalNumberPattern>1[378]00\d{6}</nationalNumberPattern>
16675         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16676         <exampleNumber>1300123456</exampleNumber>
16677       </tollFree>
16678       <premiumRate>
16679         <nationalNumberPattern>1600\d{6}</nationalNumberPattern>
16680         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16681         <exampleNumber>1600123456</exampleNumber>
16682       </premiumRate>
16683       <voip>
16684         <nationalNumberPattern>154\d{7}</nationalNumberPattern>
16685         <possibleNumberPattern>\d{10}</possibleNumberPattern>
16686         <exampleNumber>1541234567</exampleNumber>
16687       </voip>
16688     </territory>
16689
16690     <!-- Mozambique -->
16691     <territory id="MZ" countryCode="258" internationalPrefix="00">
16692       <references>
16693         <sourceUrl>http://www.itu.int/oth/T0202000091/en</sourceUrl>
16694       </references>
16695       <availableFormats>
16696         <numberFormat pattern="([28]\d)(\d{3})(\d{3,4})">
16697           <leadingDigits>
16698             2|
16699             8[2-7]
16700           </leadingDigits>
16701           <format>$1 $2 $3</format>
16702         </numberFormat>
16703         <numberFormat pattern="(80\d)(\d{3})(\d{3})">
16704           <leadingDigits>80</leadingDigits>
16705           <format>$1 $2 $3</format>
16706         </numberFormat>
16707       </availableFormats>
16708       <generalDesc>
16709         <nationalNumberPattern>[28]\d{7,8}</nationalNumberPattern>
16710         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
16711       </generalDesc>
16712       <fixedLine>
16713         <nationalNumberPattern>
16714           2(?:
16715             [1346]\d|
16716             5[0-2]|
16717             [78][12]|
16718             93
16719           )\d{5}
16720         </nationalNumberPattern>
16721         <possibleNumberPattern>\d{8}</possibleNumberPattern>
16722         <exampleNumber>21123456</exampleNumber>
16723       </fixedLine>
16724       <mobile>
16725         <nationalNumberPattern>8[23467]\d{7}</nationalNumberPattern>
16726         <possibleNumberPattern>\d{9}</possibleNumberPattern>
16727         <exampleNumber>821234567</exampleNumber>
16728       </mobile>
16729       <tollFree>
16730         <!-- Unsure of the length requirement on toll-free numbers, so using 9 based on online
16731              examples. -->
16732         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
16733         <possibleNumberPattern>\d{9}</possibleNumberPattern>
16734         <exampleNumber>800123456</exampleNumber>
16735       </tollFree>
16736       <!-- The plan suggests 801 and 802 numbers are shared-cost numbers, and numbers beginning with
16737            a 9 are premium rate, but no online examples can be found of any of these so they are
16738            omitted for the time-being. -->
16739     </territory>
16740
16741     <!-- Namibia -->
16742     <territory id="NA" countryCode="264" internationalPrefix="00"
16743                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
16744       <references>
16745         <sourceUrl>http://www.itu.int/oth/T0202000093/en</sourceUrl>
16746       </references>
16747       <availableFormats>
16748         <numberFormat pattern="(8\d)(\d{3})(\d{4})">
16749           <leadingDigits>8[1235]</leadingDigits>
16750           <format>$1 $2 $3</format>
16751         </numberFormat>
16752         <numberFormat pattern="(6\d)(\d{2,3})(\d{4})">
16753           <leadingDigits>6</leadingDigits>
16754           <format>$1 $2 $3</format>
16755         </numberFormat>
16756         <numberFormat pattern="(88)(\d{3})(\d{3})">
16757           <leadingDigits>88</leadingDigits>
16758           <format>$1 $2 $3</format>
16759         </numberFormat>
16760         <numberFormat pattern="(870)(\d{3})(\d{3})">
16761           <leadingDigits>870</leadingDigits>
16762           <format>$1 $2 $3</format>
16763         </numberFormat>
16764       </availableFormats>
16765       <generalDesc>
16766         <nationalNumberPattern>[68]\d{7,8}</nationalNumberPattern>
16767         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
16768       </generalDesc>
16769       <fixedLine>
16770         <!-- Includes VSAT service. -->
16771         <nationalNumberPattern>
16772           6(?:
16773             1(?:
16774               17|
16775               2(?:
16776                 [0189]\d|
16777                 [2-6]|
16778                 7\d?
16779               )|
16780               3(?:
16781                 [01378]|
16782                 2\d
16783               )|
16784               4[01]|
16785               69|
16786               7[014]
16787             )|
16788             2(?:
16789               17|
16790               5(?:
16791                 [0-36-8]|
16792                 4\d?
16793               )|
16794               69|
16795               70
16796             )|
16797             3(?:
16798               17|
16799               2(?:
16800                 [0237]\d?|
16801                 [14-689]
16802               )|
16803               34|
16804               6[29]|
16805               7[01]|
16806               81
16807             )|
16808             4(?:
16809               17|
16810               2(?:
16811                 [012]|
16812                 7?
16813               )|
16814               4(?:
16815                 [06]|
16816                 1\d
16817               )|
16818               5(?:
16819                 [01357]|
16820                 [25]\d?
16821               )|
16822               69|
16823               7[01]
16824             )|
16825             5(?:
16826               17|
16827               2(?:
16828                 [0459]|
16829                 [23678]\d?
16830               )|
16831               69|
16832               7[01]
16833             )|
16834             6(?:
16835               17|
16836               2(?:
16837                 5|
16838                 6\d?
16839               )|
16840               38|
16841               42|
16842               69|
16843               7[01]
16844             )|
16845             7(?:
16846               17|
16847               2(?:
16848                 [569]|
16849                 [234]\d?
16850               )|
16851               3(?:
16852                 0\d?|
16853                 [13]
16854               )|
16855               69|
16856               7[01]
16857             )
16858           )\d{4}
16859         </nationalNumberPattern>
16860         <exampleNumber>61221234</exampleNumber>
16861       </fixedLine>
16862       <mobile>
16863         <!-- Includes the Switch CDMA Service. -->
16864         <nationalNumberPattern>
16865           (?:
16866             60|
16867             8[125]
16868           )\d{7}
16869         </nationalNumberPattern>
16870         <possibleNumberPattern>\d{9}</possibleNumberPattern>
16871         <exampleNumber>811234567</exampleNumber>
16872       </mobile>
16873       <premiumRate>
16874         <nationalNumberPattern>8701\d{5}</nationalNumberPattern>
16875         <possibleNumberPattern>\d{9}</possibleNumberPattern>
16876         <exampleNumber>870123456</exampleNumber>
16877       </premiumRate>
16878       <voip>
16879         <!-- Including virtual telephone and VOIP services. -->
16880         <nationalNumberPattern>
16881           8(?:
16882             3\d{2}|
16883             86
16884           )\d{5}
16885         </nationalNumberPattern>
16886         <exampleNumber>88612345</exampleNumber>
16887       </voip>
16888     </territory>
16889
16890     <!-- New Caledonia (Territoire français d'outre-mer) -->
16891     <territory id="NC" countryCode="687" internationalPrefix="00">
16892       <references>
16893         <sourceUrl>http://www.itu.int/oth/T0202000098/en</sourceUrl>
16894         <sourceUrl>http://www.opt.nc</sourceUrl>
16895       </references>
16896       <availableFormats>
16897         <!-- From http://www.1012.nc, the local yellow pages. -->
16898         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
16899           <!-- We exclude short-codes here so they are formatted as a block -->
16900           <leadingDigits>
16901             [2-46-9]|
16902             5[0-4]
16903           </leadingDigits>
16904           <format>$1.$2.$3</format>
16905         </numberFormat>
16906       </availableFormats>
16907       <generalDesc>
16908         <nationalNumberPattern>[2-57-9]\d{5}</nationalNumberPattern>
16909         <possibleNumberPattern>\d{6}</possibleNumberPattern>
16910       </generalDesc>
16911       <fixedLine>
16912         <!-- Including the 88 prefix for public payphones. -->
16913         <nationalNumberPattern>
16914           (?:
16915             2[03-9]|
16916             3[0-5]|
16917             4[1-7]|
16918             88
16919           )\d{4}
16920         </nationalNumberPattern>
16921         <exampleNumber>201234</exampleNumber>
16922       </fixedLine>
16923       <mobile>
16924         <nationalNumberPattern>
16925           (?:
16926             5[0-4]|
16927             [79]\d|
16928             8[0-79]
16929           )\d{4}
16930         </nationalNumberPattern>
16931         <exampleNumber>751234</exampleNumber>
16932       </mobile>
16933       <!-- Listed as "voice services", from what we've seen they seem to cost extra. -->
16934       <!-- Note that OPT lists 3631 as a free short number for caller ID services, but the ITU
16935            document says that all 36 numbers are 6 digits. See ShortNumberMetadata.xml for more. -->
16936       <premiumRate>
16937         <nationalNumberPattern>36\d{4}</nationalNumberPattern>
16938         <exampleNumber>366711</exampleNumber>
16939       </premiumRate>
16940     </territory>
16941
16942     <!-- Niger -->
16943     <territory id="NE" countryCode="227" internationalPrefix="00" leadingZeroPossible="true">
16944       <references>
16945         <sourceUrl>http://www.itu.int/oth/T020200009B/en</sourceUrl>
16946       </references>
16947       <availableFormats>
16948         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
16949           <leadingDigits>
16950             [289]|
16951             09
16952           </leadingDigits>
16953           <format>$1 $2 $3 $4</format>
16954         </numberFormat>
16955         <numberFormat pattern="(08)(\d{3})(\d{3})">
16956           <leadingDigits>08</leadingDigits>
16957           <format>$1 $2 $3</format>
16958         </numberFormat>
16959       </availableFormats>
16960       <generalDesc>
16961         <nationalNumberPattern>[0289]\d{7}</nationalNumberPattern>
16962         <possibleNumberPattern>\d{8}</possibleNumberPattern>
16963       </generalDesc>
16964       <fixedLine>
16965         <!-- Adding 20 61 from online numbers. -->
16966         <nationalNumberPattern>
16967           2(?:
16968             0(?:
16969               20|
16970               3[1-7]|
16971               4[134]|
16972               5[14]|
16973               6[14578]|
16974               7[1-578]
16975             )|
16976             1(?:
16977               4[145]|
16978               5[14]|
16979               6[14-68]|
16980               7[169]|
16981               88
16982             )
16983           )\d{4}
16984         </nationalNumberPattern>
16985         <exampleNumber>20201234</exampleNumber>
16986       </fixedLine>
16987       <mobile>
16988         <!-- Added 88, 90, 91, 92, 95, 97, 98 & 99 from online data. Airtel have confirmed that they
16989              use the 89 and 97 prefixes, and Orange use 92. MOOV started using 95 in Jan 2014. -->
16990         <nationalNumberPattern>
16991           (?:
16992             8[89]|
16993             9\d
16994           )\d{6}
16995         </nationalNumberPattern>
16996         <exampleNumber>93123456</exampleNumber>
16997       </mobile>
16998       <tollFree>
16999         <nationalNumberPattern>08\d{6}</nationalNumberPattern>
17000         <exampleNumber>08123456</exampleNumber>
17001       </tollFree>
17002       <premiumRate>
17003         <nationalNumberPattern>09\d{6}</nationalNumberPattern>
17004         <exampleNumber>09123456</exampleNumber>
17005       </premiumRate>
17006     </territory>
17007
17008     <!-- Norfolk Island -->
17009     <!-- Including numbers for Australian Antarctic stations. -->
17010     <territory id="NF" countryCode="672" internationalPrefix="00">
17011       <references>
17012         <sourceUrl>http://www.itu.int/oth/T020200009D/en</sourceUrl>
17013       </references>
17014       <availableFormats>
17015         <numberFormat pattern="(\d{2})(\d{4})">
17016            <leadingDigits>1</leadingDigits>
17017           <format>$1 $2</format>
17018         </numberFormat>
17019         <numberFormat pattern="(\d)(\d{5})">
17020           <leadingDigits>3</leadingDigits>
17021           <format>$1 $2</format>
17022         </numberFormat>
17023       </availableFormats>
17024       <generalDesc>
17025         <nationalNumberPattern>[13]\d{5}</nationalNumberPattern>
17026         <possibleNumberPattern>\d{5,6}</possibleNumberPattern>
17027       </generalDesc>
17028       <fixedLine>
17029         <!-- ITU says all 3X numbers except 38 are fixed-line, but 3[3-79] numbers don't seem to
17030              connect after we tried calling them. -->
17031         <nationalNumberPattern>
17032           (?:
17033             1(?:
17034               06|
17035               17|
17036               28|
17037               39
17038             )|
17039             3[012]\d
17040           )\d{3}
17041         </nationalNumberPattern>
17042         <exampleNumber>106609</exampleNumber>
17043       </fixedLine>
17044       <mobile>
17045         <!-- Numbers found online with prefix 35. -->
17046         <nationalNumberPattern>3[58]\d{4}</nationalNumberPattern>
17047         <exampleNumber>381234</exampleNumber>
17048       </mobile>
17049     </territory>
17050
17051     <!-- Nigeria -->
17052     <territory id="NG" countryCode="234" internationalPrefix="009"
17053                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
17054                mobileNumberPortableRegion="true">
17055       <references>
17056         <sourceUrl>http://www.itu.int/oth/T020200009C/en</sourceUrl>
17057       </references>
17058       <availableFormats>
17059         <numberFormat pattern="([129])(\d{3})(\d{3,4})">
17060           <leadingDigits>[129]</leadingDigits>
17061           <format>$1 $2 $3</format>
17062         </numberFormat>
17063         <numberFormat pattern="(\d{2})(\d{3})(\d{2,3})">
17064           <leadingDigits>
17065             [3-6]|
17066             7(?:
17067               [1-79]|
17068               0[1-9]
17069             )|
17070             8[2-9]
17071           </leadingDigits>
17072           <format>$1 $2 $3</format>
17073         </numberFormat>
17074         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
17075           <leadingDigits>
17076             70|
17077             8[01]|
17078             90[2359]
17079           </leadingDigits>
17080           <format>$1 $2 $3</format>
17081         </numberFormat>
17082         <numberFormat pattern="([78]00)(\d{4})(\d{4,5})">
17083           <leadingDigits>[78]00</leadingDigits>
17084           <format>$1 $2 $3</format>
17085         </numberFormat>
17086         <numberFormat pattern="([78]00)(\d{5})(\d{5,6})">
17087           <leadingDigits>[78]00</leadingDigits>
17088           <format>$1 $2 $3</format>
17089         </numberFormat>
17090         <numberFormat pattern="(78)(\d{2})(\d{3})">
17091           <leadingDigits>78</leadingDigits>
17092           <format>$1 $2 $3</format>
17093         </numberFormat>
17094       </availableFormats>
17095       <generalDesc>
17096         <nationalNumberPattern>
17097           [1-6]\d{5,8}|
17098           9\d{5,9}|
17099           [78]\d{5,13}
17100         </nationalNumberPattern>
17101         <possibleNumberPattern>\d{5,14}</possibleNumberPattern>
17102       </generalDesc>
17103       <fixedLine>
17104         <nationalNumberPattern>
17105           [12]\d{6,7}|
17106           9(?:
17107             0[3-9]|
17108             [1-9]\d
17109           )\d{5}|
17110           (?:
17111             3\d|
17112             4[023568]|
17113             5[02368]|
17114             6[02-469]|
17115             7[4-69]|
17116             8[2-9]
17117           )\d{6}|
17118           (?:
17119             4[47]|
17120             5[14579]|
17121             6[1578]|
17122             7[0-357]
17123           )\d{5,6}|
17124           (?:
17125             78|
17126             41
17127           )\d{5}
17128         </nationalNumberPattern>
17129         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
17130         <exampleNumber>12345678</exampleNumber>
17131       </fixedLine>
17132       <mobile>
17133         <!-- More 81X prefixes have been added based on online numbers, including the prefix 817
17134              from Etisalat, 814 MTN and 811 from Glo. Furthermore, the fixed-line prefixes owned by
17135              Starcomms have apparently, according to the company, been used for mobile numbers too,
17136              despite the ITU plan, so we list them here as well. 701 has been added for Airtel/Zain.
17137              903 has been added for MTN, 905 has been added for Globacom (Glo), and 909 has been
17138              added for Etisalat. -->
17139         <nationalNumberPattern>
17140           (?:
17141             1(?:
17142               7[34]\d|
17143               8(?:
17144                 04|
17145                 [124579]\d|
17146                 8[0-3]
17147               )|
17148               95\d
17149             )|
17150             287[0-7]|
17151             3(?:
17152               18[1-8]|
17153               88[0-7]|
17154               9(?:
17155                 8[5-9]|
17156                 6[1-5]
17157               )
17158             )|
17159             4(?:
17160               28[0-2]|
17161               6(?:
17162                 7[1-9]|
17163                 8[02-47]
17164               )|
17165               88[0-2]
17166             )|
17167             5(?:
17168               2(?:
17169                 7[7-9]|
17170                 8\d
17171               )|
17172               38[1-79]|
17173               48[0-7]|
17174               68[4-7]
17175             )|
17176             6(?:
17177               2(?:
17178                 7[7-9]|
17179                 8\d
17180               )|
17181               4(?:
17182                 3[7-9]|
17183                 [68][129]|
17184                 7[04-69]|
17185                 9[1-8]
17186               )|
17187               58[0-2]|
17188               98[7-9]
17189             )|
17190             7(?:
17191               38[0-7]|
17192               69[1-8]|
17193               78[2-4]
17194             )|
17195             8(?:
17196               28[3-9]|
17197               38[0-2]|
17198               4(?:
17199                 2[12]|
17200                 3[147-9]|
17201                 5[346]|
17202                 7[4-9]|
17203                 8[014-689]|
17204                 90
17205               )|
17206               58[1-8]|
17207               78[2-9]|
17208               88[5-7]
17209             )|
17210             98[07]\d
17211           )\d{4}|
17212           (?:
17213             70(?:
17214               [13-9]\d|
17215               2[1-9]
17216             )|
17217             8(?:
17218               0[2-9]|
17219               1\d
17220             )\d|
17221             90[2359]\d
17222           )\d{6}
17223         </nationalNumberPattern>
17224         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
17225         <exampleNumber>8021234567</exampleNumber>
17226       </mobile>
17227       <!-- Info on these numbers from http://www.alphatechnologieslimited.com. -->
17228       <tollFree>
17229         <nationalNumberPattern>800\d{7,11}</nationalNumberPattern>
17230         <possibleNumberPattern>\d{10,14}</possibleNumberPattern>
17231         <exampleNumber>80017591759</exampleNumber>
17232       </tollFree>
17233       <uan>
17234         <nationalNumberPattern>700\d{7,11}</nationalNumberPattern>
17235         <possibleNumberPattern>\d{10,14}</possibleNumberPattern>
17236         <exampleNumber>7001234567</exampleNumber>
17237       </uan>
17238     </territory>
17239
17240     <!-- Nicaragua -->
17241     <territory id="NI" countryCode="505" internationalPrefix="00">
17242       <references>
17243         <sourceUrl>http://www.itu.int/oth/T020200009A/en</sourceUrl>
17244       </references>
17245       <availableFormats>
17246         <numberFormat pattern="(\d{4})(\d{4})">
17247           <format>$1 $2</format>
17248         </numberFormat>
17249       </availableFormats>
17250       <generalDesc>
17251         <nationalNumberPattern>[12578]\d{7}</nationalNumberPattern>
17252         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17253       </generalDesc>
17254       <fixedLine>
17255         <nationalNumberPattern>2\d{7}</nationalNumberPattern>
17256         <exampleNumber>21234567</exampleNumber>
17257       </fixedLine>
17258       <mobile>
17259         <!-- 55[0-7], 57, 58 and 7[5-8] were added from bug reports/numbers found online. -->
17260         <nationalNumberPattern>
17261           5(?:
17262             5[0-7]\d{5}|
17263             [78]\d{6}
17264           )|
17265           7[5-8]\d{6}|
17266           8\d{7}
17267         </nationalNumberPattern>
17268         <exampleNumber>81234567</exampleNumber>
17269       </mobile>
17270       <tollFree>
17271         <nationalNumberPattern>1800\d{4}</nationalNumberPattern>
17272         <exampleNumber>18001234</exampleNumber>
17273       </tollFree>
17274     </territory>
17275
17276     <!-- Netherlands -->
17277     <territory id="NL" countryCode="31" internationalPrefix="00"
17278                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
17279                mobileNumberPortableRegion="true">
17280       <references>
17281         <sourceUrl>http://en.wikipedia.org/wiki/%2B31</sourceUrl>
17282         <sourceUrl>http://wetten.overheid.nl/BWBR0010198</sourceUrl>
17283       </references>
17284       <availableFormats>
17285         <numberFormat pattern="([1-578]\d)(\d{3})(\d{4})">
17286           <leadingDigits>
17287             1[035]|
17288             2[0346]|
17289             3[03568]|
17290             4[0356]|
17291             5[0358]|
17292             7|
17293             8[4578]
17294           </leadingDigits>
17295           <format>$1 $2 $3</format>
17296         </numberFormat>
17297         <numberFormat pattern="([1-5]\d{2})(\d{3})(\d{3})">
17298           <leadingDigits>
17299             1[16-8]|
17300             2[259]|
17301             3[124]|
17302             4[17-9]|
17303             5[124679]
17304           </leadingDigits>
17305           <format>$1 $2 $3</format>
17306         </numberFormat>
17307         <numberFormat pattern="(6)(\d{8})">
17308           <leadingDigits>6[0-57-9]</leadingDigits>
17309           <format>$1 $2</format>
17310         </numberFormat>
17311         <numberFormat pattern="(66)(\d{7})">
17312           <leadingDigits>66</leadingDigits>
17313           <format>$1 $2</format>
17314         </numberFormat>
17315         <numberFormat pattern="(14)(\d{3,4})" nationalPrefixFormattingRule="$FG">
17316           <leadingDigits>14</leadingDigits>
17317           <format>$1 $2</format>
17318         </numberFormat>
17319         <numberFormat pattern="([89]0\d)(\d{4,7})">
17320           <leadingDigits>
17321             80|
17322             9
17323           </leadingDigits>
17324           <format>$1 $2</format>
17325         </numberFormat>
17326       </availableFormats>
17327       <generalDesc>
17328         <nationalNumberPattern>
17329           1\d{4,8}|
17330           [2-7]\d{8}|
17331           [89]\d{6,9}
17332         </nationalNumberPattern>
17333         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
17334       </generalDesc>
17335       <noInternationalDialling>
17336         <nationalNumberPattern>14\d{3,4}</nationalNumberPattern>
17337         <possibleNumberPattern>\d{5,6}</possibleNumberPattern>
17338       </noInternationalDialling>
17339       <fixedLine>
17340         <nationalNumberPattern>
17341           (?:
17342             1[0135-8]|
17343             2[02-69]|
17344             3[0-68]|
17345             4[0135-9]|
17346             [57]\d|
17347             8[478]
17348           )\d{7}
17349         </nationalNumberPattern>
17350         <possibleNumberPattern>\d{9}</possibleNumberPattern>
17351         <exampleNumber>101234567</exampleNumber>
17352       </fixedLine>
17353       <mobile>
17354         <nationalNumberPattern>6[1-58]\d{7}</nationalNumberPattern>
17355         <possibleNumberPattern>\d{9}</possibleNumberPattern>
17356         <exampleNumber>612345678</exampleNumber>
17357       </mobile>
17358       <pager>
17359         <nationalNumberPattern>66\d{7}</nationalNumberPattern>
17360         <possibleNumberPattern>\d{9}</possibleNumberPattern>
17361         <exampleNumber>662345678</exampleNumber>
17362       </pager>
17363       <tollFree>
17364         <nationalNumberPattern>800\d{4,7}</nationalNumberPattern>
17365         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
17366         <exampleNumber>8001234</exampleNumber>
17367       </tollFree>
17368       <premiumRate>
17369         <nationalNumberPattern>90[069]\d{4,7}</nationalNumberPattern>
17370         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
17371         <exampleNumber>9061234</exampleNumber>
17372       </premiumRate>
17373       <voip>
17374         <nationalNumberPattern>85\d{7}</nationalNumberPattern>
17375         <possibleNumberPattern>\d{9}</possibleNumberPattern>
17376         <exampleNumber>851234567</exampleNumber>
17377       </voip>
17378       <uan>
17379         <!-- These numbers are used for local government. They are formed by the appending the local
17380              dialling code (including the national prefix 0) after the leading digits "14". -->
17381         <nationalNumberPattern>
17382           140(?:
17383             1(?:
17384               [035]|
17385               [16-8]\d
17386             )|
17387             2(?:
17388               [0346]|
17389               [259]\d
17390             )|
17391             3(?:
17392               [03568]|
17393               [124]\d
17394             )|
17395             4(?:
17396               [0356]|
17397               [17-9]\d
17398             )|
17399             5(?:
17400               [0358]|
17401               [124679]\d
17402             )|
17403             7\d|
17404             8[458]
17405           )
17406         </nationalNumberPattern>
17407         <possibleNumberPattern>\d{5,6}</possibleNumberPattern>
17408         <exampleNumber>14020</exampleNumber>
17409       </uan>
17410     </territory>
17411
17412     <!-- Norway -->
17413     <!-- Metadata (excluding fixed-line) shared with Svalbard. -->
17414     <territory id="NO" countryCode="47" internationalPrefix="00" leadingZeroPossible="true"
17415                mainCountryForCode="true" mobileNumberPortableRegion="true">
17416       <references>
17417         <sourceUrl>http://www.npt.no/npt/numsys/E.164.pdf</sourceUrl>
17418       </references>
17419       <availableFormats>
17420         <numberFormat pattern="([489]\d{2})(\d{2})(\d{3})">
17421           <leadingDigits>[489]</leadingDigits>
17422           <format>$1 $2 $3</format>
17423         </numberFormat>
17424         <numberFormat pattern="([235-7]\d)(\d{2})(\d{2})(\d{2})">
17425           <leadingDigits>[235-7]</leadingDigits>
17426           <format>$1 $2 $3 $4</format>
17427         </numberFormat>
17428       </availableFormats>
17429       <generalDesc>
17430         <nationalNumberPattern>
17431           0\d{4}|
17432           [2-9]\d{7}
17433         </nationalNumberPattern>
17434         <possibleNumberPattern>\d{5}(?:\d{3})?</possibleNumberPattern>
17435       </generalDesc>
17436       <fixedLine>
17437         <!-- Excludes Svalbard fixed-line numbers. -->
17438         <nationalNumberPattern>
17439           (?:
17440             2[1-4]|
17441             3[1-3578]|
17442             5[1-35-7]|
17443             6[1-4679]|
17444             7[0-8]
17445           )\d{6}
17446         </nationalNumberPattern>
17447         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17448         <exampleNumber>21234567</exampleNumber>
17449       </fixedLine>
17450       <mobile>
17451         <nationalNumberPattern>
17452           (?:
17453             4[015-8]|
17454             5[89]|
17455             9\d
17456           )\d{6}
17457         </nationalNumberPattern>
17458         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17459         <exampleNumber>40612345</exampleNumber>
17460       </mobile>
17461       <tollFree>
17462         <nationalNumberPattern>80[01]\d{5}</nationalNumberPattern>
17463         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17464         <exampleNumber>80012345</exampleNumber>
17465       </tollFree>
17466       <premiumRate>
17467         <nationalNumberPattern>82[09]\d{5}</nationalNumberPattern>
17468         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17469         <exampleNumber>82012345</exampleNumber>
17470       </premiumRate>
17471       <sharedCost>
17472         <nationalNumberPattern>
17473           810(?:
17474             0[0-6]|
17475             [2-8]\d
17476           )\d{3}
17477         </nationalNumberPattern>
17478         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17479         <exampleNumber>81021234</exampleNumber>
17480       </sharedCost>
17481       <personalNumber>
17482         <nationalNumberPattern>880\d{5}</nationalNumberPattern>
17483         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17484         <exampleNumber>88012345</exampleNumber>
17485       </personalNumber>
17486       <voip>
17487         <nationalNumberPattern>85[0-5]\d{5}</nationalNumberPattern>
17488         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17489         <exampleNumber>85012345</exampleNumber>
17490       </voip>
17491       <uan>
17492         <!-- Includes some 810 local-rate numbers, and long-distance rate numbers. -->
17493         <nationalNumberPattern>
17494           0\d{4}|
17495           81(?:
17496             0(?:
17497               0[7-9]|
17498               1\d
17499             )|
17500             5\d{2}
17501           )\d{3}
17502         </nationalNumberPattern>
17503         <exampleNumber>01234</exampleNumber>
17504       </uan>
17505       <voicemail>
17506         <nationalNumberPattern>81[23]\d{5}</nationalNumberPattern>
17507         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17508         <exampleNumber>81212345</exampleNumber>
17509       </voicemail>
17510     </territory>
17511
17512     <!-- Nepal -->
17513     <territory id="NP" countryCode="977" internationalPrefix="00"
17514                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
17515       <references>
17516         <sourceUrl>http://www.itu.int/oth/T0202000095/en</sourceUrl>
17517         <sourceUrl>http://www.ntc.net.np/mobile/mob_postpaid_number_scheme.php</sourceUrl>
17518         <sourceUrl>http://www.nta.gov.np/en/2012-06-01-11-45-17/2012-06-04-04-26-59/numbering-plan</sourceUrl>
17519       </references>
17520       <availableFormats>
17521         <!-- Formatting patterns taken from pages like http://www.nepalgov.gov.np -->
17522         <numberFormat pattern="(1)(\d{7})">
17523           <leadingDigits>1[2-6]</leadingDigits>
17524           <format>$1-$2</format>
17525         </numberFormat>
17526         <numberFormat pattern="(\d{2})(\d{6})">
17527           <leadingDigits>
17528             1[01]|
17529             [2-8]|
17530             9(?:
17531               [1-69]|
17532               7[15-9]
17533             )
17534           </leadingDigits>
17535           <format>$1-$2</format>
17536         </numberFormat>
17537         <numberFormat pattern="(9\d{2})(\d{7})">
17538           <leadingDigits>
17539             9(?:
17540               6[013]|
17541               7[245]|
17542               8
17543             )
17544             </leadingDigits>
17545           <format>$1-$2</format>
17546         </numberFormat>
17547       </availableFormats>
17548       <generalDesc>
17549         <!-- This is complex, in order to try and distinguish between numbers that start with 97 and
17550              numbers that have the country code prefixed. -->
17551         <nationalNumberPattern>
17552           [1-8]\d{7}|
17553           9(?:
17554             [1-69]\d{6,8}|
17555             7[2-6]\d{5,7}|
17556             8\d{8}
17557           )
17558         </nationalNumberPattern>
17559         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
17560       </generalDesc>
17561       <!-- We don't support Rural Telecommunication Service at the moment since
17562            we are not sure what type it is. -->
17563       <fixedLine>
17564         <nationalNumberPattern>
17565           (?:
17566             1[0-6]\d|
17567             2[13-79][2-6]|
17568             3[135-8][2-6]|
17569             4[146-9][2-6]|
17570             5[135-7][2-6]|
17571             6[13-9][2-6]|
17572             7[15-9][2-6]|
17573             8[1-46-9][2-6]|
17574             9[1-79][2-6]
17575           )\d{5}
17576         </nationalNumberPattern>
17577         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
17578         <exampleNumber>14567890</exampleNumber>
17579       </fixedLine>
17580       <mobile>
17581         <nationalNumberPattern>
17582           9(?:
17583             6[013]|
17584             7[245]|
17585             8[01456]
17586           )\d{7}
17587         </nationalNumberPattern>
17588         <possibleNumberPattern>\d{10}</possibleNumberPattern>
17589         <exampleNumber>9841234567</exampleNumber>
17590       </mobile>
17591       <!-- No information on other types of phone numbers for Nepal has been found. -->
17592     </territory>
17593
17594     <!-- Nauru -->
17595     <territory id="NR" countryCode="674" internationalPrefix="00">
17596       <references>
17597         <sourceUrl>http://www.itu.int/oth/T0202000094/en</sourceUrl>
17598         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Nauru</sourceUrl>
17599       </references>
17600       <availableFormats>
17601         <numberFormat pattern="(\d{3})(\d{4})">
17602           <format>$1 $2</format>
17603         </numberFormat>
17604       </availableFormats>
17605       <generalDesc>
17606         <nationalNumberPattern>[458]\d{6}</nationalNumberPattern>
17607         <possibleNumberPattern>\d{7}</possibleNumberPattern>
17608       </generalDesc>
17609       <fixedLine>
17610         <nationalNumberPattern>
17611           (?:
17612             444|
17613             888
17614           )\d{4}
17615         </nationalNumberPattern>
17616         <exampleNumber>4441234</exampleNumber>
17617       </fixedLine>
17618       <mobile>
17619         <nationalNumberPattern>55[5-9]\d{4}</nationalNumberPattern>
17620         <exampleNumber>5551234</exampleNumber>
17621       </mobile>
17622     </territory>
17623
17624     <!-- Niue -->
17625     <territory id="NU" countryCode="683" internationalPrefix="00">
17626       <references>
17627         <sourceUrl>http://www.itu.int/oth/T02020000EC/en</sourceUrl>
17628         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Niue</sourceUrl>
17629       </references>
17630       <!-- Numbers are always formatted as a block. -->
17631       <generalDesc>
17632         <nationalNumberPattern>[1-5]\d{3}</nationalNumberPattern>
17633         <possibleNumberPattern>\d{4}</possibleNumberPattern>
17634       </generalDesc>
17635       <fixedLine>
17636         <!-- Putting FWT (fixed-wireless-terminals) numbers here too. -->
17637         <nationalNumberPattern>[34]\d{3}</nationalNumberPattern>
17638         <exampleNumber>4002</exampleNumber>
17639       </fixedLine>
17640       <mobile>
17641         <nationalNumberPattern>[125]\d{3}</nationalNumberPattern>
17642         <exampleNumber>1234</exampleNumber>
17643       </mobile>
17644     </territory>
17645
17646     <!-- New Zealand -->
17647     <!-- Includes Ross Dependency, Antarctica -->
17648     <!-- Does not currently support 083 "Enhanced voice services", New Zealand direct service
17649          numbers and 050 "Nation-Wide Service". -->
17650     <territory id="NZ" countryCode="64" internationalPrefix="0(?:0|161)"
17651                preferredInternationalPrefix="00" nationalPrefix="0"
17652                nationalPrefixFormattingRule="$NP$FG" mobileNumberPortableRegion="true">
17653       <references>
17654         <sourceUrl>http://www.itu.int/oth/T0202000099/en</sourceUrl>
17655       </references>
17656       <availableFormats>
17657         <!-- Pattern for fixed-line formats. -->
17658         <numberFormat pattern="([34679])(\d{3})(\d{4})">
17659           <leadingDigits>
17660             [346]|
17661             7[2-57-9]|
17662             9[1-9]
17663           </leadingDigits>
17664           <format>$1-$2 $3</format>
17665         </numberFormat>
17666         <!-- Area code for NZ's Scott Base, in Antarctica. -->
17667         <numberFormat pattern="(24099)(\d{3})">
17668           <leadingDigits>240</leadingDigits>
17669           <leadingDigits>2409</leadingDigits>
17670           <leadingDigits>24099</leadingDigits>
17671           <format>$1 $2</format>
17672         </numberFormat>
17673         <!-- Mobile numbers do not have exclusive leading digits - formatting depends on number
17674              length. -->
17675         <!-- Vodafone numbers can be 8 digits (without leading 0). -->
17676         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
17677           <leadingDigits>21</leadingDigits>
17678           <format>$1 $2 $3</format>
17679         </numberFormat>
17680         <!-- Paging numbers and some mobile numbers (Telecom/Vodafone/TelstraClear). -->
17681         <numberFormat pattern="(\d{2})(\d{3})(\d{3,5})">
17682           <leadingDigits>
17683             2(?:
17684               1[1-9]|
17685               [69]|
17686               7[0-35-9]
17687             )|
17688             70|
17689             86
17690           </leadingDigits>
17691           <format>$1 $2 $3</format>
17692         </numberFormat>
17693         <!-- 2Degrees numbers are formatted with 022 separated, since this seems to be more common
17694              than writing the first group as 022X based on Google web searches, and is used by
17695              2Degrees themselves. See formatting on http://www.2degreesmobile.co.nz for an example
17696              of the latter. We follow the same pattern for 020 (Orcon) and 028 (mixed) numbers. -->
17697         <numberFormat pattern="(2\d)(\d{3,4})(\d{4})">
17698           <leadingDigits>2[028]</leadingDigits>
17699           <format>$1 $2 $3</format>
17700         </numberFormat>
17701         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
17702           <!-- 0274, 0210 and toll-free/premium-rate prefixes 0508/0800/0900. -->
17703           <leadingDigits>
17704             2(?:
17705               10|
17706               74
17707             )|
17708             5|
17709             [89]0
17710           </leadingDigits>
17711           <format>$1 $2 $3</format>
17712         </numberFormat>
17713       </availableFormats>
17714       <generalDesc>
17715         <nationalNumberPattern>
17716           6[235-9]\d{6}|
17717           [2-57-9]\d{7,10}
17718         </nationalNumberPattern>
17719         <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
17720       </generalDesc>
17721       <fixedLine>
17722         <nationalNumberPattern>
17723           (?:
17724             3[2-79]|
17725             [49][2-9]|
17726             6[235-9]|
17727             7[2-57-9]
17728           )\d{6}|
17729           24099\d{3}
17730         </nationalNumberPattern>
17731         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
17732         <exampleNumber>32345678</exampleNumber>
17733       </fixedLine>
17734       <mobile>
17735         <!-- Includes mobile radio service numbers (e.g. TeamTalk). The lengths of numbers with
17736              prefix 21 are different from what's specified in the ITU doc, because of numbers found
17737              online. -->
17738         <nationalNumberPattern>
17739           2(?:
17740             [028]\d{7,8}|
17741             1(?:
17742               [03]\d{5,7}|
17743               [12457]\d{5,6}|
17744               [689]\d{5}
17745             )|
17746             [79]\d{7}
17747           )
17748         </nationalNumberPattern>
17749         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
17750         <exampleNumber>211234567</exampleNumber>
17751       </mobile>
17752       <pager>
17753         <nationalNumberPattern>[28]6\d{6,7}</nationalNumberPattern>
17754         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
17755         <exampleNumber>26123456</exampleNumber>
17756       </pager>
17757       <!-- These are the toll free patterns used, by Telecom and Telstra/Clear, but they are
17758            referred to as 'Value-added service' in the phone plan for some reason. 85 numbers are
17759            not covered, as telecom companies don't seem to support them yet. -->
17760       <tollFree>
17761         <nationalNumberPattern>
17762           508\d{6,7}|
17763           80\d{6,8}
17764         </nationalNumberPattern>
17765         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
17766         <exampleNumber>800123456</exampleNumber>
17767       </tollFree>
17768       <premiumRate>
17769         <nationalNumberPattern>90\d{7,9}</nationalNumberPattern>
17770         <possibleNumberPattern>\d{9,11}</possibleNumberPattern>
17771         <exampleNumber>900123456</exampleNumber>
17772       </premiumRate>
17773       <personalNumber>
17774         <nationalNumberPattern>70\d{7}</nationalNumberPattern>
17775         <possibleNumberPattern>\d{9}</possibleNumberPattern>
17776         <exampleNumber>701234567</exampleNumber>
17777       </personalNumber>
17778     </territory>
17779
17780     <!-- Oman -->
17781     <territory id="OM" countryCode="968" internationalPrefix="00" mobileNumberPortableRegion="true">
17782       <references>
17783         <sourceUrl>http://www.itu.int/oth/T020200009F/en</sourceUrl>
17784       </references>
17785       <availableFormats>
17786         <numberFormat pattern="(2\d)(\d{6})">
17787           <leadingDigits>2</leadingDigits>
17788           <format>$1 $2</format>
17789         </numberFormat>
17790         <numberFormat pattern="(9\d{3})(\d{4})">
17791           <leadingDigits>9</leadingDigits>
17792           <format>$1 $2</format>
17793         </numberFormat>
17794         <numberFormat pattern="([58]00)(\d{4,6})">
17795           <leadingDigits>[58]</leadingDigits>
17796           <format>$1 $2</format>
17797         </numberFormat>
17798       </availableFormats>
17799       <generalDesc>
17800         <nationalNumberPattern>
17801           (?:
17802             2[2-6]|
17803             5|
17804             9[1-9]
17805           )\d{6}|
17806           800\d{5,6}
17807         </nationalNumberPattern>
17808         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
17809       </generalDesc>
17810       <fixedLine>
17811         <nationalNumberPattern>2[2-6]\d{6}</nationalNumberPattern>
17812         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17813         <exampleNumber>23123456</exampleNumber>
17814       </fixedLine>
17815       <mobile>
17816         <nationalNumberPattern>9[1-9]\d{6}</nationalNumberPattern>
17817         <possibleNumberPattern>\d{8}</possibleNumberPattern>
17818         <exampleNumber>92123456</exampleNumber>
17819       </mobile>
17820       <tollFree>
17821         <!-- Link to document about toll-free numbers on http://www.tra.gov.om, which suggests they
17822              should be 8007 followed by 4 digits. However, the only examples I can find, including
17823              the customer help line for the main telephony company there (omantel), is 8007 followed
17824              by 5 digits, so am allowing both for now to be on the safe side. 500 numbers seem to
17825              offer international toll-free dialing numbers - +968 500 1300 for international help
17826              desk for omantel, for example. -->
17827         <nationalNumberPattern>
17828           8007\d{4,5}|
17829           500\d{4}
17830         </nationalNumberPattern>
17831         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
17832         <exampleNumber>80071234</exampleNumber>
17833       </tollFree>
17834       <!-- No premiumRate information can be found. -->
17835     </territory>
17836
17837     <!-- Panama -->
17838     <territory id="PA" countryCode="507" internationalPrefix="00" mobileNumberPortableRegion="true">
17839       <references>
17840         <!-- Last read July 9, 2014. -->
17841         <sourceUrl>http://www.asep.gob.pa/telecom/pnn/default.asp</sourceUrl>
17842         <!-- Omits the fact that mobile phones are 8 digits long. -->
17843         <sourceUrl>http://en.wikipedia.org/wiki/%2B507</sourceUrl>
17844       </references>
17845       <availableFormats>
17846         <numberFormat pattern="(\d{3})(\d{4})">
17847           <leadingDigits>[1-57-9]</leadingDigits>
17848           <format>$1-$2</format>
17849         </numberFormat>
17850         <numberFormat pattern="(\d{4})(\d{4})">
17851           <leadingDigits>6</leadingDigits>
17852           <format>$1-$2</format>
17853         </numberFormat>
17854       </availableFormats>
17855       <generalDesc>
17856         <nationalNumberPattern>[1-9]\d{6,7}</nationalNumberPattern>
17857         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
17858       </generalDesc>
17859       <!-- Note that numbers starting with 101, 106, 131, 151, 156 and 168 have not been assigned to
17860            any rule below since we are not sure what the "servicios 102/103" refer to here. -->
17861       <fixedLine>
17862         <!-- Note that "servicios 101/104" in the plan refer to "Local Basic Communications Service"
17863              and "Public and Semipublic Terminal Service", represented here as fixed-line. -->
17864         <!-- The range 194-XXXX has been added since a number was found online with this prefix and
17865              proved to be diallable. -->
17866         <nationalNumberPattern>
17867           (?:
17868             1(?:
17869               0[02-579]|
17870               19|
17871               2[37]|
17872               3[03]|
17873               4[479]|
17874               57|
17875               65|
17876               7[016-8]|
17877               8[58]|
17878               9[1349]
17879             )|
17880             2(?:
17881               [0235679]\d|
17882               1[0-7]|
17883               4[04-9]|
17884               8[028]
17885             )|
17886             3(?:
17887               [09]\d|
17888               1[14-7]|
17889               2[0-3]|
17890               3[03]|
17891               4[0457]|
17892               5[56]|
17893               6[068]|
17894               7[06-8]|
17895               8[089]
17896             )|
17897             4(?:
17898               3[013-69]|
17899               4\d|
17900               7[0-689]
17901             )|
17902             5(?:
17903               [01]\d|
17904               2[0-7]|
17905               [56]0|
17906               79
17907             )|
17908             7(?:
17909               0[09]|
17910               2[0-267]|
17911               3[06]|
17912               [49]0|
17913               5[06-9]|
17914               7[0-24-7]|
17915               8[89]
17916             )|
17917             8(?:
17918               [34]\d|
17919               5[0-4]|
17920               8[02]
17921             )|
17922             9(?:
17923               0[6-8]|
17924               1[016-8]|
17925               2[036-8]|
17926               3[3679]|
17927               40|
17928               5[0489]|
17929               6[06-9]|
17930               7[046-9]|
17931               8[36-8]|
17932               9[1-9]
17933             )
17934           )\d{4}
17935         </nationalNumberPattern>
17936         <possibleNumberPattern>\d{7}</possibleNumberPattern>
17937         <exampleNumber>2001234</exampleNumber>
17938       </fixedLine>
17939       <mobile>
17940         <!-- Note that "servicios 106/107" in the plan refer to mobile services. We also include
17941              service "210", "Servicio de Busca Personas". -->
17942         <nationalNumberPattern>
17943           (?:
17944             1[16]1|
17945             21[89]|
17946             8(?:
17947               1[01]|
17948               7[23]
17949             )
17950           )\d{4}|
17951           6(?:
17952             [024-9]\d|
17953             1[0-5]|
17954             3[0-24-9]
17955           )\d{5}
17956         </nationalNumberPattern>
17957         <exampleNumber>60012345</exampleNumber>
17958       </mobile>
17959       <tollFree>
17960         <nationalNumberPattern>80[09]\d{4}</nationalNumberPattern>
17961         <possibleNumberPattern>\d{7}</possibleNumberPattern>
17962         <exampleNumber>8001234</exampleNumber>
17963       </tollFree>
17964       <premiumRate>
17965         <!-- Value-added services are represented as "400" in the plan. -->
17966         <nationalNumberPattern>
17967           (?:
17968             779|
17969             8(?:
17970               2[235]|
17971               55|
17972               60|
17973               7[578]|
17974               86|
17975               95
17976             )|
17977             9(?:
17978               0[0-2]|
17979               81
17980             )
17981           )\d{4}
17982         </nationalNumberPattern>
17983         <possibleNumberPattern>\d{7}</possibleNumberPattern>
17984         <exampleNumber>8601234</exampleNumber>
17985       </premiumRate>
17986     </territory>
17987
17988     <!-- Peru -->
17989     <territory id="PE" countryCode="51" internationalPrefix="19(?:1[124]|77|90)00"
17990                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
17991                preferredExtnPrefix=" Anexo " mobileNumberPortableRegion="true">
17992       <references>
17993         <sourceUrl>http://www.itu.int/oth/T02020000A6/en</sourceUrl>
17994         <sourceUrl>http://en.wikipedia.org/wiki/+51</sourceUrl>
17995         <sourceUrl>http://www.assistbook.com/South%20America/Peru/widecodes</sourceUrl>
17996       </references>
17997       <availableFormats>
17998         <numberFormat pattern="(1)(\d{7})">
17999           <leadingDigits>1</leadingDigits>
18000           <format>$1 $2</format>
18001         </numberFormat>
18002         <numberFormat pattern="([4-8]\d)(\d{6})">
18003           <leadingDigits>
18004             [4-7]|
18005             8[2-4]
18006           </leadingDigits>
18007           <format>$1 $2</format>
18008         </numberFormat>
18009         <numberFormat pattern="(\d{3})(\d{5})">
18010           <leadingDigits>80</leadingDigits>
18011           <format>$1 $2</format>
18012         </numberFormat>
18013         <!-- Formatting from common usage found on the internet, supported by ITU doc. -->
18014         <numberFormat pattern="(9\d{2})(\d{3})(\d{3})"
18015                       nationalPrefixFormattingRule="$FG">
18016           <leadingDigits>9</leadingDigits>
18017           <format>$1 $2 $3</format>
18018         </numberFormat>
18019       </availableFormats>
18020       <generalDesc>
18021         <nationalNumberPattern>[14-9]\d{7,8}</nationalNumberPattern>
18022         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
18023       </generalDesc>
18024       <fixedLine>
18025         <nationalNumberPattern>
18026           (?:
18027             1\d|
18028             4[1-4]|
18029             5[1-46]|
18030             6[1-7]|
18031             7[2-46]|
18032             8[2-4]
18033           )\d{6}
18034         </nationalNumberPattern>
18035         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
18036         <exampleNumber>11234567</exampleNumber>
18037       </fixedLine>
18038       <mobile>
18039         <nationalNumberPattern>9\d{8}</nationalNumberPattern>
18040         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18041         <exampleNumber>912345678</exampleNumber>
18042       </mobile>
18043       <tollFree>
18044         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
18045         <possibleNumberPattern>\d{8}</possibleNumberPattern>
18046         <exampleNumber>80012345</exampleNumber>
18047       </tollFree>
18048       <premiumRate>
18049         <nationalNumberPattern>805\d{5}</nationalNumberPattern>
18050         <possibleNumberPattern>\d{8}</possibleNumberPattern>
18051         <exampleNumber>80512345</exampleNumber>
18052       </premiumRate>
18053       <sharedCost>
18054         <nationalNumberPattern>801\d{5}</nationalNumberPattern>
18055         <possibleNumberPattern>\d{8}</possibleNumberPattern>
18056         <exampleNumber>80112345</exampleNumber>
18057       </sharedCost>
18058       <personalNumber>
18059         <nationalNumberPattern>80[24]\d{5}</nationalNumberPattern>
18060         <possibleNumberPattern>\d{8}</possibleNumberPattern>
18061         <exampleNumber>80212345</exampleNumber>
18062       </personalNumber>
18063     </territory>
18064
18065     <!-- French Polynesia (Tahiti) (Territoire français d'outre-mer) -->
18066     <territory id="PF" countryCode="689" internationalPrefix="00">
18067       <references>
18068         <sourceUrl>http://www.itu.int/oth/T020200004D/en</sourceUrl>
18069       </references>
18070       <availableFormats>
18071         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
18072           <leadingDigits>
18073             4[09]|
18074             8[79]
18075           </leadingDigits>
18076           <format>$1 $2 $3 $4</format>
18077         </numberFormat>
18078         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
18079           <leadingDigits>44</leadingDigits>
18080           <format>$1 $2 $3</format>
18081         </numberFormat>
18082       </availableFormats>
18083       <generalDesc>
18084         <nationalNumberPattern>
18085           4\d{5,7}|
18086           8\d{7}
18087         </nationalNumberPattern>
18088         <possibleNumberPattern>\d{6}(?:\d{2})?</possibleNumberPattern>
18089       </generalDesc>
18090       <noInternationalDialling>
18091         <nationalNumberPattern>44\d{4}</nationalNumberPattern>
18092         <possibleNumberPattern>\d{6}</possibleNumberPattern>
18093         <exampleNumber>441234</exampleNumber>
18094       </noInternationalDialling>
18095       <fixedLine>
18096         <!-- Includes payphone prefixes. -->
18097         <nationalNumberPattern>
18098           4(?:
18099             [09][45689]\d|
18100             4
18101           )\d{4}
18102         </nationalNumberPattern>
18103         <exampleNumber>40412345</exampleNumber>
18104       </fixedLine>
18105       <mobile>
18106         <nationalNumberPattern>8[79]\d{6}</nationalNumberPattern>
18107         <possibleNumberPattern>\d{8}</possibleNumberPattern>
18108         <exampleNumber>87123456</exampleNumber>
18109       </mobile>
18110     </territory>
18111
18112     <!-- Papua New Guinea -->
18113     <territory id="PG" countryCode="675" internationalPrefix="00">
18114       <references>
18115         <sourceUrl>http://www.itu.int/oth/T02020000A4/en</sourceUrl>
18116         <sourceUrl>http://en.wikipedia.org/wiki/%2B675</sourceUrl>
18117       </references>
18118       <availableFormats>
18119         <numberFormat pattern="(\d{3})(\d{4})">
18120           <leadingDigits>
18121             [13-689]|
18122             27
18123           </leadingDigits>
18124           <format>$1 $2</format>
18125         </numberFormat>
18126         <numberFormat pattern="(\d{4})(\d{4})">
18127           <leadingDigits>
18128             20|
18129             7
18130           </leadingDigits>
18131           <format>$1 $2</format>
18132         </numberFormat>
18133       </availableFormats>
18134       <generalDesc>
18135         <nationalNumberPattern>[1-9]\d{6,7}</nationalNumberPattern>
18136         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
18137       </generalDesc>
18138       <fixedLine>
18139         <nationalNumberPattern>
18140           (?:
18141             3[0-2]\d|
18142             4[25]\d|
18143             5[34]\d|
18144             64[1-9]|
18145             77(?:
18146               [0-24]\d|
18147               30
18148             )|
18149             85[02-46-9]|
18150             9[78]\d
18151           )\d{4}
18152         </nationalNumberPattern>
18153         <possibleNumberPattern>\d{7}</possibleNumberPattern>
18154         <exampleNumber>3123456</exampleNumber>
18155       </fixedLine>
18156       <mobile>
18157         <!-- Mobile number patterns from the numbering plan are included here, as well as 68X from
18158              Wikipedia.
18159              As per ITU doc, prefix 20150 will expire at the end of 2015. -->
18160         <nationalNumberPattern>
18161           (?:
18162             20150|
18163             68\d{2}|
18164             7(?:
18165               [0-369]\d|
18166               75
18167             )\d{2}
18168           )\d{3}
18169         </nationalNumberPattern>
18170         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
18171         <exampleNumber>6812345</exampleNumber>
18172       </mobile>
18173       <tollFree>
18174         <nationalNumberPattern>180\d{4}</nationalNumberPattern>
18175         <possibleNumberPattern>\d{7}</possibleNumberPattern>
18176         <exampleNumber>1801234</exampleNumber>
18177       </tollFree>
18178       <voip>
18179         <!-- VSAT prefixes are here. -->
18180         <nationalNumberPattern>275\d{4}</nationalNumberPattern>
18181         <possibleNumberPattern>\d{7}</possibleNumberPattern>
18182         <exampleNumber>2751234</exampleNumber>
18183       </voip>
18184     </territory>
18185
18186     <!-- Philippines -->
18187     <territory id="PH" countryCode="63" internationalPrefix="00" nationalPrefix="0">
18188       <references>
18189         <sourceUrl>http://en.wikipedia.org/wiki/%2B63</sourceUrl>
18190       </references>
18191       <availableFormats>
18192         <!-- Area code separated from number. Area codes found here:
18193         http://en.wikipedia.org/wiki/Telecommunications_in_the_Philippines#Area_Codes -->
18194         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
18195           pattern="(2)(\d{3})(\d{4})">
18196           <leadingDigits>2</leadingDigits>
18197           <format>$1 $2 $3</format>
18198         </numberFormat>
18199         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
18200           pattern="(2)(\d{5})">
18201           <leadingDigits>2</leadingDigits>
18202           <format>$1 $2</format>
18203         </numberFormat>
18204         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
18205           pattern="(\d{4})(\d{4,6})">
18206           <leadingDigits>
18207             3(?:
18208               23|
18209               39|
18210               46
18211             )|
18212             4(?:
18213               2[3-6]|
18214               [35]9|
18215               4[26]|
18216               76
18217             )|
18218             5(?:
18219               22|
18220               44
18221             )|
18222             642|
18223             8(?:
18224               62|
18225               8[245]
18226             )
18227           </leadingDigits>
18228           <leadingDigits>
18229             3(?:
18230               230|
18231               397|
18232               461
18233             )|
18234             4(?:
18235               2(?:
18236                 35|
18237                 [46]4|
18238                 51
18239               )|
18240               396|
18241               4(?:
18242                 22|
18243                 63
18244               )|
18245               59[347]|
18246               76[15]
18247             )|
18248             5(?:
18249               221|
18250               446
18251             )|
18252             642[23]|
18253             8(?:
18254               622|
18255               8(?:
18256                 [24]2|
18257                 5[13]
18258               )
18259             )
18260           </leadingDigits>
18261           <format>$1 $2</format>
18262         </numberFormat>
18263         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
18264           pattern="(\d{5})(\d{4})">
18265           <leadingDigits>
18266             346|
18267             4(?:
18268               27|
18269               9[35]
18270             )|
18271             883
18272           </leadingDigits>
18273           <leadingDigits>
18274             3469|
18275             4(?:
18276               279|
18277               9(?:
18278                 30|
18279                 56
18280               )
18281             )|
18282             8834
18283           </leadingDigits>
18284           <format>$1 $2</format>
18285         </numberFormat>
18286         <!-- This rule is a fallback for the more specific area codes. -->
18287         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
18288           pattern="([3-8]\d)(\d{3})(\d{4})">
18289           <leadingDigits>[3-8]</leadingDigits>
18290           <format>$1 $2 $3</format>
18291         </numberFormat>
18292         <numberFormat nationalPrefixFormattingRule="$NP$FG"
18293           pattern="(\d{3})(\d{3})(\d{4})">
18294           <leadingDigits>
18295             81|
18296             9
18297           </leadingDigits>
18298           <format>$1 $2 $3</format>
18299         </numberFormat>
18300         <!-- Formatting from http://www.uniontelecard.com/calling-guides/philippines/guide1.aspx -->
18301         <numberFormat pattern="(1800)(\d{3})(\d{4})">
18302           <leadingDigits>1</leadingDigits>
18303           <format>$1 $2 $3</format>
18304         </numberFormat>
18305         <numberFormat pattern="(1800)(\d{1,2})(\d{3})(\d{4})">
18306           <leadingDigits>1</leadingDigits>
18307           <format>$1 $2 $3 $4</format>
18308         </numberFormat>
18309       </availableFormats>
18310       <generalDesc>
18311         <nationalNumberPattern>
18312           2\d{5,7}|
18313           [3-9]\d{7,9}|
18314           1800\d{7,9}
18315         </nationalNumberPattern>
18316         <possibleNumberPattern>\d{5,13}</possibleNumberPattern>
18317       </generalDesc>
18318       <fixedLine>
18319         <!-- Evidence on number length is hard to come by. We have found diallable numbers in Manila
18320              that have only 5 digits after the area code; plus it seems the 8822 area code is
18321              followed by 6 digits, and 8842 by only 4. -->
18322         <nationalNumberPattern>
18323           2\d{5}(?:\d{2})?|
18324           (?:
18325             3[2-68]|
18326             4[2-9]|
18327             5[2-6]|
18328             6[2-58]|
18329             7[24578]|
18330             8[2-8]
18331           )\d{7}|
18332           88(?:
18333             22\d{6}|
18334             42\d{4}
18335           )
18336         </nationalNumberPattern>
18337         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
18338         <exampleNumber>21234567</exampleNumber>
18339       </fixedLine>
18340       <mobile>
18341         <nationalNumberPattern>
18342           (?:
18343             81[37]|
18344             9(?:
18345               0[5-9]|
18346               1[024-9]|
18347               2[0-35-9]|
18348               3[02-9]|
18349               4[236-9]|
18350               7[34-79]|
18351               89|
18352               9[4-9]
18353             )
18354           )\d{7}
18355         </nationalNumberPattern>
18356         <possibleNumberPattern>\d{10}</possibleNumberPattern>
18357         <exampleNumber>9051234567</exampleNumber>
18358       </mobile>
18359       <!-- Information on toll-free numbers collected from searching the internet -->
18360       <tollFree>
18361         <nationalNumberPattern>1800\d{7,9}</nationalNumberPattern>
18362         <possibleNumberPattern>\d{11,13}</possibleNumberPattern>
18363         <exampleNumber>180012345678</exampleNumber>
18364       </tollFree>
18365       <!-- No information can be found about other types of numbers (such as premium rate) in the
18366            Philippines. -->
18367     </territory>
18368
18369     <!-- Pakistan -->
18370     <territory id="PK" countryCode="92" internationalPrefix="00"
18371                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
18372                mobileNumberPortableRegion="true">
18373       <references>
18374         <sourceUrl>http://www.itu.int/oth/T02020000A1/en</sourceUrl>
18375         <sourceUrl>http://en.wikipedia.org/wiki/%2B92</sourceUrl>
18376       </references>
18377       <availableFormats>
18378         <!-- Universal Access Numbers (UAN) number format patterns first, so that these numbers are
18379              formatted nicely by the AYTF. -->
18380         <numberFormat pattern="(\d{2})(111)(\d{3})(\d{3})">
18381           <leadingDigits>
18382             (?:
18383               2[125]|
18384               4[0-246-9]|
18385               5[1-35-7]|
18386               6[1-8]|
18387               7[14]|
18388               8[16]|
18389               91
18390             )1
18391           </leadingDigits>
18392           <leadingDigits>
18393             (?:
18394               2[125]|
18395               4[0-246-9]|
18396               5[1-35-7]|
18397               6[1-8]|
18398               7[14]|
18399               8[16]|
18400               91
18401             )11
18402           </leadingDigits>
18403           <leadingDigits>
18404             (?:
18405               2[125]|
18406               4[0-246-9]|
18407               5[1-35-7]|
18408               6[1-8]|
18409               7[14]|
18410               8[16]|
18411               91
18412             )111
18413           </leadingDigits>
18414           <format>$1 $2 $3 $4</format>
18415         </numberFormat>
18416         <numberFormat pattern="(\d{3})(111)(\d{3})(\d{3})">
18417           <leadingDigits>
18418             2[349]|
18419             45|
18420             54|
18421             60|
18422             72|
18423             8[2-5]|
18424             9[2-9]
18425           </leadingDigits>
18426           <leadingDigits>
18427             (?:
18428               2[349]|
18429               45|
18430               54|
18431               60|
18432               72|
18433               8[2-5]|
18434               9[2-9]
18435             )\d1
18436           </leadingDigits>
18437           <leadingDigits>
18438             (?:
18439               2[349]|
18440               45|
18441               54|
18442               60|
18443               72|
18444               8[2-5]|
18445               9[2-9]
18446             )\d11
18447           </leadingDigits>
18448           <leadingDigits>
18449             (?:
18450               2[349]|
18451               45|
18452               54|
18453               60|
18454               72|
18455               8[2-5]|
18456               9[2-9]
18457             )\d111
18458           </leadingDigits>
18459           <format>$1 $2 $3 $4</format>
18460         </numberFormat>
18461         <numberFormat pattern="(\d{2})(\d{7,8})">
18462           <leadingDigits>
18463             (?:
18464               2[125]|
18465               4[0-246-9]|
18466               5[1-35-7]|
18467               6[1-8]|
18468               7[14]|
18469               8[16]|
18470               91
18471             )[2-9]
18472           </leadingDigits>
18473           <format>$1 $2</format>
18474         </numberFormat>
18475         <numberFormat pattern="(\d{3})(\d{6,7})">
18476           <leadingDigits>
18477             2[349]|
18478             45|
18479             54|
18480             60|
18481             72|
18482             8[2-5]|
18483             9[2-9]
18484           </leadingDigits>
18485           <leadingDigits>
18486             (?:
18487               2[349]|
18488               45|
18489               54|
18490               60|
18491               72|
18492               8[2-5]|
18493               9[2-9]
18494             )\d[2-9]
18495           </leadingDigits>
18496           <format>$1 $2</format>
18497         </numberFormat>
18498         <numberFormat pattern="(3\d{2})(\d{7})" nationalPrefixFormattingRule="$NP$FG">
18499           <leadingDigits>3</leadingDigits>
18500           <format>$1 $2</format>
18501         </numberFormat>
18502         <numberFormat pattern="([15]\d{3})(\d{5,6})">
18503           <leadingDigits>
18504             58[12]|
18505             1
18506           </leadingDigits>
18507           <format>$1 $2</format>
18508         </numberFormat>
18509         <!-- This is from online examples. -->
18510         <numberFormat pattern="(586\d{2})(\d{5})">
18511           <leadingDigits>586</leadingDigits>
18512           <format>$1 $2</format>
18513         </numberFormat>
18514         <numberFormat pattern="([89]00)(\d{3})(\d{2})" nationalPrefixFormattingRule="$NP$FG">
18515           <leadingDigits>[89]00</leadingDigits>
18516           <format>$1 $2 $3</format>
18517         </numberFormat>
18518       </availableFormats>
18519       <generalDesc>
18520         <!-- This is horribly complex because the country code is 92, and several area codes start
18521              with 92, and the number length is widely variable. -->
18522         <nationalNumberPattern>
18523           1\d{8}|
18524           [2-8]\d{5,11}|
18525           9(?:
18526             [013-9]\d{4,9}|
18527             2\d(?:
18528               111\d{6}|
18529               \d{3,7}
18530             )
18531           )
18532         </nationalNumberPattern>
18533         <possibleNumberPattern>\d{6,12}</possibleNumberPattern>
18534       </generalDesc>
18535       <fixedLine>
18536         <!-- The subscriber number length is not well defined for some area codes. From online
18537              examples, we have come up with a heuristic that for 3-digit area codes, the subscriber
18538              number will be 6 or 7 digits - for 2-digit area codes it will be 7, with the exceptions
18539              of Karachi and Lahore (both 8). -->
18540         <nationalNumberPattern>
18541           (?:
18542             21|
18543             42
18544           )[2-9]\d{7}|
18545           (?:
18546             2[25]|
18547             4[0146-9]|
18548             5[1-35-7]|
18549             6[1-8]|
18550             7[14]|
18551             8[16]|
18552             91
18553           )[2-9]\d{6}|
18554           (?:
18555             2(?:
18556               3[2358]|
18557               4[2-4]|
18558               9[2-8]
18559             )|
18560             45[3479]|
18561             54[2-467]|
18562             60[468]|
18563             72[236]|
18564             8(?:
18565               2[2-689]|
18566               3[23578]|
18567               4[3478]|
18568               5[2356]
18569             )|
18570             9(?:
18571               1|
18572               2[2-8]|
18573               3[27-9]|
18574               4[2-6]|
18575               6[3569]|
18576               9[25-8]
18577             )
18578           )[2-9]\d{5,6}|
18579           58[126]\d{7}
18580         </nationalNumberPattern>
18581         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
18582         <exampleNumber>2123456789</exampleNumber>
18583       </fixedLine>
18584       <mobile>
18585         <!-- Adding 311, 325 and 320 as SMSs have been successfully sent to these numbers and numbers
18586              can be found online with these prefixes. Added 310 based on information from Zong, and
18587              316 based on information found online. -->
18588         <nationalNumberPattern>
18589           3(?:
18590             0\d|
18591             1[0-6]|
18592             2[0-5]|
18593             [34][0-7]|
18594             55|
18595             64
18596           )\d{7}
18597         </nationalNumberPattern>
18598         <possibleNumberPattern>\d{10}</possibleNumberPattern>
18599         <exampleNumber>3012345678</exampleNumber>
18600       </mobile>
18601       <tollFree>
18602         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
18603         <possibleNumberPattern>\d{8}</possibleNumberPattern>
18604         <exampleNumber>80012345</exampleNumber>
18605       </tollFree>
18606       <premiumRate>
18607         <nationalNumberPattern>900\d{5}</nationalNumberPattern>
18608         <possibleNumberPattern>\d{8}</possibleNumberPattern>
18609         <exampleNumber>90012345</exampleNumber>
18610       </premiumRate>
18611       <!-- These are referred to as UPT numbers in the plan. -->
18612       <personalNumber>
18613         <nationalNumberPattern>122\d{6}</nationalNumberPattern>
18614         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18615         <!-- The example number here is the test number from the plan. -->
18616         <exampleNumber>122044444</exampleNumber>
18617       </personalNumber>
18618       <uan>
18619         <!-- Data on what a UAN is is hard to come by. http://www.ptcl.com.pk has information under
18620              http://www.ptcl.com.pk/contentb.php?NID=143#uan - which defines their format - but not
18621              what type of number they are. We exclude Azad Jammu, Kashmir and Northern Areas here
18622              since no online example UANs can be found, and they have an "access code" at the start,
18623              making it difficult to guess what a UAN in these areas would look like. -->
18624         <nationalNumberPattern>
18625           (?:
18626             2(?:
18627               [125]|
18628               3[2358]|
18629               4[2-4]|
18630               9[2-8]
18631             )|
18632             4(?:
18633               [0-246-9]|
18634               5[3479]
18635             )|
18636             5(?:
18637               [1-35-7]|
18638               4[2-467]
18639             )|
18640             6(?:
18641               [1-8]|
18642               0[468]
18643             )|
18644             7(?:
18645               [14]|
18646               2[236]
18647             )|
18648             8(?:
18649               [16]|
18650               2[2-689]|
18651               3[23578]|
18652               4[3478]|
18653               5[2356]
18654             )|
18655             9(?:
18656               1|
18657               22|
18658               3[27-9]|
18659               4[2-6]|
18660               6[3569]|
18661               9[2-7]
18662             )
18663           )111\d{6}
18664         </nationalNumberPattern>
18665         <possibleNumberPattern>\d{11,12}</possibleNumberPattern>
18666         <exampleNumber>21111825888</exampleNumber>
18667       </uan>
18668     </territory>
18669
18670     <!-- Poland -->
18671     <territory id="PL" countryCode="48" internationalPrefix="00" mobileNumberPortableRegion="true">
18672       <references>
18673         <sourceUrl>http://en.wikipedia.org/wiki/%2B48</sourceUrl>
18674         <sourceUrl>http://www.itu.int/oth/T02020000A8/en</sourceUrl>
18675         <!-- Source is in Polish. -->
18676         <sourceUrl>http://www.uke.gov.pl/uke/index.jsp?place=Lead24&amp;news_cat_id=277&amp;news_id=3791&amp;layout=9&amp;page=text</sourceUrl>
18677         <sourceUrl>http://www.sgwp.wp.mil.pl/pl/1_1225.html</sourceUrl>
18678       </references>
18679       <availableFormats>
18680         <numberFormat pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
18681           <leadingDigits>
18682             [14]|
18683             2[0-57-9]|
18684             3[2-4]|
18685             5[24-689]|
18686             6[1-3578]|
18687             7[14-7]|
18688             8[1-79]|
18689             9[145]
18690           </leadingDigits>
18691           <format>$1 $2 $3 $4</format>
18692         </numberFormat>
18693         <numberFormat pattern="(\d{2})(\d{1})(\d{4})">
18694           <leadingDigits>[12]2</leadingDigits>
18695           <format>$1 $2 $3</format>
18696         </numberFormat>
18697         <!-- We are formatting 70 numbers as per mobile numbers, based on information from some
18698              Poles that this is more usual. -->
18699         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
18700           <leadingDigits>
18701             261|
18702             39|
18703             5[0137]|
18704             6[0469]|
18705             7[02389]|
18706             8[08]
18707           </leadingDigits>
18708           <format>$1 $2 $3</format>
18709         </numberFormat>
18710         <!-- Additional patterns for shorter pager numbers. -->
18711         <numberFormat pattern="(\d{3})(\d{2})(\d{2,3})">
18712           <leadingDigits>64</leadingDigits>
18713           <format>$1 $2 $3</format>
18714         </numberFormat>
18715         <numberFormat pattern="(\d{3})(\d{3})">
18716           <leadingDigits>64</leadingDigits>
18717           <format>$1 $2</format>
18718         </numberFormat>
18719       </availableFormats>
18720       <generalDesc>
18721         <nationalNumberPattern>
18722           [12]\d{6,8}|
18723           [3-57-9]\d{8}|
18724           6\d{5,8}
18725         </nationalNumberPattern>
18726         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
18727       </generalDesc>
18728       <fixedLine>
18729         <!-- The plan says all geographical numbers are 9 digits; but in at least Warsaw (22) and
18730              Krakow (12) we have found internationally diallable numbers that are 7 digits instead,
18731              so we support those too. Numbers which start with 261 are allocated for the militrary,
18732              see: http://www.sgwp.wp.mil.pl/pl/1_1225.html. -->
18733         <nationalNumberPattern>
18734           (?:
18735             1[2-8]|
18736             2[2-59]|
18737             3[2-4]|
18738             4[1-468]|
18739             5[24-689]|
18740             6[1-3578]|
18741             7[14-7]|
18742             8[1-79]|
18743             9[145]
18744           )\d{7}|
18745           [12]2\d{5}|
18746           261\d{6}
18747         </nationalNumberPattern>
18748         <exampleNumber>123456789</exampleNumber>
18749       </fixedLine>
18750       <mobile>
18751         <nationalNumberPattern>
18752           (?:
18753             5[0137]|
18754             6[069]|
18755             7[2389]|
18756             88
18757           )\d{7}
18758         </nationalNumberPattern>
18759         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18760         <exampleNumber>512345678</exampleNumber>
18761       </mobile>
18762       <pager>
18763         <nationalNumberPattern>64\d{4,7}</nationalNumberPattern>
18764         <exampleNumber>641234567</exampleNumber>
18765       </pager>
18766       <tollFree>
18767         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
18768         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18769         <exampleNumber>800123456</exampleNumber>
18770       </tollFree>
18771       <premiumRate>
18772         <nationalNumberPattern>70\d{7}</nationalNumberPattern>
18773         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18774         <exampleNumber>701234567</exampleNumber>
18775       </premiumRate>
18776       <sharedCost>
18777         <nationalNumberPattern>801\d{6}</nationalNumberPattern>
18778         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18779         <exampleNumber>801234567</exampleNumber>
18780       </sharedCost>
18781       <voip>
18782         <nationalNumberPattern>39\d{7}</nationalNumberPattern>
18783         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18784         <exampleNumber>391234567</exampleNumber>
18785       </voip>
18786     </territory>
18787
18788     <!-- Saint Pierre and Miquelon (Collectivité territoriale de la République française) -->
18789     <territory id="PM" countryCode="508" internationalPrefix="00"
18790                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
18791       <references>
18792         <sourceUrl>http://www.itu.int/oth/T02020000B2/en</sourceUrl>
18793       </references>
18794       <availableFormats>
18795         <numberFormat pattern="([45]\d)(\d{2})(\d{2})">
18796           <format>$1 $2 $3</format>
18797         </numberFormat>
18798       </availableFormats>
18799       <generalDesc>
18800         <nationalNumberPattern>[45]\d{5}</nationalNumberPattern>
18801         <possibleNumberPattern>\d{6}</possibleNumberPattern>
18802       </generalDesc>
18803       <fixedLine>
18804         <nationalNumberPattern>41\d{4} </nationalNumberPattern>
18805         <exampleNumber>411234</exampleNumber>
18806       </fixedLine>
18807       <mobile>
18808         <nationalNumberPattern>55\d{4} </nationalNumberPattern>
18809         <exampleNumber>551234</exampleNumber>
18810       </mobile>
18811     </territory>
18812
18813     <!-- Pitcairn Island -->
18814     <!-- id="PN" -->
18815     <!-- This island is not supported since evidence seems to be that the 50 inhabitants use
18816          satellite phones. -->
18817
18818     <!-- Puerto Rico -->
18819     <territory id="PR" countryCode="1" leadingDigits="787|939" nationalPrefix="1"
18820                internationalPrefix="011">
18821       <references>
18822         <sourceUrl>http://www.itu.int/oth/T02020000AA/en</sourceUrl>
18823       </references>
18824       <generalDesc>
18825         <!-- NANPA country - uses US formatting rules -->
18826         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
18827         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
18828       </generalDesc>
18829       <fixedLine>
18830         <nationalNumberPattern>
18831           (?:
18832             787|
18833             939
18834           )[2-9]\d{6}
18835         </nationalNumberPattern>
18836         <exampleNumber>7872345678</exampleNumber>
18837       </fixedLine>
18838       <mobile>
18839         <nationalNumberPattern>
18840           (?:
18841             787|
18842             939
18843           )[2-9]\d{6}
18844         </nationalNumberPattern>
18845         <exampleNumber>7872345678</exampleNumber>
18846       </mobile>
18847       <tollFree>
18848         <nationalNumberPattern>
18849           8(?:
18850             00|
18851             44|
18852             55|
18853             66|
18854             77|
18855             88
18856           )[2-9]\d{6}
18857         </nationalNumberPattern>
18858         <possibleNumberPattern>\d{10}</possibleNumberPattern>
18859         <exampleNumber>8002345678</exampleNumber>
18860       </tollFree>
18861       <premiumRate>
18862         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
18863         <possibleNumberPattern>\d{10}</possibleNumberPattern>
18864         <exampleNumber>9002345678</exampleNumber>
18865       </premiumRate>
18866       <personalNumber>
18867         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
18868         <nationalNumberPattern>
18869           5(?:
18870             00|
18871             33|
18872             44|
18873             66|
18874             77
18875           )[2-9]\d{6}
18876         </nationalNumberPattern>
18877         <possibleNumberPattern>\d{10}</possibleNumberPattern>
18878         <exampleNumber>5002345678</exampleNumber>
18879       </personalNumber>
18880     </territory>
18881
18882     <!-- Palestinian Authority -->
18883     <!-- Palestinian phone numbers can be reached through the Israeli country code (972) in addition
18884          to the Palestinian country code (970) and so Palestinian landlines and mobile lines are a
18885          subset of the Israeli formats. -->
18886     <territory id="PS" countryCode="970" internationalPrefix="00"
18887                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
18888       <references>
18889         <sourceUrl>http://en.wikipedia.org/wiki/%2B970</sourceUrl>
18890         <sourceUrl>http://www.wtng.info/wtng-970-ps.html</sourceUrl>
18891         <sourceUrl>http://www.paltel.ps</sourceUrl>
18892       </references>
18893       <availableFormats>
18894         <numberFormat pattern="([2489])(2\d{2})(\d{4})">
18895           <leadingDigits>[2489]</leadingDigits>
18896           <format>$1 $2 $3</format>
18897         </numberFormat>
18898         <numberFormat pattern="(5[69]\d)(\d{3})(\d{3})">
18899           <leadingDigits>5</leadingDigits>
18900           <format>$1 $2 $3</format>
18901         </numberFormat>
18902         <numberFormat nationalPrefixFormattingRule="$FG"
18903           pattern="(1[78]00)(\d{3})(\d{3})">
18904           <leadingDigits>1[78]</leadingDigits>
18905           <format>$1 $2 $3</format>
18906         </numberFormat>
18907         <!-- 4 and 5 digit premium numbers will be formatted as one block by default. -->
18908       </availableFormats>
18909       <generalDesc>
18910         <nationalNumberPattern>
18911           [24589]\d{7,8}|
18912           1(?:
18913             [78]\d{8}|
18914             [49]\d{2,3}
18915           )
18916         </nationalNumberPattern>
18917         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
18918       </generalDesc>
18919       <fixedLine>
18920         <nationalNumberPattern>
18921           (?:
18922             22[234789]|
18923             42[45]|
18924             82[01458]|
18925             92[369]
18926           )\d{5}
18927         </nationalNumberPattern>
18928         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
18929         <exampleNumber>22234567</exampleNumber>
18930       </fixedLine>
18931       <mobile>
18932         <nationalNumberPattern>5[69]\d{7}</nationalNumberPattern>
18933         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18934         <exampleNumber>599123456</exampleNumber>
18935       </mobile>
18936       <tollFree>
18937         <nationalNumberPattern>1800\d{6}</nationalNumberPattern>
18938         <possibleNumberPattern>\d{10}</possibleNumberPattern>
18939         <exampleNumber>1800123456</exampleNumber>
18940       </tollFree>
18941       <premiumRate>
18942         <!-- According to Paltel, premium numbers are 14xx and 19xxx -->
18943         <nationalNumberPattern>
18944           1(?:
18945             4|
18946             9\d
18947            )\d{2}
18948         </nationalNumberPattern>
18949         <possibleNumberPattern>\d{4,5}</possibleNumberPattern>
18950         <exampleNumber>19123</exampleNumber>
18951       </premiumRate>
18952       <sharedCost>
18953         <nationalNumberPattern>1700\d{6}</nationalNumberPattern>
18954         <possibleNumberPattern>\d{10}</possibleNumberPattern>
18955         <exampleNumber>1700123456</exampleNumber>
18956       </sharedCost>
18957     </territory>
18958
18959     <!-- Portugal -->
18960     <territory id="PT" countryCode="351" internationalPrefix="00" mobileNumberPortableRegion="true">
18961       <references>
18962         <sourceUrl>http://www.anacom.pt/render.jsp?categoryId=279098</sourceUrl>
18963       </references>
18964       <availableFormats>
18965         <!-- Note: the wikipedia page suggests that mobile numbers may also be formatted with only
18966              two digits in the first group; however, this doesn't seem to be majority usage based on
18967              searches online. -->
18968         <numberFormat pattern="(2\d)(\d{3})(\d{4})">
18969           <leadingDigits>2[12]</leadingDigits>
18970           <format>$1 $2 $3</format>
18971         </numberFormat>
18972         <numberFormat pattern="([2-46-9]\d{2})(\d{3})(\d{3})">
18973           <leadingDigits>
18974             2[3-9]|
18975             [346-9]
18976           </leadingDigits>
18977           <format>$1 $2 $3</format>
18978         </numberFormat>
18979       </availableFormats>
18980       <generalDesc>
18981         <nationalNumberPattern>[2-46-9]\d{8}</nationalNumberPattern>
18982         <possibleNumberPattern>\d{9}</possibleNumberPattern>
18983       </generalDesc>
18984       <fixedLine>
18985         <nationalNumberPattern>
18986           2(?:
18987             [12]\d|
18988             [35][1-689]|
18989             4[1-59]|
18990             6[1-35689]|
18991             7[1-9]|
18992             8[1-69]|
18993             9[1256]
18994           )\d{6}
18995         </nationalNumberPattern>
18996         <exampleNumber>212345678</exampleNumber>
18997       </fixedLine>
18998       <mobile>
18999         <nationalNumberPattern>
19000           9(?:
19001             [136]\d{2}|
19002             2[0-79]\d|
19003             480
19004           )\d{5}
19005         </nationalNumberPattern>
19006         <exampleNumber>912345678</exampleNumber>
19007       </mobile>
19008       <tollFree>
19009         <nationalNumberPattern>80[02]\d{6}</nationalNumberPattern>
19010         <exampleNumber>800123456</exampleNumber>
19011       </tollFree>
19012       <premiumRate>
19013         <!-- Fixed maximum cost numbers: 761=0.60€, 761=1€, 762=2€. -->
19014         <nationalNumberPattern>
19015           76(?:
19016             0[1-57]|
19017             1[2-47]|
19018             2[237]
19019           )\d{5}
19020         </nationalNumberPattern>
19021         <exampleNumber>760123456</exampleNumber>
19022       </premiumRate>
19023       <sharedCost>
19024         <!-- 808 are priced as local calls, 809 are national calls. -->
19025         <nationalNumberPattern>
19026           80(?:
19027             8\d|
19028             9[1579]
19029           )\d{5}
19030         </nationalNumberPattern>
19031         <exampleNumber>808123456</exampleNumber>
19032       </sharedCost>
19033       <personalNumber>
19034         <nationalNumberPattern>884[128]\d{5}</nationalNumberPattern>
19035         <exampleNumber>884123456</exampleNumber>
19036       </personalNumber>
19037       <voip>
19038         <nationalNumberPattern>30\d{7}</nationalNumberPattern>
19039         <exampleNumber>301234567</exampleNumber>
19040       </voip>
19041       <uan>
19042         <nationalNumberPattern>
19043           70(?:
19044             7\d|
19045             8[17]
19046           )\d{5}
19047         </nationalNumberPattern>
19048         <exampleNumber>707123456</exampleNumber>
19049       </uan>
19050     </territory>
19051
19052     <!-- Palau -->
19053     <territory id="PW" countryCode="680" internationalPrefix="01[12]">
19054       <references>
19055         <sourceUrl>http://www.itu.int/oth/T02020000A2/en</sourceUrl>
19056       </references>
19057       <availableFormats>
19058         <numberFormat pattern="(\d{3})(\d{4})">
19059           <format>$1 $2</format>
19060         </numberFormat>
19061       </availableFormats>
19062       <generalDesc>
19063         <nationalNumberPattern>[2-8]\d{6}</nationalNumberPattern>
19064         <possibleNumberPattern>\d{7}</possibleNumberPattern>
19065       </generalDesc>
19066       <fixedLine>
19067         <nationalNumberPattern>
19068           2552255|
19069           (?:
19070             277|
19071             345|
19072             488|
19073             5(?:
19074               35|
19075               44|
19076               87
19077             )|
19078             6(?:
19079               22|
19080               54|
19081               79
19082             )|
19083             7(?:
19084               33|
19085               47
19086             )|
19087             8(?:
19088               24|
19089               55|
19090               76
19091             )
19092           )\d{4}
19093         </nationalNumberPattern>
19094         <exampleNumber>2771234</exampleNumber>
19095       </fixedLine>
19096       <mobile>
19097         <nationalNumberPattern>
19098           (?:
19099             6[234689]0|
19100             77[45789]
19101           )\d{4}
19102         </nationalNumberPattern>
19103         <exampleNumber>6201234</exampleNumber>
19104       </mobile>
19105     </territory>
19106
19107     <!-- Paraguay -->
19108     <territory id="PY" countryCode="595" internationalPrefix="00" nationalPrefix="0"
19109                mobileNumberPortableRegion="true">
19110       <references>
19111         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Paraguay</sourceUrl>
19112         <sourceUrl>http://www.itu.int/oth/T02020000A5/en</sourceUrl>
19113         <sourceUrl>http://www.copaco.com.py/portal/index.php/component/content/article/8-empresa/74-codigos-de-area.html</sourceUrl>
19114       </references>
19115       <availableFormats>
19116         <!-- CONATEL plan. -->
19117         <numberFormat pattern="(\d{2})(\d{5,7})" nationalPrefixFormattingRule="($FG)">
19118           <leadingDigits>
19119             (?:
19120               [26]1|
19121               3[289]|
19122               4[124678]|
19123               7[123]|
19124               8[1236]
19125             )
19126           </leadingDigits>
19127           <format>$1 $2</format>
19128         </numberFormat>
19129         <numberFormat pattern="(\d{3})(\d{3,6})" nationalPrefixFormattingRule="$NP$FG">
19130           <leadingDigits>[2-9]0</leadingDigits>
19131           <format>$1 $2</format>
19132         </numberFormat>
19133         <numberFormat pattern="(\d{3})(\d{6})" nationalPrefixFormattingRule="$NP$FG">
19134           <leadingDigits>9[1-9]</leadingDigits>
19135           <format>$1 $2</format>
19136         </numberFormat>
19137         <!-- Format seen in examples found online. -->
19138         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
19139           <leadingDigits>8700</leadingDigits>
19140           <format>$1 $2 $3</format>
19141         </numberFormat>
19142         <!-- "Fall-back" rule for the rest of the fixed-line numbers that have 3-digit area codes.
19143              -->
19144         <numberFormat pattern="(\d{3})(\d{4,6})" nationalPrefixFormattingRule="($FG)">
19145           <leadingDigits>[2-8][1-9]</leadingDigits>
19146           <format>$1 $2</format>
19147         </numberFormat>
19148       </availableFormats>
19149       <generalDesc>
19150         <nationalNumberPattern>
19151           5[0-5]\d{4,7}|
19152           [2-46-9]\d{5,8}
19153         </nationalNumberPattern>
19154         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
19155       </generalDesc>
19156       <fixedLine>
19157         <nationalNumberPattern>
19158           (?:
19159             [26]1|
19160             3[289]|
19161             4[124678]|
19162             7[123]|
19163             8[1236]
19164           )\d{5,7}|
19165           (?:
19166             2(?:
19167               2[4568]|
19168               7[15]|
19169               9[1-5]
19170             )|
19171             3(?:
19172               18|
19173               3[167]|
19174               4[2357]|
19175               51
19176             )|
19177             4(?:
19178               18|
19179               2[45]|
19180               3[12]|
19181               5[13]|
19182               64|
19183               71|
19184               9[1-47]
19185             )|
19186             5(?:
19187               [1-4]\d|
19188               5[0234]
19189             )|
19190             6(?:
19191               3[1-3]|
19192               44|
19193               7[1-4678]
19194             )|
19195             7(?:
19196               17|
19197               4[0-4]|
19198               6[1-578]|
19199               75|
19200               8[0-8]
19201             )|
19202             858
19203           )\d{5,6}
19204         </nationalNumberPattern>
19205         <exampleNumber>212345678</exampleNumber>
19206       </fixedLine>
19207       <mobile>
19208         <!-- 962 was added for Tigo. -->
19209         <nationalNumberPattern>
19210           9(?:
19211             6[12]|
19212             [78][1-6]|
19213             9[1-5]
19214           )\d{6}
19215         </nationalNumberPattern>
19216         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19217         <exampleNumber>961456789</exampleNumber>
19218       </mobile>
19219       <voip>
19220         <nationalNumberPattern>8700[0-4]\d{4}</nationalNumberPattern>
19221         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19222         <exampleNumber>870012345</exampleNumber>
19223       </voip>
19224       <uan>
19225         <nationalNumberPattern>[2-9]0\d{4,7}</nationalNumberPattern>
19226         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
19227         <exampleNumber>201234567</exampleNumber>
19228       </uan>
19229     </territory>
19230
19231     <!-- Qatar -->
19232     <territory id="QA" countryCode="974" internationalPrefix="00" mobileNumberPortableRegion="true">
19233       <references>
19234         <sourceUrl>http://www.itu.int/oth/T02020000AB/en</sourceUrl>
19235         <sourceUrl>http://wtng.info/wtng-qq.html</sourceUrl>
19236       </references>
19237       <availableFormats>
19238         <numberFormat pattern="([28]\d{2})(\d{4})">
19239           <leadingDigits>[28]</leadingDigits>
19240           <format>$1 $2</format>
19241         </numberFormat>
19242         <numberFormat pattern="([3-7]\d{3})(\d{4})">
19243           <leadingDigits>[3-7]</leadingDigits>
19244           <format>$1 $2</format>
19245         </numberFormat>
19246       </availableFormats>
19247       <generalDesc>
19248         <nationalNumberPattern>[2-8]\d{6,7}</nationalNumberPattern>
19249         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
19250       </generalDesc>
19251       <fixedLine>
19252         <!-- The prefix 40 has now been allocated, based on numbers seen online. -->
19253         <nationalNumberPattern>4[04]\d{6}</nationalNumberPattern>
19254         <exampleNumber>44123456</exampleNumber>
19255       </fixedLine>
19256       <mobile>
19257         <nationalNumberPattern>[3567]\d{7}</nationalNumberPattern>
19258         <exampleNumber>33123456</exampleNumber>
19259       </mobile>
19260       <pager>
19261         <nationalNumberPattern>
19262           2(?:
19263             [12]\d|
19264             61
19265           )\d{4}
19266         </nationalNumberPattern>
19267         <possibleNumberPattern>\d{7}</possibleNumberPattern>
19268         <exampleNumber>2123456</exampleNumber>
19269       </pager>
19270       <tollFree>
19271         <nationalNumberPattern>800\d{4}</nationalNumberPattern>
19272         <exampleNumber>8001234</exampleNumber>
19273       </tollFree>
19274       <!-- No premiumRate information can be found. -->
19275     </territory>
19276
19277     <!-- Réunion (French Departments and Territories in the Indian Ocean) -->
19278     <!-- Note this shares the same country code as La Mayotte and the formatting patterns here are
19279          used by both of them. -->
19280     <territory id="RE" countryCode="262" internationalPrefix="00"
19281                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
19282                leadingDigits="262|6[49]|8" mainCountryForCode="true" >
19283       <references>
19284         <sourceUrl>http://www.itu.int/oth/T020200004B/en</sourceUrl>
19285       </references>
19286       <availableFormats>
19287         <numberFormat pattern="([268]\d{2})(\d{2})(\d{2})(\d{2})">
19288           <format>$1 $2 $3 $4</format>
19289         </numberFormat>
19290       </availableFormats>
19291       <generalDesc>
19292         <nationalNumberPattern>[268]\d{8}</nationalNumberPattern>
19293         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19294       </generalDesc>
19295       <fixedLine>
19296         <!-- 0876 numbers are mentioned in the plan, but none in use can be found. -->
19297         <nationalNumberPattern>262\d{6}</nationalNumberPattern>
19298         <exampleNumber>262161234</exampleNumber>
19299       </fixedLine>
19300       <mobile>
19301         <nationalNumberPattern>
19302           6(?:
19303             9[23]|
19304             47
19305           )\d{6}
19306         </nationalNumberPattern>
19307         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19308         <exampleNumber>692123456</exampleNumber>
19309       </mobile>
19310       <!-- 08* Numbers in Réunion are the same as those valid in France. -->
19311       <tollFree>
19312         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
19313         <exampleNumber>801234567</exampleNumber>
19314       </tollFree>
19315       <premiumRate>
19316         <nationalNumberPattern>89[1-37-9]\d{6}</nationalNumberPattern>
19317         <exampleNumber>891123456</exampleNumber>
19318       </premiumRate>
19319       <sharedCost>
19320         <nationalNumberPattern>
19321           8(?:
19322             1[019]|
19323             2[0156]|
19324             84|
19325             90
19326           )\d{6}
19327         </nationalNumberPattern>
19328         <exampleNumber>810123456</exampleNumber>
19329       </sharedCost>
19330     </territory>
19331
19332     <!-- Romania -->
19333     <!-- Extension prefix found online, confirmed by a Romanian. -->
19334     <territory id="RO" countryCode="40" internationalPrefix="00"
19335                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
19336                preferredExtnPrefix=" int " mobileNumberPortableRegion="true">
19337       <references>
19338         <sourceUrl>http://www.itu.int/oth/T02020000AC/en</sourceUrl>
19339         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Romania</sourceUrl>
19340       </references>
19341       <availableFormats>
19342         <numberFormat pattern="([237]\d)(\d{3})(\d{4})">
19343           <leadingDigits>[23]1</leadingDigits>
19344           <format>$1 $2 $3</format>
19345         </numberFormat>
19346         <numberFormat pattern="(21)(\d{4})">
19347           <leadingDigits>21</leadingDigits>
19348           <format>$1 $2</format>
19349         </numberFormat>
19350         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
19351           <!-- We format mobile numbers like this, even though ITU and wikipedia hint at
19352                \d{2}\d{3}\d{4} grouping, since the yellow pages (http://en.paginiaurii.ro/) and the
19353                majority of numbers found online follow this convention. -->
19354           <leadingDigits>
19355             [23][3-7]|
19356             [7-9]
19357           </leadingDigits>
19358           <format>$1 $2 $3</format>
19359         </numberFormat>
19360         <numberFormat pattern="(2\d{2})(\d{3})">
19361           <leadingDigits>2[3-6]</leadingDigits>
19362           <format>$1 $2</format>
19363         </numberFormat>
19364       </availableFormats>
19365       <generalDesc>
19366         <nationalNumberPattern>
19367           2\d{5,8}|
19368           [37-9]\d{8}
19369         </nationalNumberPattern>
19370         <!-- Although the ITU plan says the number plan is open, this was changed in 2008 according
19371              to wikipedia and people must dial the full number. However, there are still short
19372              numbers that total 6 digits long, so the possible number pattern should take these into
19373              account. -->
19374         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
19375       </generalDesc>
19376       <fixedLine>
19377         <!-- We exclude three-digit short numbers for Bucharest (219\d{2}) and four-digit short
19378              numbers outside Bucharest (2[36]\d9\d{3}) even though ITU suggests these exist. We do
19379              this based on numbers found online and the wikipedia article which indicate that these
19380              are four digits long in Bucharest only, and three digits elsewhere. -->
19381         <nationalNumberPattern>
19382           2(?:
19383             1(?:
19384               \d{7}|
19385               9\d{3}
19386             )|
19387             [3-6](?:
19388               \d{7}|
19389               \d9\d{2}
19390             )
19391           )|
19392           3[13-6]\d{7}
19393           </nationalNumberPattern>
19394         <exampleNumber>211234567</exampleNumber>
19395       </fixedLine>
19396       <mobile>
19397         <!-- http://www.enigma-system.net/business/customized-phone-number.html confirms that the
19398              numbers are restricted to those starting with 07000. Mobile prefix 0799 added based on
19399              open-source report and confirmation by existence of such numbers online. -->
19400         <nationalNumberPattern>
19401           7(?:
19402             000|
19403             [1-8]\d{2}|
19404             99\d
19405           )\d{5}
19406         </nationalNumberPattern>
19407         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19408         <exampleNumber>712345678</exampleNumber>
19409       </mobile>
19410       <tollFree>
19411         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
19412         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19413         <exampleNumber>800123456</exampleNumber>
19414       </tollFree>
19415       <premiumRate>
19416         <nationalNumberPattern>90[036]\d{6}</nationalNumberPattern>
19417         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19418         <exampleNumber>900123456</exampleNumber>
19419       </premiumRate>
19420       <sharedCost>
19421         <nationalNumberPattern>801\d{6}</nationalNumberPattern>
19422         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19423         <exampleNumber>801123456</exampleNumber>
19424       </sharedCost>
19425       <personalNumber>
19426         <nationalNumberPattern>802\d{6}</nationalNumberPattern>
19427         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19428         <exampleNumber>802123456</exampleNumber>
19429       </personalNumber>
19430       <uan>
19431         <!-- http://www.ancom.org.ro/pnn_1300 refers to numbers beginning with 37, 38 or 39 as
19432              location-independent national numbers. Only numbers beginning with 37 have been seen so
19433              these are the only ones supported for now. -->
19434         <nationalNumberPattern>37\d{7}</nationalNumberPattern>
19435         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19436         <exampleNumber>372123456</exampleNumber>
19437       </uan>
19438     </territory>
19439
19440     <!-- Serbia -->
19441     <territory id="RS" countryCode="381" internationalPrefix="00"
19442                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
19443                mobileNumberPortableRegion="true">
19444       <references>
19445         <sourceUrl>http://www.itu.int/oth/T02020000B9/en</sourceUrl>
19446         <sourceUrl>http://registar.ratel.rs/en/reg202</sourceUrl>
19447       </references>
19448       <availableFormats>
19449         <numberFormat pattern="([23]\d{2})(\d{4,9})">
19450           <leadingDigits>
19451             (?:
19452               2[389]|
19453               39
19454             )0
19455           </leadingDigits>
19456           <format>$1 $2</format>
19457         </numberFormat>
19458         <numberFormat pattern="([1-3]\d)(\d{5,10})">
19459           <leadingDigits>
19460             1|
19461             2(?:
19462               [0-24-7]|
19463               [389][1-9]
19464             )|
19465             3(?:
19466               [0-8]|
19467               9[1-9]
19468             )
19469           </leadingDigits>
19470           <format>$1 $2</format>
19471         </numberFormat>
19472         <numberFormat pattern="(6\d)(\d{6,8})">
19473           <leadingDigits>6</leadingDigits>
19474           <format>$1 $2</format>
19475         </numberFormat>
19476         <numberFormat pattern="([89]\d{2})(\d{3,9})">
19477           <leadingDigits>[89]</leadingDigits>
19478           <format>$1 $2</format>
19479         </numberFormat>
19480         <numberFormat pattern="(7[26])(\d{4,9})">
19481           <leadingDigits>7[26]</leadingDigits>
19482           <format>$1 $2</format>
19483         </numberFormat>
19484         <numberFormat pattern="(7[08]\d)(\d{4,9})">
19485           <leadingDigits>7[08]</leadingDigits>
19486           <format>$1 $2</format>
19487         </numberFormat>
19488       </availableFormats>
19489       <generalDesc>
19490         <!-- The complicated pattern here is to distinguish between Pristina (area code 38, followed
19491              by 2-9) and the country calling code (381). -->
19492         <nationalNumberPattern>
19493           [126-9]\d{4,11}|
19494           3(?:
19495             [0-79]\d{3,10}|
19496             8[2-9]\d{2,9}
19497           )
19498         </nationalNumberPattern>
19499         <possibleNumberPattern>\d{5,12}</possibleNumberPattern>
19500       </generalDesc>
19501       <fixedLine>
19502         <!-- Most subscriber numbers may not start with 0 or 1. Exceptionally, the prefix 11 1[5-7]
19503              has been issused, so we allow 11 1X here. -->
19504         <nationalNumberPattern>
19505           (?:
19506             1(?:
19507               [02-9][2-9]|
19508               1[1-9]
19509             )\d|
19510             2(?:
19511               [0-24-7][2-9]\d|
19512               [389](?:
19513                 0[2-9]|
19514                 [2-9]\d
19515               )
19516             )|
19517             3(?:
19518               [0-8][2-9]\d|
19519               9(?:
19520                 [2-9]\d|
19521                 0[2-9]
19522               )
19523             )
19524           )\d{3,8}
19525         </nationalNumberPattern>
19526         <possibleNumberPattern>\d{5,12}</possibleNumberPattern>
19527         <exampleNumber>10234567</exampleNumber>
19528       </fixedLine>
19529       <mobile>
19530         <nationalNumberPattern>
19531           6(?:
19532             [0-689]|
19533             7\d
19534           )\d{6,7}
19535         </nationalNumberPattern>
19536         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
19537         <exampleNumber>601234567</exampleNumber>
19538       </mobile>
19539       <tollFree>
19540         <nationalNumberPattern>800\d{3,9}</nationalNumberPattern>
19541         <possibleNumberPattern>\d{6,12}</possibleNumberPattern>
19542         <exampleNumber>80012345</exampleNumber>
19543       </tollFree>
19544       <premiumRate>
19545         <nationalNumberPattern>
19546           (?:
19547             90[0169]|
19548             78\d
19549           )\d{3,7}
19550         </nationalNumberPattern>
19551         <possibleNumberPattern>\d{6,12}</possibleNumberPattern>
19552         <exampleNumber>90012345</exampleNumber>
19553       </premiumRate>
19554       <uan>
19555         <nationalNumberPattern>7[06]\d{4,10}</nationalNumberPattern>
19556         <possibleNumberPattern>\d{6,12}</possibleNumberPattern>
19557         <exampleNumber>700123456</exampleNumber>
19558       </uan>
19559     </territory>
19560
19561     <!-- Russian Federation -->
19562     <territory id="RU" countryCode="7" mainCountryForCode="true" preferredInternationalPrefix="8~10"
19563                internationalPrefix="810" nationalPrefix="8"
19564                nationalPrefixFormattingRule="$NP ($FG)"
19565                nationalPrefixOptionalWhenFormatting="true" >
19566       <references>
19567         <sourceUrl>http://www.itu.int/oth/T02020000AD/en</sourceUrl>
19568         <sourceUrl>http://en.wikipedia.org/wiki/%2B7</sourceUrl>
19569       </references>
19570       <availableFormats>
19571         <!-- Formatting from wikipedia, confirmed on Goverment websites such as
19572              http://www.minjust.ru/ru/structure/contact/. Contains formatting instructions for
19573              Kazakhstan as well. -->
19574         <numberFormat pattern="(\d{3})(\d{2})(\d{2})" nationalPrefixFormattingRule="$FG">
19575           <!-- Local numbers only - these do not start with the national prefix. -->
19576           <leadingDigits>[1-79]</leadingDigits>
19577           <format>$1-$2-$3</format>
19578           <intlFormat>NA</intlFormat>
19579         </numberFormat>
19580         <numberFormat pattern="([3489]\d{2})(\d{3})(\d{2})(\d{2})">
19581           <leadingDigits>[34689]</leadingDigits>
19582           <format>$1 $2-$3-$4</format>
19583         </numberFormat>
19584         <numberFormat pattern="(7\d{2})(\d{3})(\d{4})">
19585           <leadingDigits>7</leadingDigits>
19586           <format>$1 $2 $3</format>
19587         </numberFormat>
19588       </availableFormats>
19589       <generalDesc>
19590         <nationalNumberPattern>[3489]\d{9}</nationalNumberPattern>
19591         <possibleNumberPattern>\d{10}</possibleNumberPattern>
19592       </generalDesc>
19593       <fixedLine>
19594         <!-- The Ivanovo area code 493 was omitted on the official document, but this is still used
19595              in the yellow pages, and on their own website and is listed on wikipedia. This applies
19596              also to 395 (Irkutsk). Also including the 840 prefix for Abkhazia. -->
19597         <nationalNumberPattern>
19598           (?:
19599             3(?:
19600               0[12]|
19601               4[1-35-79]|
19602               5[1-3]|
19603               8[1-58]|
19604               9[0145]
19605             )|
19606             4(?:
19607               01|
19608               1[1356]|
19609               2[13467]|
19610               7[1-5]|
19611               8[1-7]|
19612               9[1-689]
19613             )|
19614             8(?:
19615               1[1-8]|
19616               2[01]|
19617               3[13-6]|
19618               4[0-8]|
19619               5[15]|
19620               6[1-35-7]|
19621               7[1-37-9]
19622             )
19623           )\d{7}
19624         </nationalNumberPattern>
19625         <exampleNumber>3011234567</exampleNumber>
19626       </fixedLine>
19627       <mobile>
19628         <nationalNumberPattern>9\d{9}</nationalNumberPattern>
19629         <exampleNumber>9123456789</exampleNumber>
19630       </mobile>
19631       <tollFree>
19632         <!-- The metadata states that 804 numbers are UAN numbers, but
19633              teleum.ru/numbers/toll_free_804 states that they are now being offered as toll-free
19634              numbers. -->
19635         <nationalNumberPattern>80[04]\d{7}</nationalNumberPattern>
19636         <exampleNumber>8001234567</exampleNumber>
19637       </tollFree>
19638       <premiumRate>
19639         <!-- Covers tele-voting numbers as well. -->
19640         <nationalNumberPattern>80[39]\d{7}</nationalNumberPattern>
19641         <exampleNumber>8091234567</exampleNumber>
19642       </premiumRate>
19643     </territory>
19644
19645     <!-- Rwanda -->
19646     <!-- According to ITU, there is no national prefix. However, this is still used. As of June 3rd
19647          2011, this was confirmed by a Rwandan local. It is also shown in this format on pages such
19648          as http://www.tigo.co.rw "Choose Your Number" service. -->
19649     <territory id="RW" countryCode="250" internationalPrefix="00"
19650                nationalPrefix="0" leadingZeroPossible="true">
19651       <references>
19652         <sourceUrl>http://www.rura.gov.rw/docs/RWANDA_NATIONAL_NUMBERING_PLAN.pdf</sourceUrl>
19653         <sourceUrl>http://en.wikipedia.org/wiki/+250</sourceUrl>
19654       </references>
19655       <availableFormats>
19656         <numberFormat nationalPrefixFormattingRule="$FG"
19657           pattern="(2\d{2})(\d{3})(\d{3})">
19658           <leadingDigits>2</leadingDigits>
19659           <format>$1 $2 $3</format>
19660         </numberFormat>
19661         <numberFormat pattern="([7-9]\d{2})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
19662           <leadingDigits>[7-9]</leadingDigits>
19663           <format>$1 $2 $3</format>
19664         </numberFormat>
19665         <numberFormat pattern="(0\d)(\d{2})(\d{2})(\d{2})">
19666           <leadingDigits>0</leadingDigits>
19667           <format>$1 $2 $3 $4</format>
19668         </numberFormat>
19669       </availableFormats>
19670       <generalDesc>
19671         <nationalNumberPattern>[027-9]\d{7,8}</nationalNumberPattern>
19672         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
19673       </generalDesc>
19674       <fixedLine>
19675         <!-- We support satellite numbers here, since they are in the plan, although no recent
19676              online examples can be found. We also support fixed-line ranges that have been reserved
19677              and paid for, even where no online numbers can be found. -->
19678         <nationalNumberPattern>
19679           2[258]\d{7}|
19680           06\d{6}
19681         </nationalNumberPattern>
19682         <exampleNumber>250123456</exampleNumber>
19683       </fixedLine>
19684       <mobile>
19685         <!-- Adding 73X for Airtel - this is on the wikipedia page, but not yet in the Rwanda
19686              telecommunications numbering plan. Removing 75 - that was Rwandatel but they had their
19687              license revoked. -->
19688         <nationalNumberPattern>7[238]\d{7}</nationalNumberPattern>
19689         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19690         <exampleNumber>720123456</exampleNumber>
19691       </mobile>
19692       <tollFree>
19693         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
19694         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19695         <exampleNumber>800123456</exampleNumber>
19696       </tollFree>
19697       <premiumRate>
19698         <nationalNumberPattern>900\d{6}</nationalNumberPattern>
19699         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19700         <exampleNumber>900123456</exampleNumber>
19701       </premiumRate>
19702     </territory>
19703
19704     <!-- Saudi Arabia -->
19705     <territory id="SA" countryCode="966" internationalPrefix="00"
19706                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
19707                mobileNumberPortableRegion="true">
19708       <references>
19709         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Saudi_Arabia</sourceUrl>
19710         <sourceUrl>http://www.itu.int/oth/T02020000B7/en</sourceUrl>
19711       </references>
19712       <availableFormats>
19713         <numberFormat pattern="([1-467])(\d{3})(\d{4})">
19714           <leadingDigits>[1-467]</leadingDigits>
19715           <format>$1 $2 $3</format>
19716         </numberFormat>
19717         <numberFormat pattern="(1\d)(\d{3})(\d{4})">
19718           <leadingDigits>1[1-467]</leadingDigits>
19719           <format>$1 $2 $3</format>
19720         </numberFormat>
19721         <numberFormat pattern="(5\d)(\d{3})(\d{4})">
19722           <leadingDigits>5</leadingDigits>
19723           <format>$1 $2 $3</format>
19724         </numberFormat>
19725         <!-- It seems that the trunk prefix is not used for these numbers, based on wikipedia and on
19726              the fact that no numbers of this form found online have a trunk prefix added. -->
19727         <numberFormat pattern="(92\d{2})(\d{5})" nationalPrefixFormattingRule="$FG">
19728           <leadingDigits>92</leadingDigits>
19729           <format>$1 $2</format>
19730         </numberFormat>
19731         <numberFormat pattern="(800)(\d{3})(\d{4})" nationalPrefixFormattingRule="$FG">
19732           <leadingDigits>80</leadingDigits>
19733           <format>$1 $2 $3</format>
19734         </numberFormat>
19735         <numberFormat pattern="(811)(\d{3})(\d{3,4})">
19736           <leadingDigits>81</leadingDigits>
19737           <format>$1 $2 $3</format>
19738         </numberFormat>
19739       </availableFormats>
19740       <generalDesc>
19741         <!-- The more detailed pattern here is to allow the country-code to be stripped off for
19742              fixed-line numbers. -->
19743         <nationalNumberPattern>
19744           1\d{7,8}|
19745           (?:
19746             [2-467]|
19747             92
19748           )\d{7}|
19749           5\d{8}|
19750           8\d{9}
19751         </nationalNumberPattern>
19752         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
19753       </generalDesc>
19754       <fixedLine>
19755         <!-- Saudi Arabia is in the process of adding a leading 1 to their fixed-line numbers. This
19756              happened in May for area code 1 (parallel running ended July 13th, 2013) and then in
19757              August for the other fixed-line numbers (parallel running ends October 18th, 2013). -->
19758         <nationalNumberPattern>
19759           11\d{7}|
19760           1?(?:
19761             2[24-8]|
19762             3[35-8]|
19763             4[3-68]|
19764             6[2-5]|
19765             7[235-7]
19766           )\d{6}
19767         </nationalNumberPattern>
19768         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
19769         <exampleNumber>112345678</exampleNumber>
19770       </fixedLine>
19771       <mobile>
19772         <!-- Including "Nomadic" numbers from the Telecom Company "Go". The ITU document now says
19773              they are 11 digits long; however all online numbers are 10, and it used to say 10, so
19774              until we find evidence that this is an error, leaving them at 10 for now. -->
19775         <nationalNumberPattern>
19776           (?:
19777             5(?:
19778               [013-689]\d|
19779               7[0-26-8]
19780             )|
19781             811\d
19782           )\d{6}
19783         </nationalNumberPattern>
19784         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
19785         <exampleNumber>512345678</exampleNumber>
19786       </mobile>
19787       <tollFree>
19788         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
19789         <possibleNumberPattern>\d{10}</possibleNumberPattern>
19790         <exampleNumber>8001234567</exampleNumber>
19791       </tollFree>
19792       <sharedCost>
19793         <!-- Including shared revenue with shared cost here. -->
19794         <nationalNumberPattern>92[05]\d{6}</nationalNumberPattern>
19795         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19796         <exampleNumber>920012345</exampleNumber>
19797       </sharedCost>
19798     </territory>
19799
19800     <!-- Solomon Islands -->
19801     <territory id="SB" countryCode="677" internationalPrefix="0[01]">
19802       <references>
19803         <sourceUrl>http://www.itu.int/oth/T02020000BF/en</sourceUrl>
19804       </references>
19805       <!-- A single group is used to format 5-digit numbers. This formatting pattern follows
19806            the guidelines in the ITU document. -->
19807       <availableFormats>
19808         <numberFormat pattern="(\d{2})(\d{5})">
19809           <leadingDigits>[7-9]</leadingDigits>
19810           <format>$1 $2</format>
19811         </numberFormat>
19812       </availableFormats>
19813       <generalDesc>
19814         <nationalNumberPattern>[1-9]\d{4,6}</nationalNumberPattern>
19815         <possibleNumberPattern>\d{5,7}</possibleNumberPattern>
19816       </generalDesc>
19817       <fixedLine>
19818         <!-- Although not mentioned in the 2011 update, it seems likely that the range 67300-67699
19819              is still used for Sasamunga, Shortland, Poitete and Ringgi as per the 2010 plan. -->
19820         <nationalNumberPattern>
19821           (?:
19822             1[4-79]|
19823             [23]\d|
19824             4[01]|
19825             5[03]|
19826             6[0-37]
19827           )\d{3}
19828         </nationalNumberPattern>
19829         <possibleNumberPattern>\d{5}</possibleNumberPattern>
19830         <exampleNumber>40123</exampleNumber>
19831       </fixedLine>
19832       <mobile>
19833         <!-- The 795 prefix is not in the ITU plan (5.XII.2014), but was added because such a number
19834              was dialed successfully. -->
19835         <nationalNumberPattern>
19836           48\d{3}|
19837           7(?:
19838             30|
19839             [46-8]\d|
19840             5[025-9]|
19841             9[0-5]
19842           )\d{4}|
19843           8[4-8]\d{5}|
19844           9(?:
19845             1[2-9]|
19846             2[013-9]|
19847             3[0-2]|
19848             [46]\d|
19849             5[0-46-9]|
19850             7[0-689]|
19851             8[0-79]|
19852             9[0-8]
19853           )\d{4}
19854         </nationalNumberPattern>
19855         <exampleNumber>7421234</exampleNumber>
19856       </mobile>
19857       <tollFree>
19858         <nationalNumberPattern>1[38]\d{3}</nationalNumberPattern>
19859         <possibleNumberPattern>\d{5}</possibleNumberPattern>
19860         <exampleNumber>18123</exampleNumber>
19861       </tollFree>
19862       <voip>
19863         <nationalNumberPattern>5[12]\d{3}</nationalNumberPattern>
19864         <possibleNumberPattern>\d{5}</possibleNumberPattern>
19865         <exampleNumber>51123</exampleNumber>
19866       </voip>
19867     </territory>
19868
19869     <!-- Seychelles -->
19870     <territory id="SC" countryCode="248" internationalPrefix="0[0-2]"
19871                preferredInternationalPrefix="00">
19872       <references>
19873         <sourceUrl>http://www.itu.int/oth/T02020000BA/en</sourceUrl>
19874         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Seychelles</sourceUrl>
19875       </references>
19876       <availableFormats>
19877         <numberFormat pattern="(\d{3})(\d{3})">
19878           <leadingDigits>[89]</leadingDigits>
19879           <format>$1 $2</format>
19880         </numberFormat>
19881         <numberFormat pattern="(\d)(\d{3})(\d{3})">
19882           <leadingDigits>[246]</leadingDigits>
19883           <format>$1 $2 $3</format>
19884         </numberFormat>
19885       </availableFormats>
19886       <generalDesc>
19887         <nationalNumberPattern>[24689]\d{5,6}</nationalNumberPattern>
19888         <possibleNumberPattern>\d{6,7}</possibleNumberPattern>
19889       </generalDesc>
19890       <fixedLine>
19891         <!-- We are putting Fixed Services numbers here for now, as we cannot find any evidence that
19892              they are more expensive to call than other Fixed Line services. ISDN and DID services
19893              are here too, since they seem to be also fixed-line phone numbers. -->
19894         <nationalNumberPattern>4[2-46]\d{5}</nationalNumberPattern>
19895         <possibleNumberPattern>\d{7}</possibleNumberPattern>
19896         <exampleNumber>4217123</exampleNumber>
19897       </fixedLine>
19898       <mobile>
19899         <!-- Includes Fixed Cellular. -->
19900         <nationalNumberPattern>2[5-8]\d{5}</nationalNumberPattern>
19901         <possibleNumberPattern>\d{7}</possibleNumberPattern>
19902         <exampleNumber>2510123</exampleNumber>
19903       </mobile>
19904       <tollFree>
19905         <nationalNumberPattern>8000\d{2}</nationalNumberPattern>
19906         <possibleNumberPattern>\d{6}</possibleNumberPattern>
19907         <exampleNumber>800000</exampleNumber>
19908       </tollFree>
19909       <premiumRate>
19910         <!-- Using this to represent Value Added Service in the plan. -->
19911         <nationalNumberPattern>98\d{4}</nationalNumberPattern>
19912         <possibleNumberPattern>\d{6}</possibleNumberPattern>
19913         <exampleNumber>981234</exampleNumber>
19914       </premiumRate>
19915       <voip>
19916         <nationalNumberPattern>64\d{5}</nationalNumberPattern>
19917         <possibleNumberPattern>\d{7}</possibleNumberPattern>
19918         <exampleNumber>6412345</exampleNumber>
19919       </voip>
19920     </territory>
19921
19922     <!-- Sudan -->
19923     <territory id="SD" countryCode="249" internationalPrefix="00"
19924                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
19925       <references>
19926         <sourceUrl>http://www.itu.int/oth/T02020000C4/en</sourceUrl>
19927       </references>
19928       <availableFormats>
19929         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
19930           <format>$1 $2 $3</format>
19931         </numberFormat>
19932       </availableFormats>
19933       <generalDesc>
19934         <nationalNumberPattern>[19]\d{8}</nationalNumberPattern>
19935         <possibleNumberPattern>\d{9}</possibleNumberPattern>
19936       </generalDesc>
19937       <fixedLine>
19938         <!-- Retaining previous prefix as 18 since it seems still to be used. Adding 11 from numbers
19939              found online. -->
19940         <nationalNumberPattern>
19941           1(?:
19942             [125]\d|
19943             8[3567]
19944           )\d{6}
19945         </nationalNumberPattern>
19946         <exampleNumber>121231234</exampleNumber>
19947       </fixedLine>
19948       <mobile>
19949         <!-- Adding 90X as online numbers have been found with this prefix. -->
19950         <nationalNumberPattern>9[012569]\d{7}</nationalNumberPattern>
19951         <exampleNumber>911231234</exampleNumber>
19952       </mobile>
19953     </territory>
19954
19955     <!-- Sweden -->
19956     <territory id="SE" countryCode="46" internationalPrefix="00"
19957                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
19958                mobileNumberPortableRegion="true">
19959       <references>
19960         <sourceUrl>http://www.pts.se/upload/Ovrigt/Tele/Nummerfragor/swedish-numbering-plan-for-telephony-acc-itu-140407.pdf</sourceUrl>        
19961       </references>
19962       <availableFormats>
19963       <!-- Formatting patterns are from the numbering plan and from the Swedish yellow pages
19964            http://gulasidorna.eniro.se -->
19965         <numberFormat pattern="(8)(\d{2,3})(\d{2,3})(\d{2})">
19966           <leadingDigits>8</leadingDigits>
19967           <format>$1-$2 $3 $4</format>
19968           <intlFormat>$1 $2 $3 $4</intlFormat>
19969         </numberFormat>
19970         <numberFormat pattern="([1-69]\d)(\d{2,3})(\d{2})(\d{2})">
19971           <leadingDigits>
19972             1[013689]|
19973             2[0136]|
19974             3[1356]|
19975             4[0246]|
19976             54|
19977             6[03]|
19978             90
19979           </leadingDigits>
19980           <format>$1-$2 $3 $4</format>
19981           <intlFormat>$1 $2 $3 $4</intlFormat>
19982         </numberFormat>
19983         <numberFormat pattern="([1-69]\d)(\d{3})(\d{2})">
19984           <leadingDigits>
19985             1[13689]|
19986             2[136]|
19987             3[1356]|
19988             4[0246]|
19989             54|
19990             6[03]|
19991             90
19992           </leadingDigits>
19993           <format>$1-$2 $3</format>
19994           <intlFormat>$1 $2 $3</intlFormat>
19995         </numberFormat>
19996         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
19997           <leadingDigits>
19998             1[2457]|
19999             2[2457-9]|
20000             3[0247-9]|
20001             4[1357-9]|
20002             5[0-35-9]|
20003             6[124-9]|
20004             9(?:
20005               [125-8]|
20006               3[0-5]|
20007               4[0-3]
20008             )
20009           </leadingDigits>
20010           <format>$1-$2 $3 $4</format>
20011           <intlFormat>$1 $2 $3 $4</intlFormat>
20012         </numberFormat>
20013         <numberFormat pattern="(\d{3})(\d{2,3})(\d{2})">
20014           <leadingDigits>
20015             1[2457]|
20016             2[2457-9]|
20017             3[0247-9]|
20018             4[1357-9]|
20019             5[0-35-9]|
20020             6[124-9]|
20021             9(?:
20022               [125-8]|
20023               3[0-5]|
20024               4[0-3]
20025             )
20026           </leadingDigits>
20027           <format>$1-$2 $3</format>
20028           <intlFormat>$1 $2 $3</intlFormat>
20029         </numberFormat>
20030         <numberFormat pattern="(7\d)(\d{3})(\d{2})(\d{2})">
20031           <leadingDigits>7</leadingDigits>
20032           <format>$1-$2 $3 $4</format>
20033           <intlFormat>$1 $2 $3 $4</intlFormat>
20034         </numberFormat>
20035         <numberFormat pattern="(77)(\d{2})(\d{2})">
20036           <leadingDigits>7</leadingDigits>
20037           <format>$1-$2$3</format>
20038           <intlFormat>$1 $2 $3</intlFormat>
20039         </numberFormat>
20040         <numberFormat pattern="(20)(\d{2,3})(\d{2})">
20041           <leadingDigits>20</leadingDigits>
20042           <format>$1-$2 $3</format>
20043           <intlFormat>$1 $2 $3</intlFormat>
20044         </numberFormat>
20045         <numberFormat pattern="(9[034]\d)(\d{2})(\d{2})(\d{3})">
20046           <leadingDigits>9[034]</leadingDigits>
20047           <format>$1-$2 $3 $4</format>
20048           <intlFormat>$1 $2 $3 $4</intlFormat>
20049         </numberFormat>
20050         <numberFormat pattern="(9[034]\d)(\d{4})">
20051           <leadingDigits>9[034]</leadingDigits>
20052           <format>$1-$2</format>
20053           <intlFormat>$1 $2</intlFormat>
20054         </numberFormat>
20055       </availableFormats>
20056       <generalDesc>
20057         <nationalNumberPattern>[1-9]\d{5,9}</nationalNumberPattern>
20058         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
20059       </generalDesc>
20060       <fixedLine>
20061         <nationalNumberPattern>
20062           1(?:
20063             0[1-8]\d{6}|
20064             [136]\d{5,7}|
20065             (?:
20066               2[0-35]|
20067               4[0-4]|
20068               5[0-25-9]|
20069               7[13-6]|
20070               [89]\d
20071             )\d{5,6}
20072           )|
20073           2(?:
20074             [136]\d{5,7}|
20075             (?:
20076               2[0-7]|
20077               4[0136-8]|
20078               5[0138]|
20079               7[018]|
20080               8[01]|
20081               9[0-57]
20082             )\d{5,6}
20083           )|
20084           3(?:
20085             [356]\d{5,7}|
20086             (?:
20087               0[0-4]|
20088               1\d|
20089               2[0-25]|
20090               4[056]|
20091               7[0-2]|
20092               8[0-3]|
20093               9[023]
20094             )\d{5,6}
20095           )|
20096           4(?:
20097             0[1-9]\d{4,6}|
20098             [246]\d{5,7}|
20099             (?:
20100               1[013-8]|
20101               3[0135]|
20102               5[14-79]|
20103               7[0-246-9]|
20104               8[0156]|
20105               9[0-689]
20106             )\d{5,6}
20107           )|
20108           5(?:
20109             0[0-6]|
20110             [15][0-5]|
20111             2[0-68]|
20112             3[0-4]|
20113             4\d|
20114             6[03-5]|
20115             7[013]|
20116             8[0-79]|
20117             9[01]
20118           )\d{5,6}|
20119           6(?:
20120             0[1-9]\d{4,6}|
20121             3\d{5,7}|
20122             (?:
20123               1[1-3]|
20124               2[0-4]|
20125               4[02-57]|
20126               5[0-37]|
20127               6[0-3]|
20128               7[0-2]|
20129               8[0247]|
20130               9[0-356]
20131             )\d{5,6}
20132           )|
20133           8[1-9]\d{5,7}|
20134           9(?:
20135             0[1-9]\d{4,6}|
20136             (?:
20137               1[0-68]|
20138               2\d|
20139               3[02-5]|
20140               4[0-3]|
20141               5[0-4]|
20142               [68][01]|
20143               7[0135-8]
20144             )\d{5,6}
20145           )
20146         </nationalNumberPattern>
20147         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
20148         <exampleNumber>8123456</exampleNumber>
20149       </fixedLine>
20150       <mobile>
20151         <nationalNumberPattern>7[02369]\d{7}</nationalNumberPattern>
20152         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20153         <exampleNumber>701234567</exampleNumber>
20154       </mobile>
20155       <pager>
20156         <nationalNumberPattern>74[02-9]\d{6}</nationalNumberPattern>
20157         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20158         <exampleNumber>740123456</exampleNumber>
20159       </pager>
20160       <tollFree>
20161         <nationalNumberPattern>
20162           20(?:
20163             0(?:
20164               0\d{2}|
20165               [1-9](?:
20166                 0\d{1,4}|
20167                 [1-9]\d{4}
20168               )
20169             )|
20170             1(?:
20171               0\d{4}|
20172               [1-9]\d{4,5}
20173             )|
20174             [2-9]\d{5}
20175           )
20176         </nationalNumberPattern>
20177         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
20178         <exampleNumber>20123456</exampleNumber>
20179       </tollFree>
20180       <premiumRate>
20181         <nationalNumberPattern>
20182           9(?:
20183             00|
20184             39|
20185             44
20186           )(?:
20187             1(?:
20188               [0-26]\d{5}|
20189               [3-57-9]\d{2}
20190             )|
20191             2(?:
20192               [0-2]\d{5}|
20193               [3-9]\d{2}
20194             )|
20195             3(?:
20196               [0139]\d{5}|
20197               [24-8]\d{2}
20198             )|
20199             4(?:
20200               [045]\d{5}|
20201               [1-36-9]\d{2}
20202             )|
20203             5(?:
20204               5\d{5}|
20205               [0-46-9]\d{2}
20206             )|
20207             6(?:
20208               [679]\d{5}|
20209               [0-58]\d{2}
20210             )|
20211             7(?:
20212               [078]\d{5}|
20213               [1-69]\d{2}
20214             )|
20215             8(?:
20216               [578]\d{5}|
20217               [0-469]\d{2}
20218             )
20219           )
20220         </nationalNumberPattern>
20221         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
20222         <exampleNumber>9001234567</exampleNumber>
20223       </premiumRate>
20224       <sharedCost>
20225         <nationalNumberPattern>
20226           77(?:
20227             0(?:
20228               0\d{2}|
20229               [1-9](?:
20230                 0\d|
20231                 [1-9]\d{4}
20232               )
20233             )|
20234             [1-6][1-9]\d{5}
20235           )
20236         </nationalNumberPattern>
20237         <possibleNumberPattern>\d{6}(?:\d{3})?</possibleNumberPattern>
20238         <exampleNumber>771234567</exampleNumber>
20239       </sharedCost>
20240       <personalNumber>
20241         <nationalNumberPattern>75[1-8]\d{6}</nationalNumberPattern>
20242         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20243         <exampleNumber>751234567</exampleNumber>
20244       </personalNumber>
20245     </territory>
20246
20247     <!-- Singapore -->
20248     <territory id="SG" countryCode="65" internationalPrefix="0[0-3]\d"
20249                mobileNumberPortableRegion="true">
20250       <references>
20251         <sourceUrl>http://www.ida.gov.sg/Policies-and-Regulations/Industry-and-Licensees/Numbering/National-Numbering-Plan-and-Allocation-Process.aspx</sourceUrl>
20252       </references>
20253       <availableFormats>
20254         <numberFormat pattern="([3689]\d{3})(\d{4})">
20255           <leadingDigits>
20256             [369]|
20257             8[1-9]
20258           </leadingDigits>
20259           <format>$1 $2</format>
20260         </numberFormat>
20261         <numberFormat pattern="(1[89]00)(\d{3})(\d{4})">
20262           <leadingDigits>1[89]</leadingDigits>
20263           <format>$1 $2 $3</format>
20264         </numberFormat>
20265         <numberFormat pattern="(7000)(\d{4})(\d{3})">
20266           <leadingDigits>70</leadingDigits>
20267           <format>$1 $2 $3</format>
20268         </numberFormat>
20269         <numberFormat pattern="(800)(\d{3})(\d{4})">
20270           <leadingDigits>80</leadingDigits>
20271           <format>$1 $2 $3</format>
20272         </numberFormat>
20273       </availableFormats>
20274       <generalDesc>
20275         <!-- We have a stricter national number pattern for numbers beginning with 6 to enable us to
20276              easily strip off leading "65" country codes. -->
20277         <nationalNumberPattern>
20278           [36]\d{7}|
20279           [17-9]\d{7,10}
20280         </nationalNumberPattern>
20281         <possibleNumberPattern>\d{8,11}</possibleNumberPattern>
20282       </generalDesc>
20283       <fixedLine>
20284         <nationalNumberPattern>6[1-9]\d{6}</nationalNumberPattern>
20285         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20286         <exampleNumber>61234567</exampleNumber>
20287       </fixedLine>
20288       <mobile>
20289         <nationalNumberPattern>
20290           (?:
20291             8[1-8]|
20292             9[0-8]
20293           )\d{6}
20294         </nationalNumberPattern>
20295         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20296         <exampleNumber>81234567</exampleNumber>
20297       </mobile>
20298       <tollFree>
20299         <nationalNumberPattern>1?800\d{7}</nationalNumberPattern>
20300         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
20301         <exampleNumber>18001234567</exampleNumber>
20302       </tollFree>
20303       <premiumRate>
20304         <nationalNumberPattern>1900\d{7}</nationalNumberPattern>
20305         <possibleNumberPattern>\d{11}</possibleNumberPattern>
20306         <exampleNumber>19001234567</exampleNumber>
20307       </premiumRate>
20308       <voip>
20309         <nationalNumberPattern>3[12]\d{6}</nationalNumberPattern>
20310         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20311         <exampleNumber>31234567</exampleNumber>
20312       </voip>
20313       <uan>
20314         <!-- Although not detailed in the plan beyond mentioning their existence, it seems 7000
20315              numbers are used for companies. Most of the online examples are in fact alpha-numbers.
20316              -->
20317         <nationalNumberPattern>7000\d{7}</nationalNumberPattern>
20318         <possibleNumberPattern>\d{11}</possibleNumberPattern>
20319         <exampleNumber>70001234567</exampleNumber>
20320       </uan>
20321     </territory>
20322
20323     <!-- Saint Helena -->
20324     <territory id="SH" countryCode="290" internationalPrefix="00" mainCountryForCode="true">
20325       <references>
20326         <sourceUrl>http://www.itu.int/oth/T02020000AF/en</sourceUrl>
20327       </references>
20328       <!-- Numbers are formatted as a block. -->
20329       <generalDesc>
20330         <nationalNumberPattern>[2-79]\d{3,4}</nationalNumberPattern>
20331         <possibleNumberPattern>\d{4,5}</possibleNumberPattern>
20332       </generalDesc>
20333       <fixedLine>
20334         <!-- St Helena is changing to 5 digits on October 1. 2013 -> we support both patterns here.
20335              The new pattern is first, followed by the old (hence the repetition of the leading 2).
20336              -->
20337         <nationalNumberPattern>
20338           2(?:
20339             [0-57-9]\d|
20340             6[4-9]
20341           )\d{2}|
20342           (?:
20343             [2-46]\d|
20344             7[01]
20345           )\d{2}
20346         </nationalNumberPattern>
20347         <!-- Using St Helena Tourism as the example number. -->
20348         <exampleNumber>2158</exampleNumber>
20349       </fixedLine>
20350       <mobile>
20351         <nationalNumberPattern>NA</nationalNumberPattern>
20352         <possibleNumberPattern>NA</possibleNumberPattern>
20353       </mobile>
20354       <premiumRate>
20355         <nationalNumberPattern>
20356           (?:
20357             [59]\d|
20358             7[2-9]
20359           )\d{2}
20360         </nationalNumberPattern>
20361         <exampleNumber>5012</exampleNumber>
20362       </premiumRate>
20363     </territory>
20364
20365     <!-- Slovenia -->
20366     <territory id="SI" countryCode="386" internationalPrefix="00"
20367                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
20368                mobileNumberPortableRegion="true">
20369       <references>
20370         <sourceUrl>http://www.itu.int/oth/T02020000BE/en</sourceUrl>
20371       </references>
20372       <availableFormats>
20373         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
20374           pattern="(\d)(\d{3})(\d{2})(\d{2})">
20375           <leadingDigits>
20376             [12]|
20377             3[4-8]|
20378             4[24-8]|
20379             5[2-8]|
20380             7[3-8]
20381           </leadingDigits>
20382           <format>$1 $2 $3 $4</format>
20383           </numberFormat>
20384         <numberFormat pattern="([3-7]\d)(\d{3})(\d{3})">
20385           <leadingDigits>
20386             [37][01]|
20387             4[0139]|
20388             51|
20389             6
20390           </leadingDigits>
20391           <format>$1 $2 $3</format>
20392           </numberFormat>
20393         <numberFormat pattern="([89][09])(\d{3,6})">
20394           <leadingDigits>[89][09]</leadingDigits>
20395           <format>$1 $2</format>
20396         </numberFormat>
20397         <numberFormat pattern="([58]\d{2})(\d{5})">
20398           <leadingDigits>
20399             59|
20400             8[1-3]
20401           </leadingDigits>
20402           <format>$1 $2</format>
20403         </numberFormat>
20404       </availableFormats>
20405       <generalDesc>
20406         <nationalNumberPattern>
20407           [1-7]\d{6,7}|
20408           [89]\d{4,7}
20409         </nationalNumberPattern>
20410         <possibleNumberPattern>\d{5,8}</possibleNumberPattern>
20411       </generalDesc>
20412       <fixedLine>
20413         <nationalNumberPattern>
20414           (?:
20415             1\d|
20416             [25][2-8]|
20417             3[4-8]|
20418             4[24-8]|
20419             7[3-8]
20420           )\d{6}
20421         </nationalNumberPattern>
20422         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
20423         <exampleNumber>11234567</exampleNumber>
20424       </fixedLine>
20425       <mobile>
20426         <!-- We include 043 and 049 here - it is VoIP in the plan, but is actually used to provide
20427              mobile coverage to Kosovo. Also added 068, which is used by the mobile operator bob.si
20428          -->
20429         <nationalNumberPattern>
20430           (?:
20431             [37][01]|
20432             4[0139]|
20433             51|
20434             6[48]
20435           )\d{6}
20436         </nationalNumberPattern>
20437         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20438         <exampleNumber>31234567</exampleNumber>
20439       </mobile>
20440       <tollFree>
20441         <nationalNumberPattern>80\d{4,6}</nationalNumberPattern>
20442         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
20443         <exampleNumber>80123456</exampleNumber>
20444       </tollFree>
20445       <premiumRate>
20446         <!-- Includes televoting, mass calling -->
20447         <nationalNumberPattern>
20448           90\d{4,6}|
20449           89[1-3]\d{2,5}
20450         </nationalNumberPattern>
20451         <possibleNumberPattern>\d{5,8}</possibleNumberPattern>
20452         <exampleNumber>90123456</exampleNumber>
20453       </premiumRate>
20454       <voip>
20455         <nationalNumberPattern>
20456           (?:
20457             59|
20458             8[1-3]
20459           )\d{6}
20460         </nationalNumberPattern>
20461         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20462         <exampleNumber>59012345</exampleNumber>
20463       </voip>
20464     </territory>
20465
20466     <!-- Svalbard -->
20467     <!-- Metadata shared with Norway. -->
20468     <territory id="SJ" countryCode="47" internationalPrefix="00" leadingZeroPossible="true">
20469       <references>
20470         <sourceUrl>http://www.npt.no/pt_internet/numsys/E.164.pdf</sourceUrl>
20471       </references>
20472       <generalDesc>
20473         <nationalNumberPattern>
20474           0\d{4}|
20475           [4789]\d{7}
20476         </nationalNumberPattern>
20477         <possibleNumberPattern>\d{5}(?:\d{3})?</possibleNumberPattern>
20478       </generalDesc>
20479       <fixedLine>
20480         <nationalNumberPattern>79\d{6}</nationalNumberPattern>
20481         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20482         <exampleNumber>79123456</exampleNumber>
20483       </fixedLine>
20484       <!-- Copied from Norway metadata. -->
20485       <mobile>
20486         <nationalNumberPattern>
20487           (?:
20488             4[015-8]|
20489             5[89]|
20490             9\d
20491           )\d{6}
20492         </nationalNumberPattern>
20493         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20494         <exampleNumber>41234567</exampleNumber>
20495       </mobile>
20496       <tollFree>
20497         <nationalNumberPattern>80[01]\d{5}</nationalNumberPattern>
20498         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20499         <exampleNumber>80012345</exampleNumber>
20500       </tollFree>
20501       <premiumRate>
20502         <nationalNumberPattern>82[09]\d{5}</nationalNumberPattern>
20503         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20504         <exampleNumber>82012345</exampleNumber>
20505       </premiumRate>
20506       <sharedCost>
20507         <nationalNumberPattern>
20508           810(?:
20509             0[0-6]|
20510             [2-8]\d
20511           )\d{3}
20512         </nationalNumberPattern>
20513         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20514         <exampleNumber>81021234</exampleNumber>
20515       </sharedCost>
20516       <personalNumber>
20517         <nationalNumberPattern>880\d{5}</nationalNumberPattern>
20518         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20519         <exampleNumber>88012345</exampleNumber>
20520       </personalNumber>
20521       <voip>
20522         <nationalNumberPattern>85[0-5]\d{5}</nationalNumberPattern>
20523         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20524         <exampleNumber>85012345</exampleNumber>
20525       </voip>
20526       <uan>
20527         <!-- Includes some 810 local-rate numbers, and long-distance rate numbers. -->
20528         <nationalNumberPattern>
20529           0\d{4}|
20530           81(?:
20531             0(?:
20532               0[7-9]|
20533               1\d
20534             )|
20535             5\d{2}
20536           )\d{3}
20537         </nationalNumberPattern>
20538         <exampleNumber>01234</exampleNumber>
20539       </uan>
20540       <voicemail>
20541         <nationalNumberPattern>81[23]\d{5}</nationalNumberPattern>
20542         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20543         <exampleNumber>81212345</exampleNumber>
20544       </voicemail>
20545     </territory>
20546
20547     <!-- Slovakia -->
20548     <territory id="SK" countryCode="421" internationalPrefix="00"
20549                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
20550                mobileNumberPortableRegion="true">
20551       <references>
20552         <sourceUrl>http://www.itu.int/oth/T02020000BD/en</sourceUrl>
20553       </references>
20554       <availableFormats>
20555         <numberFormat pattern="(2)(\d{3})(\d{3})(\d{2})">
20556           <leadingDigits>2</leadingDigits>
20557           <format>$1/$2 $3 $4</format>
20558         </numberFormat>
20559         <numberFormat pattern="([3-5]\d)(\d{3})(\d{2})(\d{2})">
20560           <leadingDigits>[3-5]</leadingDigits>
20561           <format>$1/$2 $3 $4</format>
20562         </numberFormat>
20563         <numberFormat pattern="([689]\d{2})(\d{3})(\d{3})">
20564           <leadingDigits>[689]</leadingDigits>
20565           <format>$1 $2 $3</format>
20566         </numberFormat>
20567       </availableFormats>
20568       <generalDesc>
20569         <nationalNumberPattern>[2-689]\d{8}</nationalNumberPattern>
20570         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20571       </generalDesc>
20572       <noInternationalDialling>
20573         <nationalNumberPattern>
20574           (?:
20575             8(?:
20576               00|
20577               [5-9]\d
20578             )|
20579             9(?:
20580               00|
20581               [78]\d
20582             )
20583           )\d{6}
20584         </nationalNumberPattern>
20585         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20586         <exampleNumber>800123456</exampleNumber>
20587       </noInternationalDialling>
20588       <fixedLine>
20589         <nationalNumberPattern>[2-5]\d{8}</nationalNumberPattern>
20590         <exampleNumber>212345678</exampleNumber>
20591       </fixedLine>
20592       <mobile>
20593         <!-- 948 isn't in the number pattern, but many examples using this have been found, so
20594              deeming it valid for now. -->
20595         <nationalNumberPattern>
20596           9(?:
20597             0[1-8]|
20598             1[0-24-9]|
20599             4[0489]
20600           )\d{6}
20601         </nationalNumberPattern>
20602         <exampleNumber>912123456</exampleNumber>
20603       </mobile>
20604       <tollFree>
20605         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
20606         <exampleNumber>800123456</exampleNumber>
20607       </tollFree>
20608       <premiumRate>
20609         <nationalNumberPattern>
20610           9(?:
20611             [78]\d{7}|
20612             00\d{6}
20613           )
20614         </nationalNumberPattern>
20615         <exampleNumber>900123456</exampleNumber>
20616       </premiumRate>
20617       <sharedCost>
20618         <nationalNumberPattern>8[5-9]\d{7}</nationalNumberPattern>
20619         <exampleNumber>850123456</exampleNumber>
20620       </sharedCost>
20621       <voip>
20622         <nationalNumberPattern>
20623           6(?:
20624             5[0-4]|
20625             9[0-6]
20626           )\d{6}
20627         </nationalNumberPattern>
20628         <exampleNumber>690123456</exampleNumber>
20629       </voip>
20630       <uan>
20631         <nationalNumberPattern>96\d{7}</nationalNumberPattern>
20632         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20633         <exampleNumber>961234567</exampleNumber>
20634       </uan>
20635     </territory>
20636
20637     <!-- Sierra Leone -->
20638     <territory id="SL" countryCode="232" internationalPrefix="00"
20639                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
20640       <references>
20641         <sourceUrl>http://www.itu.int/oth/T02020000BB/en</sourceUrl>
20642       </references>
20643       <availableFormats>
20644         <!-- Following formatting of online yellow pages http://www.leonedirect.com -->
20645         <numberFormat pattern="(\d{2})(\d{6})">
20646           <format>$1 $2</format>
20647         </numberFormat>
20648       </availableFormats>
20649       <generalDesc>
20650         <nationalNumberPattern>[2-57-9]\d{7}</nationalNumberPattern>
20651         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
20652       </generalDesc>
20653       <fixedLine>
20654         <nationalNumberPattern>[235]2[2-4][2-9]\d{4}</nationalNumberPattern>
20655         <exampleNumber>22221234</exampleNumber>
20656       </fixedLine>
20657       <mobile>
20658         <nationalNumberPattern>
20659           (?:
20660             2[15]|
20661             3[034]|
20662             4[04]|
20663             5[05]|
20664             7[6-9]|
20665             88|
20666             99
20667           )\d{6}
20668         </nationalNumberPattern>
20669         <exampleNumber>25123456</exampleNumber>
20670       </mobile>
20671     </territory>
20672
20673     <!-- San Marino -->
20674     <!-- San Marino fixed-line numbers have an area code of "0549". However, this seems to be
20675          optional when dialling from outside the country; the phone number can be reached both with
20676          and without this area code. The nationalPrefixForParsing and nationalPrefixTransformRule
20677          are used to ensure that if the 0549 is not present, it will be added. -->
20678     <territory id="SM" countryCode="378" internationalPrefix="00"
20679                nationalPrefixForParsing="(?:0549)?([89]\d{5})" nationalPrefixTransformRule="0549$1"
20680                leadingZeroPossible="true">
20681       <references>
20682         <sourceUrl>http://www.itu.int/oth/T02020000B5/en</sourceUrl>
20683         <!-- Information about Italy. -->
20684         <sourceUrl>http://en.wikipedia.org/wiki/%2B39</sourceUrl>
20685         <sourceUrl>http://en.wikipedia.org/wiki/%2B378</sourceUrl>
20686       </references>
20687       <availableFormats>
20688         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
20689           <leadingDigits>[5-7]</leadingDigits>
20690           <format>$1 $2 $3 $4</format>
20691         </numberFormat>
20692         <!-- We follow the guidelines of the yellow-pages when formatting in national format. -->
20693         <numberFormat pattern="(0549)(\d{6})">
20694           <leadingDigits>0</leadingDigits>
20695           <format>$1 $2</format>
20696           <!-- We follow the guidelines of the Telecommunications Document published on ITU when
20697                formatting in international format. -->
20698           <intlFormat>($1) $2</intlFormat>
20699         </numberFormat>
20700         <!-- A rule in case the number has been stored without the leading 0549 necessary for
20701              fixed-lines. -->
20702         <numberFormat pattern="(\d{6})">
20703           <leadingDigits>[89]</leadingDigits>
20704           <format>0549 $1</format>
20705           <intlFormat>(0549) $1</intlFormat>
20706         </numberFormat>
20707       </availableFormats>
20708       <generalDesc>
20709         <nationalNumberPattern>[05-7]\d{7,9}</nationalNumberPattern>
20710         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
20711       </generalDesc>
20712       <!-- Example numbers provided by the Telecommunications Services. -->
20713       <fixedLine>
20714         <nationalNumberPattern>
20715           0549(?:
20716             8[0157-9]|
20717             9\d
20718           )\d{4}
20719         </nationalNumberPattern>
20720         <exampleNumber>0549886377</exampleNumber>
20721       </fixedLine>
20722       <mobile>
20723         <nationalNumberPattern>6[16]\d{6}</nationalNumberPattern>
20724         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20725         <exampleNumber>66661212</exampleNumber>
20726       </mobile>
20727       <premiumRate>
20728         <!-- Includes Video Call numbers. -->
20729         <nationalNumberPattern>7[178]\d{6}</nationalNumberPattern>
20730         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20731         <exampleNumber>71123456</exampleNumber>
20732       </premiumRate>
20733       <voip>
20734         <nationalNumberPattern>5[158]\d{6}</nationalNumberPattern>
20735         <possibleNumberPattern>\d{8}</possibleNumberPattern>
20736         <exampleNumber>58001110</exampleNumber>
20737       </voip>
20738     </territory>
20739
20740     <!-- Senegal -->
20741     <territory id="SN" countryCode="221" internationalPrefix="00">
20742       <references>
20743         <sourceUrl>http://www.itu.int/oth/T02020000B8/en</sourceUrl>
20744         <sourceUrl>http://www.artpsenegal.net</sourceUrl>
20745       </references>
20746       <availableFormats>
20747         <!-- Using yellow pages and online telecom company formatting, rather than that implied in
20748              the national numbering plan. -->
20749         <numberFormat pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
20750           <leadingDigits>[379]</leadingDigits>
20751           <format>$1 $2 $3 $4</format>
20752         </numberFormat>
20753         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
20754           <leadingDigits>8</leadingDigits>
20755           <format>$1 $2 $3 $4</format>
20756         </numberFormat>
20757       </availableFormats>
20758       <generalDesc>
20759         <nationalNumberPattern>[3789]\d{8}</nationalNumberPattern>
20760         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20761       </generalDesc>
20762       <fixedLine>
20763         <nationalNumberPattern>
20764           3(?:
20765             0(?:
20766               1[0-2]|
20767               80
20768             )|
20769             282|
20770             3(?:
20771               8[1-9]|
20772               9[3-9]
20773             )|
20774             611|
20775             90[1-5]
20776           )\d{5}
20777         </nationalNumberPattern>
20778         <exampleNumber>301012345</exampleNumber>
20779       </fixedLine>
20780       <mobile>
20781         <nationalNumberPattern>
20782           7(?:
20783             [067]\d|
20784             21|
20785             8[0-26]|
20786             90
20787           )\d{6}
20788         </nationalNumberPattern>
20789         <exampleNumber>701234567</exampleNumber>
20790       </mobile>
20791       <tollFree>
20792         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
20793         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20794         <exampleNumber>800123456</exampleNumber>
20795       </tollFree>
20796       <premiumRate>
20797         <!-- Revenu Partagé in the plan. -->
20798         <nationalNumberPattern>88[4689]\d{6}</nationalNumberPattern>
20799         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20800         <exampleNumber>884123456</exampleNumber>
20801       </premiumRate>
20802       <sharedCost>
20803         <nationalNumberPattern>81[02468]\d{6}</nationalNumberPattern>
20804         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20805         <exampleNumber>810123456</exampleNumber>
20806       </sharedCost>
20807       <voip>
20808         <!-- Also covers satellite telephony ranges. -->
20809         <nationalNumberPattern>
20810           3392\d{5}|
20811           93330\d{4}
20812         </nationalNumberPattern>
20813         <exampleNumber>933301234</exampleNumber>
20814       </voip>
20815     </territory>
20816
20817     <!-- Somalia -->
20818     <!-- This document seems to cover only a small set of prefixes in Somalia. Somalia has limited
20819          information available, and the numerous telecom carriers were previously working under an
20820          unregulated environment. The extra prefixes were added from the contact phone numbers of
20821          the countries main telecom operators. We also have received information that a national
20822          prefix of "0" is required when dialling from different regions (e.g. Puntland, Somaliland)
20823          for some operators, so that is included here although we do not use it when formatting. -->
20824     <territory id="SO" countryCode="252" internationalPrefix="00" nationalPrefix="0">
20825       <references>
20826         <sourceUrl>http://www.itu.int/oth/T02020000C0/en</sourceUrl>
20827         <sourceUrl>http://en.wikipedia.org/wiki/+252</sourceUrl>
20828       </references>
20829       <availableFormats>
20830         <!-- These follow formats online, such as http://www.hortel.net/contact_us.html -->
20831         <numberFormat pattern="(\d)(\d{6})">
20832           <leadingDigits>
20833             2[0-79]|
20834             [13-5]
20835           </leadingDigits>
20836           <format>$1 $2</format>
20837         </numberFormat>
20838         <numberFormat pattern="(\d)(\d{7})">
20839           <leadingDigits>
20840             24|
20841             [67]
20842           </leadingDigits>
20843           <format>$1 $2</format>
20844         </numberFormat>
20845         <numberFormat pattern="(\d{2})(\d{5,7})">
20846           <leadingDigits>
20847             15|
20848             28|
20849             6[1378]
20850           </leadingDigits>
20851           <format>$1 $2</format>
20852         </numberFormat>
20853         <numberFormat pattern="(69\d)(\d{6})">
20854           <leadingDigits>69</leadingDigits>
20855           <format>$1 $2</format>
20856         </numberFormat>
20857         <numberFormat pattern="(90\d)(\d{3})(\d{3})">
20858           <leadingDigits>90</leadingDigits>
20859           <format>$1 $2 $3</format>
20860         </numberFormat>
20861       </availableFormats>
20862       <generalDesc>
20863         <nationalNumberPattern>[1-79]\d{6,8}</nationalNumberPattern>
20864         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
20865       </generalDesc>
20866       <fixedLine>
20867         <!-- Apparently Telesom and Nationlink (Somaliland) both use the prefix 2. We exclude 28
20868              here since that is apparently used for mobile. -->
20869         <nationalNumberPattern>
20870           (?:
20871             1\d|
20872             2[0-79]|
20873             3[0-46-8]|
20874             4[0-7]|
20875             59
20876           )\d{5}
20877         </nationalNumberPattern>
20878         <possibleNumberPattern>\d{7}</possibleNumberPattern>
20879         <exampleNumber>4012345</exampleNumber>
20880       </fixedLine>
20881       <mobile>
20882         <!-- 24 is used by the carrier Telesom. 28 is used by Nationlink. 6[89] are apparently used
20883              by Nationlink Somalia, 67 by Nationlink Puntland, and 61 by Hormuud. 7X is used by
20884              Somtel. 6 followed by only 7 digits is used by Telecom. Note that in June 2014 many
20885              ranges were suspended by the government. 90\d{6} was listed as one of the ranges to be
20886              suspended, but open-source contributors confirm that 907\d{6} is still in use, even if
20887              the shorter 90 ranges are no longer. -->
20888         <nationalNumberPattern>
20889           (?:
20890             15\d|
20891             2(?:
20892               4\d|
20893               8
20894             )|
20895             6[137-9]?\d{2}|
20896             7[1-9]\d|
20897             907\d
20898           )\d{5}
20899         </nationalNumberPattern>
20900         <exampleNumber>71123456</exampleNumber>
20901       </mobile>
20902     </territory>
20903
20904     <!-- Suriname -->
20905     <territory id="SR" countryCode="597" internationalPrefix="00">
20906       <references>
20907         <sourceUrl>http://www.itu.int/oth/T02020000C5/en</sourceUrl>
20908       </references>
20909       <availableFormats>
20910         <!-- Following conventions used in the Suriname Yellow Pages. -->
20911         <numberFormat pattern="(\d{3})(\d{3})">
20912           <leadingDigits>
20913             [2-4]|
20914             5[2-58]
20915           </leadingDigits>
20916           <format>$1-$2</format>
20917         </numberFormat>
20918         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
20919           <leadingDigits>56</leadingDigits>
20920           <format>$1-$2-$3</format>
20921         </numberFormat>
20922         <numberFormat pattern="(\d{3})(\d{4})">
20923           <leadingDigits>
20924             59|
20925             [6-8]
20926           </leadingDigits>
20927           <format>$1-$2</format>
20928         </numberFormat>
20929       </availableFormats>
20930       <generalDesc>
20931         <nationalNumberPattern>[2-8]\d{5,6}</nationalNumberPattern>
20932         <possibleNumberPattern>\d{6,7}</possibleNumberPattern>
20933       </generalDesc>
20934       <fixedLine>
20935         <!-- Includes non-geographic WLL-CDMA Fixed Lines. -->
20936         <nationalNumberPattern>
20937           (?:
20938             2[1-3]|
20939             3[0-7]|
20940             4\d|
20941             5[2-58]|
20942             68\d
20943           )\d{4}
20944         </nationalNumberPattern>
20945         <exampleNumber>211234</exampleNumber>
20946       </fixedLine>
20947       <mobile>
20948         <nationalNumberPattern>
20949           (?:
20950             7[124-7]|
20951             8[1-9]
20952           )\d{5}
20953         </nationalNumberPattern>
20954         <possibleNumberPattern>\d{7}</possibleNumberPattern>
20955         <exampleNumber>7412345</exampleNumber>
20956       </mobile>
20957       <voip>
20958         <nationalNumberPattern>
20959           5(?:
20960             6\d{4}|
20961             90[0-4]\d{3}
20962           )
20963         </nationalNumberPattern>
20964         <possibleNumberPattern>\d{6,7}</possibleNumberPattern>
20965         <exampleNumber>561234</exampleNumber>
20966       </voip>
20967     </territory>
20968
20969     <!-- South Sudan -->
20970     <territory id="SS" countryCode="211" internationalPrefix="00" nationalPrefix="0">
20971       <references>
20972         <sourceUrl>http://www.itu.int/oth/T02020000F9/en</sourceUrl>
20973         <sourceUrl>http://en.wikipedia.org/wiki/+211</sourceUrl>
20974       </references>
20975       <availableFormats>
20976         <numberFormat pattern="(\d{3})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
20977           <format>$1 $2 $3</format>
20978         </numberFormat>
20979       </availableFormats>
20980       <generalDesc>
20981         <nationalNumberPattern>[19]\d{8}</nationalNumberPattern>
20982         <possibleNumberPattern>\d{9}</possibleNumberPattern>
20983       </generalDesc>
20984       <fixedLine>
20985         <nationalNumberPattern>18\d{7}</nationalNumberPattern>
20986         <exampleNumber>181234567</exampleNumber>
20987       </fixedLine>
20988       <mobile>
20989         <nationalNumberPattern>
20990           (?:
20991             12|
20992             9[1257]
20993           )\d{7}
20994         </nationalNumberPattern>
20995         <exampleNumber>977123456</exampleNumber>
20996       </mobile>
20997     </territory>
20998
20999     <!-- Sao Tome and Principe -->
21000     <territory id="ST" countryCode="239" internationalPrefix="00">
21001       <references>
21002         <sourceUrl>http://www.itu.int/oth/T02020000B6/en</sourceUrl>
21003       </references>
21004       <availableFormats>
21005         <numberFormat pattern="(\d{3})(\d{4})">
21006           <format>$1 $2</format>
21007         </numberFormat>
21008       </availableFormats>
21009       <generalDesc>
21010         <nationalNumberPattern>[29]\d{6}</nationalNumberPattern>
21011         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21012       </generalDesc>
21013       <fixedLine>
21014         <nationalNumberPattern>22\d{5}</nationalNumberPattern>
21015         <exampleNumber>2221234</exampleNumber>
21016       </fixedLine>
21017       <mobile>
21018         <nationalNumberPattern>9[89]\d{5}</nationalNumberPattern>
21019         <exampleNumber>9812345</exampleNumber>
21020       </mobile>
21021     </territory>
21022
21023     <!-- El Salvador -->
21024     <territory id="SV" countryCode="503" internationalPrefix="00">
21025       <references>
21026         <sourceUrl>http://www.itu.int/oth/T020200003F/en</sourceUrl>
21027         <sourceUrl>http://www.siget.gob.sv/BusquedaPublica.aspx?pagina=3&amp;tipo=27&amp;titulo=t8&amp;sector=2&amp;ordenar=&amp;dir=DESC</sourceUrl>
21028       </references>
21029       <availableFormats>
21030         <numberFormat pattern="(\d{4})(\d{4})">
21031           <leadingDigits>[267]</leadingDigits>
21032           <format>$1 $2</format>
21033         </numberFormat>
21034         <numberFormat pattern="(\d{3})(\d{4})">
21035           <leadingDigits>[89]</leadingDigits>
21036           <format>$1 $2</format>
21037         </numberFormat>
21038         <numberFormat pattern="(\d{3})(\d{4})(\d{4})">
21039           <leadingDigits>[89]</leadingDigits>
21040           <format>$1 $2 $3</format>
21041         </numberFormat>
21042       </availableFormats>
21043       <generalDesc>
21044         <nationalNumberPattern>
21045           [267]\d{7}|
21046           [89]\d{6}(?:\d{4})?
21047         </nationalNumberPattern>
21048         <possibleNumberPattern>
21049           \d{7,8}|
21050           \d{11}
21051         </possibleNumberPattern>
21052       </generalDesc>
21053       <fixedLine>
21054         <!-- Numbers starting with 20, 27, 28 and 29 are reserved but not yet used. -->
21055         <nationalNumberPattern>2[1-6]\d{6}</nationalNumberPattern>
21056         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21057         <exampleNumber>21234567</exampleNumber>
21058       </fixedLine>
21059       <mobile>
21060         <nationalNumberPattern>[67]\d{7}</nationalNumberPattern>
21061         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21062         <exampleNumber>70123456</exampleNumber>
21063       </mobile>
21064       <tollFree>
21065         <!-- Toll free numbers are either 800 NNNN or 800 NNNN NNNN. -->
21066         <nationalNumberPattern>800\d{4}(?:\d{4})?</nationalNumberPattern>
21067         <possibleNumberPattern>\d{7}(?:\d{4})?</possibleNumberPattern>
21068         <exampleNumber>8001234</exampleNumber>
21069       </tollFree>
21070       <premiumRate>
21071         <!-- Premium rate numbers are either 900 NNNN or 900 NNNN NNNN. -->
21072         <nationalNumberPattern>900\d{4}(?:\d{4})?</nationalNumberPattern>
21073         <possibleNumberPattern>\d{7}(?:\d{4})?</possibleNumberPattern>
21074         <exampleNumber>9001234</exampleNumber>
21075       </premiumRate>
21076     </territory>
21077
21078     <!-- Sint Maarten -->
21079     <territory id="SX" countryCode="1" leadingDigits="721" nationalPrefix="1"
21080                internationalPrefix="011">
21081       <references>
21082         <sourceUrl>http://www.nanpa.com/pdf/PL_429.pdf</sourceUrl>
21083         <sourceUrl>http://www.itu.int/oth/T02020000F7/en</sourceUrl>
21084       </references>
21085       <generalDesc>
21086         <!-- NANPA country - uses US formatting rules -->
21087         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
21088         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
21089       </generalDesc>
21090       <fixedLine>
21091         <nationalNumberPattern>
21092           7215(?:
21093             4[2-8]|
21094             8[239]|
21095             9[056]
21096           )\d{4}
21097         </nationalNumberPattern>
21098         <exampleNumber>7215425678</exampleNumber>
21099       </fixedLine>
21100       <mobile>
21101         <!-- We assume we can send SMSs to the Fixed GSM numbers mentioned in the plan and hence
21102              include these as mobile numbers. -->
21103         <nationalNumberPattern>
21104           7215(?:
21105             1[02]|
21106             2\d|
21107             5[034679]|
21108             8[014-8]
21109           )\d{4}
21110         </nationalNumberPattern>
21111         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21112         <exampleNumber>7215205678</exampleNumber>
21113       </mobile>
21114       <tollFree>
21115         <nationalNumberPattern>
21116           8(?:
21117             00|
21118             44|
21119             55|
21120             66|
21121             77|
21122             88
21123           )[2-9]\d{6}
21124         </nationalNumberPattern>
21125         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21126         <exampleNumber>8002123456</exampleNumber>
21127       </tollFree>
21128       <premiumRate>
21129         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
21130         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21131         <exampleNumber>9002123456</exampleNumber>
21132       </premiumRate>
21133       <personalNumber>
21134         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
21135         <nationalNumberPattern>
21136           5(?:
21137             00|
21138             33|
21139             44|
21140             66|
21141             77
21142           )[2-9]\d{6}
21143         </nationalNumberPattern>
21144         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21145         <exampleNumber>5002345678</exampleNumber>
21146       </personalNumber>
21147     </territory>
21148
21149     <!-- Syrian Arab Republic -->
21150     <territory id="SY" countryCode="963" internationalPrefix="00"
21151                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
21152                nationalPrefixOptionalWhenFormatting="true">
21153       <references>
21154         <sourceUrl>http://www.itu.int/oth/T02020000C9/en</sourceUrl>
21155         <sourceUrl>http://en.wikipedia.org/wiki/%2B963</sourceUrl>
21156       </references>
21157       <availableFormats>
21158         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})">
21159           <leadingDigits>[1-5]</leadingDigits>
21160           <format>$1 $2 $3</format>
21161         </numberFormat>
21162         <numberFormat pattern="(9\d{2})(\d{3})(\d{3})">
21163           <leadingDigits>9</leadingDigits>
21164           <format>$1 $2 $3</format>
21165         </numberFormat>
21166       </availableFormats>
21167       <generalDesc>
21168         <nationalNumberPattern>[1-59]\d{7,8}</nationalNumberPattern>
21169         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
21170       </generalDesc>
21171       <fixedLine>
21172       <!-- Numbers with the 21 prefix are made optionally 1-digit longer based on numbers found on
21173            the Internet. -->
21174         <nationalNumberPattern>
21175           (?:
21176             1(?:
21177               1\d?|
21178               4\d|
21179               [2356]
21180             )|
21181             2(?:
21182               1\d?|
21183               [235]
21184             )|
21185             3(?:
21186               [13]\d|
21187               4
21188             )|
21189             4[13]|
21190             5[1-3]
21191           )\d{6}
21192         </nationalNumberPattern>
21193         <exampleNumber>112345678</exampleNumber>
21194       </fixedLine>
21195       <mobile>
21196         <!-- Numbers have been found on the Internet for the prefixes 922, 93[046-8],
21197              95[138], and 96[05]. -->
21198         <nationalNumberPattern>
21199           9(?:
21200             22|
21201             [35][0-8]|
21202             4\d|
21203             6[024-9]|
21204             88|
21205             9[0-489]
21206           )\d{6}
21207         </nationalNumberPattern>
21208         <possibleNumberPattern>\d{9}</possibleNumberPattern>
21209         <exampleNumber>944567890</exampleNumber>
21210       </mobile>
21211       <!-- No tollFree or premiumRate information can be found. -->
21212     </territory>
21213
21214     <!-- Swaziland -->
21215     <territory id="SZ" countryCode="268" internationalPrefix="00" leadingZeroPossible="true">
21216       <references>
21217         <sourceUrl>http://www.itu.int/oth/T02020000C6/en</sourceUrl>
21218       </references>
21219       <availableFormats>
21220         <numberFormat pattern="(\d{4})(\d{4})">
21221           <leadingDigits>[027]</leadingDigits>
21222           <format>$1 $2</format>
21223         </numberFormat>
21224       </availableFormats>
21225       <generalDesc>
21226         <nationalNumberPattern>[027]\d{7}</nationalNumberPattern>
21227         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21228       </generalDesc>
21229       <noInternationalDialling>
21230         <nationalNumberPattern>0800\d{4}</nationalNumberPattern>
21231         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21232         <exampleNumber>08001234</exampleNumber>
21233       </noInternationalDialling>
21234       <fixedLine>
21235         <nationalNumberPattern>
21236           2(?:
21237             2(?:
21238               0[07]|
21239               [13]7|
21240               2[57]
21241             )|
21242             3(?:
21243               0[34]|
21244               [1278]3|
21245               3[23]|
21246               [46][34]
21247             )|
21248             (?:
21249               40[4-69]|
21250               67
21251             )|
21252             5(?:
21253               0[5-7]|
21254               1[6-9]|
21255               [23][78]|
21256               48|
21257               5[01]
21258             )
21259           )\d{4}
21260         </nationalNumberPattern>
21261         <exampleNumber>22171234</exampleNumber>
21262       </fixedLine>
21263       <mobile>
21264         <nationalNumberPattern>7[6-8]\d{6}</nationalNumberPattern>
21265         <exampleNumber>76123456</exampleNumber>
21266       </mobile>
21267       <tollFree>
21268         <nationalNumberPattern>0800\d{4}</nationalNumberPattern>
21269         <exampleNumber>08001234</exampleNumber>
21270       </tollFree>
21271     </territory>
21272
21273     <!-- Tristan da Cunha -->
21274     <territory id="TA" countryCode="290" internationalPrefix="00">
21275       <references>
21276         <sourceUrl>http://www.itu.int/oth/T02020000AF/en</sourceUrl>
21277       </references>
21278       <!-- Numbers are formatted as a block. Shares a country code with Saint Helena. -->
21279       <generalDesc>
21280         <nationalNumberPattern>8\d{3}</nationalNumberPattern>
21281         <possibleNumberPattern>\d{4}</possibleNumberPattern>
21282       </generalDesc>
21283       <fixedLine>
21284         <nationalNumberPattern>8\d{3}</nationalNumberPattern>
21285         <exampleNumber>8999</exampleNumber>
21286       </fixedLine>
21287       <mobile>
21288         <nationalNumberPattern>NA</nationalNumberPattern>
21289         <possibleNumberPattern>NA</possibleNumberPattern>
21290       </mobile>
21291     </territory>
21292
21293     <!-- Turks and Caicos Islands -->
21294     <territory id="TC" countryCode="1" leadingDigits="649" nationalPrefix="1"
21295                internationalPrefix="011">
21296       <references>
21297         <sourceUrl>http://www.itu.int/oth/T02020000D8/en</sourceUrl>
21298       </references>
21299       <generalDesc>
21300         <!-- NANPA country - uses US formatting rules -->
21301         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
21302         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
21303       </generalDesc>
21304       <fixedLine>
21305         <nationalNumberPattern>
21306           649(?:
21307             712|
21308             9(?:
21309               4\d|
21310               50
21311             )
21312           )\d{4}
21313         </nationalNumberPattern>
21314         <exampleNumber>6497121234</exampleNumber>
21315       </fixedLine>
21316       <mobile>
21317         <!-- Extra prefixes 246, 247, 346 found online and in the yellow pages. -->
21318         <nationalNumberPattern>
21319           649(?:
21320             2(?:
21321               3[129]|
21322               4[1-7]
21323             )|
21324             3(?:
21325               3[1-389]|
21326               4[1-7]
21327             )|
21328             4[34][1-3]
21329           )\d{4}
21330         </nationalNumberPattern>
21331         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21332         <exampleNumber>6492311234</exampleNumber>
21333       </mobile>
21334       <tollFree>
21335         <nationalNumberPattern>
21336           8(?:
21337             00|
21338             44|
21339             55|
21340             66|
21341             77|
21342             88
21343           )[2-9]\d{6}
21344         </nationalNumberPattern>
21345         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21346         <exampleNumber>8002345678</exampleNumber>
21347       </tollFree>
21348       <premiumRate>
21349         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
21350         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21351         <exampleNumber>9002345678</exampleNumber>
21352       </premiumRate>
21353       <personalNumber>
21354         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
21355         <nationalNumberPattern>
21356           5(?:
21357             00|
21358             33|
21359             44|
21360             66|
21361             77
21362           )[2-9]\d{6}
21363         </nationalNumberPattern>
21364         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21365         <exampleNumber>5002345678</exampleNumber>
21366       </personalNumber>
21367       <voip>
21368         <nationalNumberPattern>64971[01]\d{4}</nationalNumberPattern>
21369         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21370         <exampleNumber>6497101234</exampleNumber>
21371       </voip>
21372     </territory>
21373
21374     <!-- Chad -->
21375     <!-- The international prefix includes 16 as the international manual exchange. -->
21376     <territory id="TD" countryCode="235" preferredInternationalPrefix="00"
21377                internationalPrefix="00|16">
21378       <references>
21379         <sourceUrl>http://www.itu.int/oth/T0202000029/en</sourceUrl>
21380       </references>
21381       <availableFormats>
21382         <numberFormat
21383           pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
21384           <format>$1 $2 $3 $4</format>
21385         </numberFormat>
21386       </availableFormats>
21387       <generalDesc>
21388         <nationalNumberPattern>[2679]\d{7}</nationalNumberPattern>
21389         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21390       </generalDesc>
21391       <fixedLine>
21392         <nationalNumberPattern>
21393           22(?:
21394             [3789]0|
21395             5[0-5]|
21396             6[89]
21397           )\d{4}
21398         </nationalNumberPattern>
21399         <exampleNumber>22501234</exampleNumber>
21400       </fixedLine>
21401       <mobile>
21402         <!-- Sotel Tchad "SALAM" (77 XX XX XX) is classified as a fixed operator in the plan, but it
21403              also says numbers starting with 7 are mobile numbers. Putting under mobile for now.
21404              Also adding 6[028] and 63[5-9] which are operated by Airtel. -->
21405         <nationalNumberPattern>
21406           (?:
21407             6[02368]\d|
21408             77\d|
21409             9(?:
21410               5[0-4]|
21411               9\d
21412             )
21413           )\d{5}
21414         </nationalNumberPattern>
21415         <exampleNumber>63012345</exampleNumber>
21416       </mobile>
21417     </territory>
21418
21419     <!-- French Southern Territories -->
21420     <!-- id="TF" countryCode="262" internationalPrefix="00" nationalPrefix="0" -->
21421     <!-- This country is not covered due to lack of information about its numbering plan. It has 140
21422          temporary inhabitants. -->
21423
21424     <!-- Togo -->
21425     <territory id="TG" countryCode="228" internationalPrefix="00">
21426       <references>
21427         <sourceUrl>http://www.itu.int/oth/T02020000D1/en</sourceUrl>
21428       </references>
21429       <availableFormats>
21430         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
21431           <format>$1 $2 $3 $4</format>
21432         </numberFormat>
21433       </availableFormats>
21434       <generalDesc>
21435         <nationalNumberPattern>[29]\d{7}</nationalNumberPattern>
21436         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21437       </generalDesc>
21438       <fixedLine>
21439         <nationalNumberPattern>
21440           2(?:
21441             2[2-7]|
21442             3[23]|
21443             44|
21444             55|
21445             66|
21446             77
21447           )\d{5}
21448         </nationalNumberPattern>
21449         <exampleNumber>22212345</exampleNumber>
21450       </fixedLine>
21451       <mobile>
21452         <!-- Prefix 93 is from an open-source bug report -->
21453         <nationalNumberPattern>9[0-389]\d{6}</nationalNumberPattern>
21454         <exampleNumber>90112345</exampleNumber>
21455       </mobile>
21456     </territory>
21457
21458     <!-- Thailand -->
21459     <territory id="TH" countryCode="66" internationalPrefix="00"
21460                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
21461                mobileNumberPortableRegion="true">
21462       <references>
21463         <sourceUrl>http://www.itu.int/oth/T02020000CD/en</sourceUrl>
21464         <sourceUrl>http://www.barascientific.com/bscnews/variety/emergency/Tel-4Digi.pdf</sourceUrl>
21465       </references>
21466       <availableFormats>
21467         <!-- Formatting patterns from wikipedia and the document itself -
21468              http://en.wikipedia.org/wiki/%2B66 -->
21469         <numberFormat pattern="(2)(\d{3})(\d{4})">
21470           <leadingDigits>2</leadingDigits>
21471           <format>$1 $2 $3</format>
21472         </numberFormat>
21473         <numberFormat pattern="([13-9]\d)(\d{3})(\d{3,4})">
21474           <leadingDigits>
21475             14|
21476             [3-9]
21477           </leadingDigits>
21478           <format>$1 $2 $3</format>
21479         </numberFormat>
21480         <numberFormat nationalPrefixFormattingRule="$FG"
21481           pattern="(1[89]00)(\d{3})(\d{3})">
21482           <leadingDigits>1</leadingDigits>
21483           <format>$1 $2 $3</format>
21484         </numberFormat>
21485       </availableFormats>
21486       <generalDesc>
21487         <nationalNumberPattern>
21488           [2-9]\d{7,8}|
21489           1\d{3}(?:\d{5,6})?
21490         </nationalNumberPattern>
21491         <possibleNumberPattern>\d{4}|\d{8,10}</possibleNumberPattern>
21492       </generalDesc>
21493       <noInternationalDialling>
21494         <nationalNumberPattern>1\d{3}</nationalNumberPattern>
21495         <possibleNumberPattern>\d{4}</possibleNumberPattern>
21496         <exampleNumber>1100</exampleNumber>
21497       </noInternationalDialling>
21498       <fixedLine>
21499         <!-- Numbers online have been found that start with 20, despite the ITU doc not covering
21500              these. -->
21501         <nationalNumberPattern>
21502           (?:
21503             2\d|
21504             3[2-9]|
21505             4[2-5]|
21506             5[2-6]|
21507             7[3-7]
21508           )\d{6}
21509         </nationalNumberPattern>
21510         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21511         <exampleNumber>21234567</exampleNumber>
21512       </fixedLine>
21513       <mobile>
21514         <!-- Numbers found online starting with 62. 14 and 63 are from an open-source bug report,
21515              we couldn't find evidence of these specifically being in use but this article
21516              http://www.prachachat.net/news_detail.php?newsid=1395732787&grpid=03&catid=06&subcatid=0600
21517              talks about prefix 6 and 1 being cleared for mobile use. -->
21518         <nationalNumberPattern>
21519           (?:
21520             14|
21521             6[1-3]|
21522             [89]\d
21523           )\d{7}
21524         </nationalNumberPattern>
21525         <possibleNumberPattern>\d{9}</possibleNumberPattern>
21526         <exampleNumber>812345678</exampleNumber>
21527       </mobile>
21528       <!-- http://en.wikipedia.org/wiki/Toll-free_telephone_number -->
21529       <tollFree>
21530         <nationalNumberPattern>1800\d{6}</nationalNumberPattern>
21531         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21532         <exampleNumber>1800123456</exampleNumber>
21533       </tollFree>
21534       <premiumRate>
21535         <nationalNumberPattern>1900\d{6}</nationalNumberPattern>
21536         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21537         <exampleNumber>1900123456</exampleNumber>
21538       </premiumRate>
21539       <voip>
21540         <!-- The ITU document says that the 89 prefix is also VOIP but there are lots of numbers
21541              online to suggest they are actually used as mobile numbers. -->
21542         <nationalNumberPattern>6[08]\d{7}</nationalNumberPattern>
21543         <possibleNumberPattern>\d{9}</possibleNumberPattern>
21544         <exampleNumber>601234567</exampleNumber>
21545       </voip>
21546       <uan>
21547         <!-- 4-digit numbers are classified under UAN. Most of these are commercial numbers, and
21548              their costs range from free to 6 Baht/min. -->
21549         <nationalNumberPattern>1\d{3}</nationalNumberPattern>
21550         <possibleNumberPattern>\d{4}</possibleNumberPattern>
21551         <exampleNumber>1100</exampleNumber>
21552       </uan>
21553     </territory>
21554
21555     <!-- Tajikistan -->
21556     <territory id="TJ" countryCode="992" preferredInternationalPrefix="8~10"
21557                internationalPrefix="810" nationalPrefix="8"
21558                nationalPrefixFormattingRule="($NP) $FG"
21559                nationalPrefixOptionalWhenFormatting="true">
21560       <references>
21561         <sourceUrl>http://www.itu.int/oth/T02020000CA/en</sourceUrl>
21562       </references>
21563       <availableFormats>
21564         <numberFormat pattern="([349]\d{2})(\d{2})(\d{4})">
21565           <leadingDigits>
21566             [34]7|
21567             91[78]
21568           </leadingDigits>
21569           <format>$1 $2 $3</format>
21570         </numberFormat>
21571         <numberFormat pattern="([459]\d)(\d{3})(\d{4})">
21572           <leadingDigits>
21573             4[48]|
21574             5|
21575             9(?:
21576               1[59]|
21577               [0235-9]
21578             )
21579           </leadingDigits>
21580           <format>$1 $2 $3</format>
21581         </numberFormat>
21582         <numberFormat pattern="(331700)(\d)(\d{2})">
21583           <leadingDigits>331</leadingDigits>
21584           <leadingDigits>3317</leadingDigits>
21585           <leadingDigits>33170</leadingDigits>
21586           <leadingDigits>331700</leadingDigits>
21587           <format>$1 $2 $3</format>
21588         </numberFormat>
21589         <numberFormat pattern="(\d{4})(\d)(\d{4})">
21590           <leadingDigits>3[1-5]</leadingDigits>
21591           <leadingDigits>
21592             3(?:
21593               [1245]|
21594               3(?:
21595                 [02-9]|
21596                 1[0-589]
21597               )
21598             )
21599           </leadingDigits>
21600           <format>$1 $2 $3</format>
21601         </numberFormat>
21602       </availableFormats>
21603       <generalDesc>
21604         <nationalNumberPattern>[3-59]\d{8}</nationalNumberPattern>
21605         <possibleNumberPattern>\d{3,9}</possibleNumberPattern>
21606       </generalDesc>
21607       <fixedLine>
21608         <nationalNumberPattern>
21609           (?:
21610             3(?:
21611               1[3-5]|
21612               2[245]|
21613               3[12]|
21614               4[24-7]|
21615               5[25]|
21616               72
21617             )|
21618             4(?:
21619               46|
21620               74|
21621               87
21622             )
21623           )\d{6}
21624         </nationalNumberPattern>
21625         <exampleNumber>372123456</exampleNumber>
21626       </fixedLine>
21627       <mobile>
21628         <!-- Adding 90 prefix as SMS messages could be successfully delivered to these mobile
21629              numbers, and 50[12] for TCell from bug reports. -->
21630         <nationalNumberPattern>
21631           (?:
21632             50[125]|
21633             9[0-35-9]\d
21634           )\d{6}
21635         </nationalNumberPattern>
21636         <possibleNumberPattern>\d{9}</possibleNumberPattern>
21637         <exampleNumber>917123456</exampleNumber>
21638       </mobile>
21639       <!-- No tollFree or premiumRate information can be found. -->
21640     </territory>
21641
21642     <!-- Tokelau -->
21643     <territory id="TK" countryCode="690" internationalPrefix="00">
21644       <references>
21645         <sourceUrl>http://www.itu.int/oth/T02020000D2/en</sourceUrl>
21646       </references>
21647       <generalDesc>
21648         <nationalNumberPattern>[2-9]\d{3}</nationalNumberPattern>
21649         <possibleNumberPattern>\d{4}</possibleNumberPattern>
21650       </generalDesc>
21651       <fixedLine>
21652         <nationalNumberPattern>[2-4]\d{3}</nationalNumberPattern>
21653         <!-- The example number is the contact number from the ITU document. -->
21654         <exampleNumber>3010</exampleNumber>
21655       </fixedLine>
21656       <mobile>
21657         <nationalNumberPattern>[5-9]\d{3}</nationalNumberPattern>
21658         <exampleNumber>5190</exampleNumber>
21659       </mobile>
21660     </territory>
21661
21662     <!-- Timor-Leste (East Timor) -->
21663     <territory id="TL" countryCode="670" internationalPrefix="00">
21664       <references>
21665         <sourceUrl>http://www.itu.int/oth/T02020000D0/en</sourceUrl>
21666       </references>
21667       <availableFormats>
21668         <numberFormat pattern="(\d{3})(\d{4})">
21669           <leadingDigits>[2-489]</leadingDigits>
21670           <format>$1 $2</format>
21671         </numberFormat>
21672         <!-- Since numbers grew an extra digit, we have no indication of how people are formatting
21673              them. If we see another pattern being used, we should change this later. -->
21674         <numberFormat pattern="(\d{4})(\d{4})">
21675           <leadingDigits>7</leadingDigits>
21676           <format>$1 $2</format>
21677         </numberFormat>
21678       </availableFormats>
21679       <generalDesc>
21680         <nationalNumberPattern>
21681           [2-489]\d{6}|
21682           7\d{6,7}
21683         </nationalNumberPattern>
21684         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
21685       </generalDesc>
21686       <fixedLine>
21687         <nationalNumberPattern>
21688           (?:
21689             2[1-5]|
21690             3[1-9]|
21691             4[1-4]
21692           )\d{5}
21693         </nationalNumberPattern>
21694         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21695         <exampleNumber>2112345</exampleNumber>
21696       </fixedLine>
21697       <mobile>
21698         <nationalNumberPattern>7[3-8]\d{6}</nationalNumberPattern>
21699         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21700         <exampleNumber>77212345</exampleNumber>
21701       </mobile>
21702       <tollFree>
21703         <nationalNumberPattern>80\d{5}</nationalNumberPattern>
21704         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21705         <exampleNumber>8012345</exampleNumber>
21706       </tollFree>
21707       <premiumRate>
21708         <nationalNumberPattern>90\d{5}</nationalNumberPattern>
21709         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21710         <exampleNumber>9012345</exampleNumber>
21711       </premiumRate>
21712       <!-- We don't include paging or voicemail because the identified paging range was used by
21713            mobile previously, and for voicemail, it is unclear if the 2012 change affected these
21714            numbers, or if the range was indeed previously used for voicemail at all. -->
21715       <personalNumber>
21716         <!-- We presume this wasn't affected by the numbering plan update. -->
21717         <nationalNumberPattern>70\d{5}</nationalNumberPattern>
21718         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21719         <exampleNumber>7012345</exampleNumber>
21720       </personalNumber>
21721     </territory>
21722
21723     <!-- Turkmenistan -->
21724     <territory id="TM" countryCode="993" preferredInternationalPrefix="8~10"
21725                internationalPrefix="810" nationalPrefix="8"
21726                nationalPrefixFormattingRule="($NP $FG)">
21727       <references>
21728         <sourceUrl>http://www.itu.int/oth/T02020000D7/en</sourceUrl>
21729         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Turkmenistan</sourceUrl>
21730       </references>
21731       <availableFormats>
21732         <!-- There doesn't seem to be a standardized format. The format below is based on the
21733              Turkmenistan embassy at
21734              http://www.turkmenistanembassy.org/turkmen/info/contact.html -->
21735           <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
21736             <leadingDigits>12</leadingDigits>
21737             <format>$1 $2-$3-$4</format>
21738           </numberFormat>
21739           <numberFormat pattern="(\d{2})(\d{6})" nationalPrefixFormattingRule="$NP $FG">
21740             <leadingDigits>6</leadingDigits>
21741             <format>$1 $2</format>
21742           </numberFormat>
21743           <numberFormat pattern="(\d{3})(\d)(\d{2})(\d{2})">
21744             <leadingDigits>
21745               13|
21746               [2-5]
21747             </leadingDigits>
21748             <format>$1 $2-$3-$4</format>
21749           </numberFormat>
21750       </availableFormats>
21751       <generalDesc>
21752         <nationalNumberPattern>[1-6]\d{7}</nationalNumberPattern>
21753         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21754       </generalDesc>
21755       <fixedLine>
21756         <!-- Additional prefixes from the wikipedia page. -->
21757         <nationalNumberPattern>
21758           (?:
21759             1(?:
21760               2\d|
21761               3[1-9]
21762             )|
21763             2(?:
21764               22|
21765               4[0-35-8]
21766             )|
21767             3(?:
21768               22|
21769               4[03-9]
21770             )|
21771             4(?:
21772               22|
21773               3[128]|
21774               4\d|
21775               6[15]
21776             )|
21777             5(?:
21778               22|
21779               5[7-9]|
21780               6[014-689]
21781             )
21782           )\d{5}
21783         </nationalNumberPattern>
21784         <exampleNumber>12345678</exampleNumber>
21785       </fixedLine>
21786       <mobile>
21787         <!-- According to feedback from users, the carrier Altyn Asyr is the only one currently
21788              operating, with the numbers 6[3-5]\d{6}. MTS used to operate the ranges 6[6-8] but this
21789              has been suspended. It is unclear whether it will resume. We support both ranges in the
21790              meantime. The range 62 seems also now to be in use, according to numbers found online.
21791              -->
21792         <nationalNumberPattern>6[2-8]\d{6}</nationalNumberPattern>
21793         <exampleNumber>66123456</exampleNumber>
21794       </mobile>
21795       <!-- No tollFree or premiumRate information can be found. -->
21796     </territory>
21797
21798     <!-- Tunisia -->
21799     <territory id="TN" countryCode="216" internationalPrefix="00">
21800       <references>
21801         <sourceUrl>http://www.itu.int/oth/T02020000D5/en</sourceUrl>
21802         <sourceUrl>http://www.tunisietelecom.tn/tt/wcm/connect/?MOD=PDMProxy&amp;TYPE=personalization&amp;ID=NONE&amp;KEY=NONE&amp;LIBRARY=%2FcontentRoot%2Ficm%3Alibraries%5B16%5D&amp;FOLDER=%2F&amp;DOC_NAME=%2FcontentRoot%2Ficm%3Alibraries%5B16%5D%2FOTTI+2011.pdf</sourceUrl>
21803         <sourceUrl>http://www.tunisietelecom.tn/tt/internet/fr/pme/fixe/numeros_acceuil</sourceUrl>
21804       </references>
21805       <availableFormats>
21806         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
21807           <format>$1 $2 $3</format>
21808         </numberFormat>
21809       </availableFormats>
21810       <generalDesc>
21811         <nationalNumberPattern>[2-57-9]\d{7}</nationalNumberPattern>
21812         <possibleNumberPattern>\d{8}</possibleNumberPattern>
21813       </generalDesc>
21814       <fixedLine>
21815         <!-- 3[012] numbers are no longer listed in the ITU doc, but we support them based on
21816              online searches. -->
21817         <nationalNumberPattern>
21818           3[012]\d{6}|
21819           7\d{7}|
21820           81200\d{3}
21821         </nationalNumberPattern>
21822         <exampleNumber>71234567</exampleNumber>
21823       </fixedLine>
21824       <mobile>
21825         <!-- Numbers starting with 5 are no longer listed in the ITU doc, but we support them based
21826              on online searches and Wikipedia. -->
21827         <nationalNumberPattern>
21828           (?:
21829             [259]\d|
21830             4[0-24]
21831           )\d{6}
21832         </nationalNumberPattern>
21833         <exampleNumber>20123456</exampleNumber>
21834       </mobile>
21835       <tollFree>
21836         <!-- ITU lists 80 xx xx xx, but the document published by Tunisie Telecom has more specific
21837              information which is followed here. -->
21838         <nationalNumberPattern>8010\d{4}</nationalNumberPattern>
21839         <exampleNumber>80101234</exampleNumber>
21840       </tollFree>
21841       <premiumRate>
21842         <nationalNumberPattern>88\d{6}</nationalNumberPattern>
21843         <exampleNumber>88123456</exampleNumber>
21844       </premiumRate>
21845       <sharedCost>
21846         <!-- 8110xxxx numbers are listed as being "discounted non-geographical numbers" and are put
21847              here for now. In the future we might consider them as UAN.
21848              ITU lists 82 xx xx xx, but the document published by Tunisie Telecom has more specific
21849              information which is followed here. -->
21850         <nationalNumberPattern>8[12]10\d{4}</nationalNumberPattern>
21851         <exampleNumber>81101234</exampleNumber>
21852       </sharedCost>
21853     </territory>
21854
21855     <!-- Tonga -->
21856     <territory id="TO" countryCode="676" internationalPrefix="00" leadingZeroPossible="true">
21857       <references>
21858         <sourceUrl>http://www.itu.int/oth/T02020000D3/en</sourceUrl>
21859         <sourceUrl>http://www.wtng.info/wtng-676-to.html</sourceUrl>
21860       </references>
21861       <availableFormats>
21862         <numberFormat pattern="(\d{2})(\d{3})">
21863           <leadingDigits>
21864             [1-6]|
21865             7[0-4]|
21866             8[05]
21867           </leadingDigits>
21868           <format>$1-$2</format>
21869         </numberFormat>
21870         <numberFormat pattern="(\d{3})(\d{4})">
21871           <leadingDigits>
21872             7[5-9]|
21873             8[47-9]
21874           </leadingDigits>
21875           <format>$1 $2</format>
21876         </numberFormat>
21877         <numberFormat pattern="(\d{4})(\d{3})">
21878           <leadingDigits>0</leadingDigits>
21879           <format>$1 $2</format>
21880         </numberFormat>
21881       </availableFormats>
21882       <generalDesc>
21883         <nationalNumberPattern>[02-8]\d{4,6}</nationalNumberPattern>
21884         <possibleNumberPattern>\d{5,7}</possibleNumberPattern>
21885       </generalDesc>
21886       <fixedLine>
21887         <nationalNumberPattern>
21888           (?:
21889             2\d|
21890             3[1-8]|
21891             4[1-4]|
21892             [56]0|
21893             7[0149]|
21894             8[05]
21895           )\d{3}
21896         </nationalNumberPattern>
21897         <possibleNumberPattern>\d{5}</possibleNumberPattern>
21898         <exampleNumber>20123</exampleNumber>
21899       </fixedLine>
21900       <mobile>
21901         <!-- TCC mobile numbers were given a prefix of "77" in 2009, although this is not mentioned
21902              in their ITU document. Numbers with a prefix of "75" and "84" have also been found. -->
21903         <nationalNumberPattern>
21904           (?:
21905             7[578]|
21906             8[47-9]
21907           )\d{5}
21908         </nationalNumberPattern>
21909         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21910         <exampleNumber>7715123</exampleNumber>
21911       </mobile>
21912       <tollFree>
21913         <nationalNumberPattern>0800\d{3}</nationalNumberPattern>
21914         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21915         <exampleNumber>0800222</exampleNumber>
21916       </tollFree>
21917     </territory>
21918
21919     <!-- Turkey -->
21920     <territory id="TR" countryCode="90" internationalPrefix="00" nationalPrefix="0"
21921                mobileNumberPortableRegion="true">
21922       <references>
21923         <sourceUrl>http://en.wikipedia.org/wiki/%2B90</sourceUrl>
21924         <sourceUrl>http://www.itu.int/oth/T02020000D6/en</sourceUrl>
21925       </references>
21926       <availableFormats>
21927         <numberFormat nationalPrefixFormattingRule="($NP$FG)" pattern="(\d{3})(\d{3})(\d{4})"
21928           nationalPrefixOptionalWhenFormatting="true">
21929           <leadingDigits>
21930             [23]|
21931             4(?:
21932               [0-35-9]|
21933               4[0-35-9]
21934             )
21935           </leadingDigits>
21936           <format>$1 $2 $3</format>
21937         </numberFormat>
21938         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(\d{3})(\d{3})(\d{4})"
21939           nationalPrefixOptionalWhenFormatting="true">
21940           <leadingDigits>[589]</leadingDigits>
21941           <format>$1 $2 $3</format>
21942         </numberFormat>
21943         <numberFormat pattern="(444)(\d{1})(\d{3})">
21944           <leadingDigits>444</leadingDigits>
21945           <format>$1 $2 $3</format>
21946         </numberFormat>
21947       </availableFormats>
21948       <generalDesc>
21949         <nationalNumberPattern>
21950           [2-589]\d{9}|
21951           444\d{4}
21952         </nationalNumberPattern>
21953         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
21954       </generalDesc>
21955       <noInternationalDialling>
21956         <nationalNumberPattern>444\d{4}</nationalNumberPattern>
21957         <possibleNumberPattern>\d{7}</possibleNumberPattern>
21958         <exampleNumber>4441444</exampleNumber>
21959       </noInternationalDialling>
21960       <fixedLine>
21961         <!-- Includes numbers starting with 392 for Northern Cyprus. -->
21962         <nationalNumberPattern>
21963           (?:
21964             2(?:
21965               [13][26]|
21966               [28][2468]|
21967               [45][268]|
21968               [67][246]
21969             )|
21970             3(?:
21971               [13][28]|
21972               [24-6][2468]|
21973               [78][02468]|
21974               92
21975             )|
21976             4(?:
21977               [16][246]|
21978               [23578][2468]|
21979               4[26]
21980             )
21981           )\d{7}
21982         </nationalNumberPattern>
21983         <possibleNumberPattern>\d{10}</possibleNumberPattern>
21984         <exampleNumber>2123456789</exampleNumber>
21985       </fixedLine>
21986       <mobile>
21987         <!-- There are some differences between the Turkish and English wikipedia pages here, and
21988              some number prefixes do not seem to be able to be found online. Omitting 500, 508 and
21989              509 from the English page because of this. -->
21990         <nationalNumberPattern>
21991           5(?:
21992             0[1-7]|
21993             22|
21994             [34]\d|
21995             5[1-59]|
21996             9[246]
21997           )\d{7}
21998         </nationalNumberPattern>
21999         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22000         <exampleNumber>5012345678</exampleNumber>
22001       </mobile>
22002       <pager>
22003         <nationalNumberPattern>512\d{7}</nationalNumberPattern>
22004         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22005         <exampleNumber>5123456789</exampleNumber>
22006       </pager>
22007       <tollFree>
22008         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
22009         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22010         <exampleNumber>8001234567</exampleNumber>
22011       </tollFree>
22012       <premiumRate>
22013         <nationalNumberPattern>900\d{7}</nationalNumberPattern>
22014         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22015         <exampleNumber>9001234567</exampleNumber>
22016       </premiumRate>
22017       <uan>
22018         <!-- http://www.turktelekom.com.tr/tt/portal/News/Archive/7-digit-special-service-number-starting-with-444 -->
22019         <nationalNumberPattern>
22020           444\d{4}|
22021           850\d{7}
22022         </nationalNumberPattern>
22023         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
22024         <exampleNumber>4441444</exampleNumber>
22025       </uan>
22026     </territory>
22027
22028     <!-- Trinidad and Tobago -->
22029     <territory id="TT" countryCode="1" leadingDigits="868" nationalPrefix="1"
22030                internationalPrefix="011">
22031       <references>
22032         <sourceUrl>http://www.itu.int/oth/T02020000D4/en</sourceUrl>
22033       </references>
22034       <generalDesc>
22035         <!-- NANPA country - uses US formatting rules -->
22036         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
22037         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
22038       </generalDesc>
22039       <fixedLine>
22040         <nationalNumberPattern>
22041           868(?:
22042             2(?:
22043               [03]1|
22044               2[1-5]
22045             )|
22046             6(?:
22047               0[79]|
22048               1[02-9]|
22049               2[1-9]|
22050               [3-69]\d|
22051               7[0-79]
22052             )|
22053             82[124]
22054           )\d{4}
22055         </nationalNumberPattern>
22056         <exampleNumber>8682211234</exampleNumber>
22057       </fixedLine>
22058       <mobile>
22059         <nationalNumberPattern>
22060           868(?:
22061             2(?:
22062               [89]\d
22063             )|
22064             3(?:
22065               0[1-9]|
22066               1[02-9]|
22067               [2-9]\d
22068             )|
22069             4[6-9]\d|
22070             6(?:
22071               20|
22072               78|
22073               8\d
22074             )|
22075             7(?:
22076               0[1-9]|
22077               1[02-9]|
22078               [2-9]\d
22079             )
22080           )\d{4}
22081         </nationalNumberPattern>
22082         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22083         <exampleNumber>8682911234</exampleNumber>
22084       </mobile>
22085       <tollFree>
22086         <nationalNumberPattern>
22087           8(?:
22088             00|
22089             44|
22090             55|
22091             66|
22092             77|
22093             88
22094           )[2-9]\d{6}
22095         </nationalNumberPattern>
22096         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22097         <exampleNumber>8002345678</exampleNumber>
22098       </tollFree>
22099       <premiumRate>
22100         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
22101         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22102         <exampleNumber>9002345678</exampleNumber>
22103       </premiumRate>
22104       <personalNumber>
22105         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
22106         <nationalNumberPattern>
22107           5(?:
22108             00|
22109             33|
22110             44|
22111             66|
22112             77
22113           )[2-9]\d{6}
22114         </nationalNumberPattern>
22115         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22116         <exampleNumber>5002345678</exampleNumber>
22117       </personalNumber>
22118     </territory>
22119
22120     <!-- Tuvalu -->
22121     <territory id="TV" countryCode="688" internationalPrefix="00">
22122       <references>
22123         <sourceUrl>http://www.itu.int/oth/T02020000D9/en</sourceUrl>
22124         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Tuvalu</sourceUrl>
22125       </references>
22126       <!-- Numbers are formatted as a block. -->
22127       <generalDesc>
22128         <nationalNumberPattern>[29]\d{4,5}</nationalNumberPattern>
22129         <possibleNumberPattern>\d{5,6}</possibleNumberPattern>
22130       </generalDesc>
22131       <fixedLine>
22132         <nationalNumberPattern>2[02-9]\d{3}</nationalNumberPattern>
22133         <possibleNumberPattern>\d{5}</possibleNumberPattern>
22134         <exampleNumber>20123</exampleNumber>
22135       </fixedLine>
22136       <mobile>
22137         <!-- Some numbers online can be found that are 5-digits long, and start with 90 or 91. We
22138              don't know if these are valid or not - the ITU document excludes them - so are not
22139              covering these for now. -->
22140         <nationalNumberPattern>90\d{4}</nationalNumberPattern>
22141         <possibleNumberPattern>\d{6}</possibleNumberPattern>
22142         <exampleNumber>901234</exampleNumber>
22143       </mobile>
22144     </territory>
22145
22146     <!-- Taiwan, China -->
22147     <!-- Extension symbols found on the internet so far have been #, X and Ext - so # has been
22148          chosen as the preferred extension prefix. -->
22149     <territory id="TW" countryCode="886" internationalPrefix="0(?:0[25679]|19)"
22150                nationalPrefix="0" preferredExtnPrefix="#" nationalPrefixFormattingRule="$NP$FG"
22151                mobileNumberPortableRegion="true">
22152       <references>
22153         <sourceUrl>http://www.itu.int/oth/T02020000EB/en</sourceUrl>
22154       </references>
22155       <availableFormats>
22156         <numberFormat pattern="([2-8])(\d{3,4})(\d{4})">
22157           <leadingDigits>
22158             [2-6]|
22159             [78][1-9]
22160           </leadingDigits>
22161           <format>$1 $2 $3</format>
22162         </numberFormat>
22163         <numberFormat pattern="([89]\d{2})(\d{3})(\d{3})">
22164           <leadingDigits>
22165             80|
22166             9
22167           </leadingDigits>
22168           <format>$1 $2 $3</format>
22169         </numberFormat>
22170         <numberFormat pattern="(70)(\d{4})(\d{4})">
22171           <leadingDigits>70</leadingDigits>
22172           <format>$1 $2 $3</format>
22173         </numberFormat>
22174       </availableFormats>
22175       <generalDesc>
22176         <nationalNumberPattern>
22177           [2-689]\d{7,8}|
22178           7\d{7,9}
22179         </nationalNumberPattern>
22180         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
22181       </generalDesc>
22182       <fixedLine>
22183         <nationalNumberPattern>[2-8]\d{7,8}</nationalNumberPattern>
22184         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
22185         <exampleNumber>21234567</exampleNumber>
22186       </fixedLine>
22187       <mobile>
22188         <nationalNumberPattern>9\d{8}</nationalNumberPattern>
22189         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22190         <exampleNumber>912345678</exampleNumber>
22191       </mobile>
22192       <tollFree>
22193         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
22194         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22195         <exampleNumber>800123456</exampleNumber>
22196       </tollFree>
22197       <premiumRate>
22198         <nationalNumberPattern>900\d{6}</nationalNumberPattern>
22199         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22200         <exampleNumber>900123456</exampleNumber>
22201       </premiumRate>
22202       <!-- http://www.chief.com.tw/telecom_eng/front/bin/ptlist.phtml?Category=107 -->
22203       <voip>
22204         <nationalNumberPattern>70\d{8}</nationalNumberPattern>
22205         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22206         <exampleNumber>7012345678</exampleNumber>
22207       </voip>
22208     </territory>
22209
22210     <!-- Tanzania -->
22211     <territory id="TZ" countryCode="255" internationalPrefix="00[056]"
22212                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
22213       <references>
22214         <sourceUrl>http://www.itu.int/oth/T02020000CB/en</sourceUrl>
22215       </references>
22216       <availableFormats>
22217         <numberFormat pattern="([24]\d)(\d{3})(\d{4})">
22218           <leadingDigits>[24]</leadingDigits>
22219           <format>$1 $2 $3</format>
22220         </numberFormat>
22221         <numberFormat pattern="([67]\d{2})(\d{3})(\d{3})">
22222           <leadingDigits>[67]</leadingDigits>
22223           <format>$1 $2 $3</format>
22224         </numberFormat>
22225         <!-- Formatting for special numbers from http://www.tcra.go.tz -->
22226         <numberFormat pattern="([89]\d{2})(\d{2})(\d{4})">
22227           <leadingDigits>[89]</leadingDigits>
22228           <format>$1 $2 $3</format>
22229         </numberFormat>
22230       </availableFormats>
22231       <generalDesc>
22232         <nationalNumberPattern>\d{9}</nationalNumberPattern>
22233         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
22234       </generalDesc>
22235       <fixedLine>
22236         <nationalNumberPattern>2[2-8]\d{7}</nationalNumberPattern>
22237         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
22238         <exampleNumber>222345678</exampleNumber>
22239       </fixedLine>
22240       <mobile>
22241         <nationalNumberPattern>
22242           (?:
22243             6[1578]|
22244             7[1-9]
22245           )\d{7}
22246         </nationalNumberPattern>
22247         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22248         <exampleNumber>612345678</exampleNumber>
22249       </mobile>
22250       <tollFree>
22251         <nationalNumberPattern>80[08]\d{6}</nationalNumberPattern>
22252         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22253         <exampleNumber>800123456</exampleNumber>
22254       </tollFree>
22255       <premiumRate>
22256         <nationalNumberPattern>90\d{7}</nationalNumberPattern>
22257         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22258         <exampleNumber>900123456</exampleNumber>
22259       </premiumRate>
22260       <sharedCost>
22261         <nationalNumberPattern>
22262           8(?:
22263             40|
22264             6[01]
22265           )\d{6}
22266         </nationalNumberPattern>
22267         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22268         <exampleNumber>840123456</exampleNumber>
22269       </sharedCost>
22270       <voip>
22271         <nationalNumberPattern>41\d{7}</nationalNumberPattern>
22272         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22273         <exampleNumber>412345678</exampleNumber>
22274       </voip>
22275     </territory>
22276
22277     <!-- Ukraine -->
22278     <territory id="UA" countryCode="380" preferredInternationalPrefix="0~0"
22279                internationalPrefix="00"
22280                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
22281       <references>
22282         <sourceUrl>http://www.itu.int/oth/T02020000DB/en</sourceUrl>
22283         <sourceUrl>http://en.wikipedia.org/wiki/%2B380</sourceUrl>
22284       </references>
22285       <availableFormats>
22286         <!-- City codes separated out. No definitive list has been found of what constitutes the
22287              area code - http://www.ua.all-biz.info/guide/phonecodes is useful but not error-free.
22288              Have used local yellow pages guidelines, Google searches and regression tests to
22289              reverse-engineer these rules as well as bugs. -->
22290         <numberFormat pattern="([3-689]\d)(\d{3})(\d{4})">
22291           <leadingDigits>
22292             [38]9|
22293             4(?:
22294               [45][0-5]|
22295               87
22296             )|
22297             5(?:
22298               0|
22299               6[37]|
22300               7[37]
22301             )|
22302             6[36-8]|
22303             9[1-9]
22304           </leadingDigits>
22305           <leadingDigits>
22306             [38]9|
22307             4(?:
22308               [45][0-5]|
22309               87
22310             )|
22311             5(?:
22312               0|
22313               6(?:
22314                 3[14-7]|
22315                 7
22316               )|
22317               7[37]
22318             )|
22319             6[36-8]|
22320             9[1-9]
22321           </leadingDigits>
22322           <format>$1 $2 $3</format>
22323         </numberFormat>
22324         <numberFormat pattern="([3-689]\d{2})(\d{3})(\d{3})">
22325           <leadingDigits>
22326             3[1-8]2|
22327             4[13678]2|
22328             5(?:
22329               [12457]2|
22330               6[24]
22331             )|
22332             6(?:
22333               [49]2|
22334               [12][29]|
22335               5[24]
22336             )|
22337             8[0-8]|
22338             90
22339           </leadingDigits>
22340           <leadingDigits>
22341             3(?:
22342               [1-46-8]2[013-9]|
22343               52
22344             )|
22345             4(?:
22346               [1378]2|
22347               62[013-9]
22348             )|
22349             5(?:
22350               [12457]2|
22351               6[24]
22352             )|
22353             6(?:
22354               [49]2|
22355               [12][29]|
22356               5[24]
22357             )|
22358             8[0-8]|
22359             90
22360           </leadingDigits>
22361           <format>$1 $2 $3</format>
22362         </numberFormat>
22363         <numberFormat pattern="([3-6]\d{3})(\d{5})">
22364           <leadingDigits>
22365             3(?:
22366               5[013-9]|
22367               [1-46-8]
22368             )|
22369             4(?:
22370               [137][013-9]|
22371               6|
22372               [45][6-9]|
22373               8[4-6]
22374             )|
22375             5(?:
22376               [1245][013-9]|
22377               6[0135-9]|
22378               3|
22379               7[4-6]
22380             )|
22381             6(?:
22382               [49][013-9]|
22383               5[0135-9]|
22384               [12][13-8]
22385             )
22386           </leadingDigits>
22387           <leadingDigits>
22388             3(?:
22389               5[013-9]|
22390               [1-46-8](?:
22391                 22|
22392                 [013-9]
22393               )
22394             )|
22395             4(?:
22396               [137][013-9]|
22397               6(?:
22398                 [013-9]|
22399                 22
22400               )|
22401               [45][6-9]|
22402               8[4-6]
22403             )|
22404             5(?:
22405               [1245][013-9]|
22406               6(?:
22407                 3[02389]|
22408                 [015689]
22409               )|
22410               3|
22411               7[4-6]
22412             )|
22413             6(?:
22414               [49][013-9]|
22415               5[0135-9]|
22416               [12][13-8]
22417             )
22418           </leadingDigits>
22419           <format>$1 $2</format>
22420         </numberFormat>
22421       </availableFormats>
22422       <generalDesc>
22423         <nationalNumberPattern>[3-689]\d{8}</nationalNumberPattern>
22424         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
22425       </generalDesc>
22426       <fixedLine>
22427         <nationalNumberPattern>
22428           (?:
22429             3[1-8]|
22430             4[13-8]|
22431             5[1-7]|
22432             6[12459]
22433           )\d{7}
22434         </nationalNumberPattern>
22435         <exampleNumber>311234567</exampleNumber>
22436       </fixedLine>
22437       <mobile>
22438         <nationalNumberPattern>
22439           (?:
22440             39|
22441             50|
22442             6[36-8]|
22443             9[1-9]
22444           )\d{7}
22445         </nationalNumberPattern>
22446         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22447         <exampleNumber>391234567</exampleNumber>
22448       </mobile>
22449       <tollFree>
22450         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
22451         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22452         <exampleNumber>800123456</exampleNumber>
22453       </tollFree>
22454       <premiumRate>
22455         <nationalNumberPattern>900\d{6}</nationalNumberPattern>
22456         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22457         <exampleNumber>900123456</exampleNumber>
22458       </premiumRate>
22459       <!-- Added based on: http://www.didx.net/did/ShowCountry/Country/AreaDesc/Area/9442 -->
22460       <voip>
22461         <nationalNumberPattern>89\d{7}</nationalNumberPattern>
22462         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22463         <exampleNumber>891234567</exampleNumber>
22464       </voip>
22465     </territory>
22466
22467     <!-- Uganda -->
22468     <territory id="UG" countryCode="256" internationalPrefix="00[057]"
22469                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
22470       <references>
22471         <sourceUrl>http://www.itu.int/oth/T02020000F1/en</sourceUrl>
22472         <sourceUrl>http://www.ucc.co.ug/licensing/ugandaNumberingPlan.pdf</sourceUrl>
22473       </references>
22474       <availableFormats>
22475         <numberFormat pattern="(\d{3})(\d{6})">
22476           <leadingDigits>
22477             [7-9]|
22478             20(?:
22479               [013-8]|
22480               2[5-9]
22481             )|
22482             4(?:
22483               6[45]|
22484               [7-9]
22485             )
22486           </leadingDigits>
22487           <format>$1 $2</format>
22488         </numberFormat>
22489         <numberFormat pattern="(\d{2})(\d{7})">
22490           <leadingDigits>
22491             3|
22492             4(?:
22493               [1-5]|
22494               6[0-36-9]
22495             )
22496           </leadingDigits>
22497           <format>$1 $2</format>
22498         </numberFormat>
22499         <numberFormat pattern="(2024)(\d{5})">
22500           <leadingDigits>2024</leadingDigits>
22501           <format>$1 $2</format>
22502         </numberFormat>
22503       </availableFormats>
22504       <generalDesc>
22505         <nationalNumberPattern>\d{9}</nationalNumberPattern>
22506         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
22507       </generalDesc>
22508       <fixedLine>
22509         <!-- Ranges with prefixes 20[5-8] are "not yet operational" as of Feb. 2013. -->
22510         <nationalNumberPattern>
22511           20(?:
22512             [0147]\d{2}|
22513             2(?:
22514               40|
22515               [5-9]\d
22516             )|
22517             3[23]\d|
22518             5[0-4]\d|
22519             6[03]\d|
22520             8[0-2]\d
22521           )\d{4}|
22522           [34]\d{8}
22523         </nationalNumberPattern>
22524         <!-- The ITU plan calls for all numbers to be exactly 9 digits. However, it's not clear if
22525              local dialing is still possible. We assume it is for now. -->
22526         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
22527         <exampleNumber>312345678</exampleNumber>
22528       </fixedLine>
22529       <mobile>
22530         <!-- Added 79[5-9] and 707 from online numbers found with this prefix. -->
22531         <!-- Ranges with prefixes 7[46] are "not yet operational" as of Jun. 2013. -->
22532         <!-- Ranges with prefixes 2030 or 723 are "not yet operational" as of Oct. 2014. -->
22533         <nationalNumberPattern>
22534           2030\d{5}|
22535           7(?:
22536             0[0-7]|
22537             [15789]\d|
22538             2[03]|
22539             30|
22540             [46][0-4]
22541           )\d{6}
22542         </nationalNumberPattern>
22543         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22544         <exampleNumber>712345678</exampleNumber>
22545       </mobile>
22546       <tollFree>
22547         <nationalNumberPattern>800[123]\d{5}</nationalNumberPattern>
22548         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22549         <exampleNumber>800123456</exampleNumber>
22550       </tollFree>
22551       <premiumRate>
22552         <nationalNumberPattern>90[123]\d{6}</nationalNumberPattern>
22553         <possibleNumberPattern>\d{9}</possibleNumberPattern>
22554         <exampleNumber>901123456</exampleNumber>
22555       </premiumRate>
22556     </territory>
22557
22558     <!-- United States -->
22559     <!-- Note the national prefix of US is the same as its country code, and when formatting phone
22560          numbers in the national format, it is not included. Therefore, we omit it here to make
22561          formatting consistent with the rest of the world. The same applies to all the
22562          countries/regions under NANPA -->
22563     <!-- The national prefix of "1" here is the same as the country code. It is not used by default
22564          when formatting, but is set here so that users who are calling formatByPattern can specify
22565          NationalPrefixFormattingRule if they want to. -->
22566     <territory id="US" countryCode="1" internationalPrefix="011" mainCountryForCode="true"
22567                nationalPrefix="1" nationalPrefixOptionalWhenFormatting="true"
22568                mobileNumberPortableRegion="true">
22569       <references>
22570         <sourceUrl>http://www.nanpa.com/reports/reports_npa.html</sourceUrl>
22571         <sourceUrl>http://en.wikipedia.org/wiki/North_American_Numbering_Plan</sourceUrl>
22572       </references>
22573       <availableFormats>
22574         <numberFormat pattern="(\d{3})(\d{4})">
22575           <format>$1-$2</format>
22576           <intlFormat>NA</intlFormat>
22577         </numberFormat>
22578         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
22579           <format>($1) $2-$3</format>
22580           <!-- A different pattern is used when formatting internationally, as the area code is no
22581                longer optional and should not be in brackets. -->
22582           <intlFormat>$1-$2-$3</intlFormat>
22583         </numberFormat>
22584       </availableFormats>
22585       <generalDesc>
22586         <nationalNumberPattern>[2-9]\d{9}</nationalNumberPattern>
22587         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
22588       </generalDesc>
22589       <fixedLine>
22590         <nationalNumberPattern>
22591           (?:
22592             2(?:
22593               0[1-35-9]|
22594               1[02-9]|
22595               2[04589]|
22596               3[149]|
22597               4[08]|
22598               5[1-46]|
22599               6[0279]|
22600               7[026]|
22601               8[13]
22602             )|
22603             3(?:
22604               0[1-57-9]|
22605               1[02-9]|
22606               2[0135]|
22607               3[014679]|
22608               4[67]|
22609               5[12]|
22610               6[014]|
22611               8[56]
22612             )|
22613             4(?:
22614               0[124-9]|
22615               1[02-579]|
22616               2[3-5]|
22617               3[0245]|
22618               4[0235]|
22619               58|
22620               69|
22621               7[0589]|
22622               8[04]
22623             )|
22624             5(?:
22625               0[1-57-9]|
22626               1[0235-8]|
22627               20|
22628               3[0149]|
22629               4[01]|
22630               5[19]|
22631               6[1-37]|
22632               7[013-5]|
22633               8[056]
22634             )|
22635             6(?:
22636               0[1-35-9]|
22637               1[024-9]|
22638               2[03689]|
22639               3[016]|
22640               4[16]|
22641               5[017]|
22642               6[0-279]|
22643               78|
22644               8[12]
22645             )|
22646             7(?:
22647               0[1-46-8]|
22648               1[02-9]|
22649               2[0457]|
22650               3[1247]|
22651               4[07]|
22652               5[47]|
22653               6[02359]|
22654               7[02-59]|
22655               8[156]
22656             )|
22657             8(?:
22658               0[1-68]|
22659               1[02-8]|
22660               28|
22661               3[0-25]|
22662               4[3578]|
22663               5[06-9]|
22664               6[02-5]|
22665               7[028]
22666             )|
22667             9(?:
22668               0[1346-9]|
22669               1[02-9]|
22670               2[0589]|
22671               3[01678]|
22672               4[0179]|
22673               5[12469]|
22674               7[0-3589]|
22675               8[0459]
22676             )
22677           )[2-9]\d{6}
22678         </nationalNumberPattern>
22679         <exampleNumber>2015555555</exampleNumber>
22680       </fixedLine>
22681       <mobile>
22682         <nationalNumberPattern>
22683           (?:
22684             2(?:
22685               0[1-35-9]|
22686               1[02-9]|
22687               2[04589]|
22688               3[149]|
22689               4[08]|
22690               5[1-46]|
22691               6[0279]|
22692               7[026]|
22693               8[13]
22694             )|
22695             3(?:
22696               0[1-57-9]|
22697               1[02-9]|
22698               2[0135]|
22699               3[014679]|
22700               4[67]|
22701               5[12]|
22702               6[014]|
22703               8[56]
22704             )|
22705             4(?:
22706               0[124-9]|
22707               1[02-579]|
22708               2[3-5]|
22709               3[0245]|
22710               4[0235]|
22711               58|
22712               69|
22713               7[0589]|
22714               8[04]
22715             )|
22716             5(?:
22717               0[1-57-9]|
22718               1[0235-8]|
22719               20|
22720               3[0149]|
22721               4[01]|
22722               5[19]|
22723               6[1-37]|
22724               7[013-5]|
22725               8[056]
22726             )|
22727             6(?:
22728               0[1-35-9]|
22729               1[024-9]|
22730               2[03689]|
22731               3[016]|
22732               4[16]|
22733               5[017]|
22734               6[0-279]|
22735               78|
22736               8[12]
22737             )|
22738             7(?:
22739               0[1-46-8]|
22740               1[02-9]|
22741               2[0457]|
22742               3[1247]|
22743               4[07]|
22744               5[47]|
22745               6[02359]|
22746               7[02-59]|
22747               8[156]
22748             )|
22749             8(?:
22750               0[1-68]|
22751               1[02-8]|
22752               28|
22753               3[0-25]|
22754               4[3578]|
22755               5[06-9]|
22756               6[02-5]|
22757               7[028]
22758             )|
22759             9(?:
22760               0[1346-9]|
22761               1[02-9]|
22762               2[0589]|
22763               3[01678]|
22764               4[0179]|
22765               5[12469]|
22766               7[0-3589]|
22767               8[0459]
22768             )
22769           )[2-9]\d{6}
22770         </nationalNumberPattern>
22771         <exampleNumber>2015555555</exampleNumber>
22772       </mobile>
22773       <tollFree>
22774         <nationalNumberPattern>
22775           8(?:
22776             00|
22777             44|
22778             55|
22779             66|
22780             77|
22781             88
22782           )[2-9]\d{6}
22783         </nationalNumberPattern>
22784         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22785         <exampleNumber>8002345678</exampleNumber>
22786       </tollFree>
22787       <premiumRate>
22788         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
22789         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22790         <exampleNumber>9002345678</exampleNumber>
22791       </premiumRate>
22792       <personalNumber>
22793         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
22794         <nationalNumberPattern>
22795           5(?:
22796             00|
22797             33|
22798             44|
22799             66|
22800             77
22801           )[2-9]\d{6}
22802         </nationalNumberPattern>
22803         <possibleNumberPattern>\d{10}</possibleNumberPattern>
22804         <exampleNumber>5002345678</exampleNumber>
22805       </personalNumber>
22806     </territory>
22807
22808     <!-- Uruguay -->
22809     <!-- International long-distance providers can be dialled by dialling 01 followed by a carrier
22810          code JK, where J = [3-9] and K is any digit. -->
22811     <territory id="UY" countryCode="598" internationalPrefix="0(?:1[3-9]\d|0)"
22812                preferredInternationalPrefix="00" nationalPrefix="0" preferredExtnPrefix=" int. ">
22813       <references>
22814         <sourceUrl>http://www.itu.int/oth/T02020000E0/en</sourceUrl>
22815         <sourceUrl>http://www.ursec.gub.uy</sourceUrl>
22816         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Uruguay</sourceUrl>
22817       </references>
22818       <availableFormats>
22819         <!-- Following paginasamarillas.com.uy formatting. -->
22820         <numberFormat pattern="(\d{4})(\d{4})">
22821           <leadingDigits>[24]</leadingDigits>
22822           <format>$1 $2</format>
22823         </numberFormat>
22824         <!-- Including the national prefix here since URSEC does when formatting these. -->
22825         <numberFormat pattern="(\d{2})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
22826           <leadingDigits>9[1-9]</leadingDigits>
22827           <format>$1 $2 $3</format>
22828         </numberFormat>
22829         <numberFormat pattern="(\d{3})(\d{4})" nationalPrefixFormattingRule="$NP$FG">
22830           <leadingDigits>[89]0</leadingDigits>
22831           <format>$1 $2</format>
22832         </numberFormat>
22833       </availableFormats>
22834       <generalDesc>
22835         <nationalNumberPattern>[2489]\d{6,7}</nationalNumberPattern>
22836         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
22837       </generalDesc>
22838       <fixedLine>
22839         <nationalNumberPattern>
22840           2\d{7}|
22841           4[2-7]\d{6}
22842         </nationalNumberPattern>
22843         <exampleNumber>21231234</exampleNumber>
22844       </fixedLine>
22845       <mobile>
22846         <nationalNumberPattern>9[1-9]\d{6}</nationalNumberPattern>
22847         <possibleNumberPattern>\d{8}</possibleNumberPattern>
22848         <exampleNumber>94231234</exampleNumber>
22849       </mobile>
22850       <tollFree>
22851         <nationalNumberPattern>80[05]\d{4}</nationalNumberPattern>
22852         <possibleNumberPattern>\d{7}</possibleNumberPattern>
22853         <exampleNumber>8001234</exampleNumber>
22854       </tollFree>
22855       <premiumRate>
22856         <nationalNumberPattern>90[0-8]\d{4}</nationalNumberPattern>
22857         <possibleNumberPattern>\d{7}</possibleNumberPattern>
22858         <exampleNumber>9001234</exampleNumber>
22859       </premiumRate>
22860      </territory>
22861
22862     <!-- Uzbekistan -->
22863     <territory id="UZ" countryCode="998" preferredInternationalPrefix="8~10"
22864                internationalPrefix="810" nationalPrefix="8"
22865                nationalPrefixFormattingRule="$NP $FG">
22866       <references>
22867         <sourceUrl>http://www.ttts.uz/eng/telephone_codes/codes_uzb_eng</sourceUrl>
22868         <sourceUrl>http://www.itu.int/oth/T02020000E1/en</sourceUrl>
22869       </references>
22870       <availableFormats>
22871         <numberFormat pattern="([679]\d)(\d{3})(\d{2})(\d{2})">
22872           <format>$1 $2 $3 $4</format>
22873         </numberFormat>
22874       </availableFormats>
22875       <generalDesc>
22876         <nationalNumberPattern>[679]\d{8}</nationalNumberPattern>
22877         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
22878       </generalDesc>
22879       <fixedLine>
22880         <!-- Adding 711 from numbers found online, such as the US embassy, and 6922, which seems to
22881              be used in Namangan. -->
22882         <nationalNumberPattern>
22883           (?:
22884             6(?:
22885               1(?:
22886                 22|
22887                 3[124]|
22888                 4[1-4]|
22889                 5[123578]|
22890                 64
22891               )|
22892               2(?:
22893                 22|
22894                 3[0-57-9]|
22895                 41
22896               )|
22897               5(?:
22898                 22|
22899                 3[3-7]|
22900                 5[024-8]
22901               )|
22902               6\d{2}|
22903               7(?:
22904                 [23]\d|
22905                 7[69]
22906               )|
22907               9(?:
22908                 22|
22909                 4[1-8]|
22910                 6[135]
22911               )
22912             )|
22913             7(?:
22914               0(?:
22915                 5[4-9]|
22916                 6[0146]|
22917                 7[12456]|
22918                 9[135-8]
22919               )|
22920               1[12]\d|
22921               2(?:
22922                 22|
22923                 3[1345789]|
22924                 4[123579]|
22925                 5[14]
22926               )|
22927               3(?:
22928                 2\d|
22929                 3[1578]|
22930                 4[1-35-7]|
22931                 5[1-57]|
22932                 61
22933               )|
22934               4(?:
22935                 2\d|
22936                 3[1-579]|
22937                 7[1-79]
22938               )|
22939               5(?:
22940                 22|
22941                 5[1-9]|
22942                 6[1457]
22943               )|
22944               6(?:
22945                 22|
22946                 3[12457]|
22947                 4[13-8]
22948               )|
22949               9(?:
22950                 22|
22951                 5[1-9]
22952               )
22953             )
22954           )\d{5}
22955         </nationalNumberPattern>
22956         <exampleNumber>662345678</exampleNumber>
22957       </fixedLine>
22958       <mobile>
22959         <!-- Adding 9[45] as suggested by http://www.ucell.uz/en/for_subscribers/how_to_call.html
22960              Adding other prefixes from http://www.weltvorwahlen.de/99861353.html, and any other
22961              prefixes Tyntec has a carrier mapped to. -->
22962         <nationalNumberPattern>
22963           6(?:
22964             1(?:
22965               2(?:
22966                 98|
22967                 2[01]
22968               )|
22969               35[0-4]|
22970               50\d|
22971               61[23]|
22972               7(?:
22973                 [01][017]|
22974                 4\d|
22975                 55|
22976                 9[5-9]
22977               )
22978             )|
22979             2(?:
22980               11\d|
22981               2(?:
22982                 [12]1|
22983                 9[01379]
22984               )|
22985               5(?:
22986                 [126]\d|
22987                 3[0-4]
22988               )|
22989               7\d{2}
22990             )|
22991             5(?:
22992               19[01]|
22993               2(?:
22994                 27|
22995                 9[26]
22996               )|
22997               30\d|
22998               59\d|
22999               7\d{2}
23000             )|
23001             6(?:
23002               2(?:
23003                 1[5-9]|
23004                 2[0367]|
23005                 38|
23006                 41|
23007                 52|
23008                 60
23009               )|
23010               3[79]\d|
23011               4(?:
23012                 56|
23013                 83
23014               )|
23015               7(?:
23016                 [07]\d|
23017                 1[017]|
23018                 3[07]|
23019                 4[047]|
23020                 5[057]|
23021                 67|
23022                 8[0178]|
23023                 9[79]
23024                 )|
23025               9[0-3]\d
23026             )|
23027             7(?:
23028               2(?:
23029                 24|
23030                 3[237]|
23031                 4[5-9]|
23032                 7[15-8]
23033               )|
23034               5(?:
23035                 7[12]|
23036                 8[0589]
23037               )|
23038               7(?:
23039                 0\d|
23040                 [39][07]
23041               )|
23042               9(?:
23043                 0\d|
23044                 7[079]
23045               )
23046             )|
23047             9(?:
23048               2(?:
23049                 1[1267]|
23050                 5\d|
23051                 3[01]|
23052                 7[0-4]
23053               )|
23054               5[67]\d|
23055               6(?:
23056                 2[0-26]|
23057                 8\d
23058               )|
23059               7\d{2}
23060             )
23061           )\d{4}|
23062           7(?:
23063             0\d{3}|
23064             1(?:
23065               13[01]|
23066               6(?:
23067                 0[47]|
23068                 1[67]|
23069                 66
23070               )|
23071               71[3-69]|
23072               98\d
23073             )|
23074             2(?:
23075               2(?:
23076                 2[79]|
23077                 95
23078               )|
23079               3(?:
23080                 2[5-9]|
23081                 6[0-6]
23082               )|
23083               57\d|
23084               7(?:
23085                 0\d|
23086                 1[17]|
23087                 2[27]|
23088                 3[37]|
23089                 44|
23090                 5[057]|
23091                 66|
23092                 88
23093               )
23094             )|
23095             3(?:
23096               2(?:
23097                 1[0-6]|
23098                 21|
23099                 3[469]|
23100                 7[159]
23101               )|
23102               33\d|
23103               5(?:
23104                 0[0-4]|
23105                 5[579]|
23106                 9\d
23107               )|
23108               7(?:
23109                 [0-3579]\d|
23110                 4[0467]|
23111                 6[67]|
23112                 8[078]
23113               )|
23114               9[4-6]\d
23115             )|
23116             4(?:
23117               2(?:
23118                 29|
23119                 5[0257]|
23120                 6[0-7]|
23121                 7[1-57]
23122               )|
23123               5(?:
23124                 1[0-4]|
23125                 8\d|
23126                 9[5-9]
23127               )|
23128               7(?:
23129                 0\d|
23130                 1[024589]|
23131                 2[0127]|
23132                 3[0137]|
23133                 [46][07]|
23134                 5[01]|
23135                 7[5-9]|
23136                 9[079]
23137               )|
23138               9(?:
23139                 7[015-9]|
23140                 [89]\d
23141               )
23142             )|
23143             5(?:
23144               112|
23145               2(?:
23146                 0\d|
23147                 2[29]|
23148                 [49]4
23149               )|
23150               3[1568]\d|
23151               52[6-9]|
23152               7(?:
23153                 0[01578]|
23154                 1[017]|
23155                 [23]7|
23156                 4[047]|
23157                 [5-7]\d|
23158                 8[78]|
23159                 9[079]
23160               )
23161             )|
23162             6(?:
23163               2(?:
23164                 2[1245]|
23165                 4[2-4]
23166               )|
23167               39\d|
23168               41[179]|
23169               5(?:
23170                 [349]\d|
23171                 5[0-2]
23172               )|
23173               7(?:
23174                 0[017]|
23175                 [13]\d|
23176                 22|
23177                 44|
23178                 55|
23179                 67|
23180                 88
23181               )
23182             )|
23183             9(?:
23184               22[128]|
23185               3(?:
23186                 2[0-4]|
23187                 7\d
23188               )|
23189               57[05629]|
23190               7(?:
23191                 2[05-9]|
23192                 3[37]|
23193                 4\d|
23194                 60|
23195                 7[2579]|
23196                 87|
23197                 9[07]
23198               )
23199             )
23200           )\d{4}|
23201           9[0-57-9]\d{7}
23202         </nationalNumberPattern>
23203         <exampleNumber>912345678</exampleNumber>
23204       </mobile>
23205       <!-- No tollFree or premiumRate information can be found. -->
23206     </territory>
23207
23208     <!-- Vatican City -->
23209     <!-- Note that numbers here are also accessible via Italy (+39 and prefix of 06 698) but can
23210          also be dialled with the Vatican City country code. -->
23211     <territory id="VA" countryCode="379" internationalPrefix="00" leadingZeroPossible="true">
23212       <references>
23213         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Vatican_City</sourceUrl>
23214       </references>
23215       <availableFormats>
23216         <numberFormat pattern="(06)(\d{4})(\d{4})">
23217           <format>$1 $2 $3</format>
23218         </numberFormat>
23219       </availableFormats>
23220       <generalDesc>
23221         <nationalNumberPattern>06\d{8}</nationalNumberPattern>
23222         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23223       </generalDesc>
23224       <fixedLine>
23225         <nationalNumberPattern>06698\d{5}</nationalNumberPattern>
23226         <exampleNumber>0669812345</exampleNumber>
23227       </fixedLine>
23228       <mobile>
23229         <!-- We have no information on mobile numbers from the Vatican. It is probable that they use
23230              Italian mobile contracts. -->
23231         <nationalNumberPattern>NA</nationalNumberPattern>
23232         <possibleNumberPattern>NA</possibleNumberPattern>
23233       </mobile>
23234       <!-- No information exists about other types of numbers. -->
23235     </territory>
23236
23237     <!-- Saint Vincent and the Grenadines -->
23238     <territory id="VC" countryCode="1" leadingDigits="784" nationalPrefix="1"
23239                internationalPrefix="011">
23240       <references>
23241         <sourceUrl>http://www.itu.int/oth/T02020000B3/en</sourceUrl>
23242       </references>
23243       <generalDesc>
23244         <!-- NANPA country - uses US formatting rules -->
23245         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
23246         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
23247       </generalDesc>
23248       <!-- For 570, 571 and 572 prefixes, we believe the ITU doc incorrectly listed them to be under
23249            area code 758, which should be 784. -->
23250       <fixedLine>
23251         <nationalNumberPattern>
23252           784(?:
23253             266|
23254             3(?:
23255               6[6-9]|
23256               7\d|
23257               8[0-24-6]
23258             )|
23259             4(?:
23260               38|
23261               5[0-36-8]|
23262               8[0-8]
23263             )|
23264             5(?:
23265               55|
23266               7[0-2]|
23267               93
23268             )|
23269             638|
23270             784
23271           )\d{4}
23272         </nationalNumberPattern>
23273         <exampleNumber>7842661234</exampleNumber>
23274       </fixedLine>
23275       <mobile>
23276         <nationalNumberPattern>
23277           784(?:
23278             4(?:
23279               3[0-4]|
23280               5[45]|
23281               89|
23282               9[0-5]
23283             )|
23284             5(?:
23285               2[6-9]|
23286               3[0-4]
23287             )
23288           )\d{4}
23289         </nationalNumberPattern>
23290         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23291         <exampleNumber>7844301234</exampleNumber>
23292       </mobile>
23293       <tollFree>
23294         <nationalNumberPattern>
23295           8(?:
23296             00|
23297             44|
23298             55|
23299             66|
23300             77|
23301             88
23302           )[2-9]\d{6}
23303         </nationalNumberPattern>
23304         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23305         <exampleNumber>8002345678</exampleNumber>
23306       </tollFree>
23307       <premiumRate>
23308         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
23309         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23310         <exampleNumber>9002345678</exampleNumber>
23311       </premiumRate>
23312       <personalNumber>
23313         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
23314         <nationalNumberPattern>
23315           5(?:
23316             00|
23317             33|
23318             44|
23319             66|
23320             77
23321           )[2-9]\d{6}
23322         </nationalNumberPattern>
23323         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23324         <exampleNumber>5002345678</exampleNumber>
23325       </personalNumber>
23326     </territory>
23327
23328     <!-- Venezuela -->
23329     <!-- 1XX specifies a particular carrier to route a call to, but none of these have been
23330          implemented. -->
23331     <territory id="VE" countryCode="58" internationalPrefix="00"
23332                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
23333                carrierCodeFormattingRule="$CC $FG">
23334       <references>
23335         <sourceUrl>http://www.itu.int/oth/T02020000E3/en</sourceUrl>
23336         <sourceUrl>http://en.wikipedia.org/wiki/+58</sourceUrl>
23337       </references>
23338       <availableFormats>
23339         <numberFormat pattern="(\d{3})(\d{7})">
23340           <format>$1-$2</format>
23341         </numberFormat>
23342       </availableFormats>
23343       <generalDesc>
23344         <nationalNumberPattern>[24589]\d{9}</nationalNumberPattern>
23345         <!-- Open numbering plan. -->
23346         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
23347       </generalDesc>
23348       <fixedLine>
23349         <!-- Including region-free 500 calls here, since these are treated as local calls. Wikipedia
23350              mentions these as 5XX, but online examples that can be found are seemingly restricted
23351              to 50[01]. -->
23352         <nationalNumberPattern>
23353           (?:
23354             2(?:
23355               12|
23356               3[457-9]|
23357               [58][1-9]|
23358               [467]\d|
23359               9[1-6]
23360             )|
23361             50[01]
23362           )\d{7}
23363         </nationalNumberPattern>
23364         <exampleNumber>2121234567</exampleNumber>
23365       </fixedLine>
23366       <mobile>
23367         <nationalNumberPattern>
23368           4(?:
23369             1[24-8]|
23370             2[46]
23371           )\d{7}
23372         </nationalNumberPattern>
23373         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23374         <exampleNumber>4121234567</exampleNumber>
23375       </mobile>
23376       <tollFree>
23377         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
23378         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23379         <exampleNumber>8001234567</exampleNumber>
23380       </tollFree>
23381       <premiumRate>
23382         <nationalNumberPattern>900\d{7}</nationalNumberPattern>
23383         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23384         <exampleNumber>9001234567</exampleNumber>
23385       </premiumRate>
23386     </territory>
23387
23388     <!-- Virgin Islands, British -->
23389     <territory id="VG" countryCode="1" leadingDigits="284" nationalPrefix="1"
23390                internationalPrefix="011">
23391       <references>
23392         <sourceUrl>http://www.itu.int/oth/T020200001E/en</sourceUrl>
23393       </references>
23394       <generalDesc>
23395         <!-- NANPA country - uses US formatting rules -->
23396         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
23397         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
23398       </generalDesc>
23399       <fixedLine>
23400         <!-- No data on central office codes can be found on the nanpa.com website. The codes 422
23401              and 774 have been added from numbers found in the white pages. -->
23402         <nationalNumberPattern>
23403           284(?:
23404             (?:
23405               229|
23406               4(?:
23407                 22|
23408                 9[45]
23409               )|
23410               774|
23411               8(?:
23412                 52|
23413                 6[459]
23414               )
23415             )\d{4}|
23416             496[0-5]\d{3}
23417           )
23418         </nationalNumberPattern>
23419         <exampleNumber>2842291234</exampleNumber>
23420       </fixedLine>
23421       <mobile>
23422         <!-- No data on central office codes can be found on the nanpa.com website. The codes
23423              34[0-367], 446 and 54[57] have been added from numbers found in the white pages. -->
23424         <nationalNumberPattern>
23425           284(?:
23426             (?:
23427               3(?:
23428                 0[0-3]|
23429                 4[0-367]
23430               )|
23431               4(?:
23432                 4[0-6]|
23433                 68|
23434                 99
23435               )|
23436               54[0-57]
23437             )\d{4}|
23438             496[6-9]\d{3}
23439           )
23440         </nationalNumberPattern>
23441         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23442         <exampleNumber>2843001234</exampleNumber>
23443       </mobile>
23444       <tollFree>
23445         <nationalNumberPattern>
23446           8(?:
23447             00|
23448             44|
23449             55|
23450             66|
23451             77|
23452             88
23453           )[2-9]\d{6}
23454         </nationalNumberPattern>
23455         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23456         <exampleNumber>8002345678</exampleNumber>
23457       </tollFree>
23458       <premiumRate>
23459         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
23460         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23461         <exampleNumber>9002345678</exampleNumber>
23462       </premiumRate>
23463       <personalNumber>
23464         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
23465         <nationalNumberPattern>
23466           5(?:
23467             00|
23468             33|
23469             44|
23470             66|
23471             77
23472           )[2-9]\d{6}
23473         </nationalNumberPattern>
23474         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23475         <exampleNumber>5002345678</exampleNumber>
23476       </personalNumber>
23477     </territory>
23478
23479     <!-- Virgin Islands, United States -->
23480     <territory id="VI" countryCode="1" leadingDigits="340" nationalPrefix="1"
23481                internationalPrefix="011">
23482       <references>
23483         <sourceUrl>http://www.itu.int/oth/T02020000DF/en</sourceUrl>
23484       </references>
23485       <generalDesc>
23486         <!-- NANPA country - uses US formatting rules -->
23487         <nationalNumberPattern>[3589]\d{9}</nationalNumberPattern>
23488         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
23489       </generalDesc>
23490       <fixedLine>
23491         <!-- The ITU document seems a bit out-of-date so extra prefixes based on numbers in the
23492              yellow pages have been added, and the list of exchanges found on
23493              http://www.allareacodes.com/340 -->
23494         <nationalNumberPattern>
23495           340(?:
23496             2(?:
23497               01|
23498               2[0678]|
23499               44|
23500               77
23501             )|
23502             3(?:
23503               32|
23504               44
23505             )|
23506             4(?:
23507               22|
23508               7[34]
23509             )|
23510             5(?:
23511               1[34]|
23512               55
23513             )|
23514             6(?:
23515               26|
23516               4[23]|
23517               77|
23518               9[023]
23519             )|
23520             7(?:
23521               1[2-589]|
23522               27|
23523               7\d
23524             )|
23525             884|
23526             998
23527           )\d{4}
23528         </nationalNumberPattern>
23529         <exampleNumber>3406421234</exampleNumber>
23530       </fixedLine>
23531       <mobile>
23532         <nationalNumberPattern>
23533           340(?:
23534             2(?:
23535               01|
23536               2[0678]|
23537               44|
23538               77
23539             )|
23540             3(?:
23541               32|
23542               44
23543             )|
23544             4(?:
23545               22|
23546               7[34]
23547             )|
23548             5(?:
23549               1[34]|
23550               55
23551             )|
23552             6(?:
23553               26|
23554               4[23]|
23555               77|
23556               9[023]
23557             )|
23558             7(?:
23559               1[2-589]|
23560               27|
23561               7\d
23562             )|
23563             884|
23564             998
23565           )\d{4}
23566         </nationalNumberPattern>
23567         <exampleNumber>3406421234</exampleNumber>
23568       </mobile>
23569       <tollFree>
23570         <nationalNumberPattern>
23571           8(?:
23572             00|
23573             44|
23574             55|
23575             66|
23576             77|
23577             88
23578           )[2-9]\d{6}
23579         </nationalNumberPattern>
23580         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23581         <exampleNumber>8002345678</exampleNumber>
23582       </tollFree>
23583       <premiumRate>
23584         <nationalNumberPattern>900[2-9]\d{6}</nationalNumberPattern>
23585         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23586         <exampleNumber>9002345678</exampleNumber>
23587       </premiumRate>
23588       <personalNumber>
23589         <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
23590         <nationalNumberPattern>
23591           5(?:
23592             00|
23593             33|
23594             44|
23595             66|
23596             77
23597           )[2-9]\d{6}
23598         </nationalNumberPattern>
23599         <possibleNumberPattern>\d{10}</possibleNumberPattern>
23600         <exampleNumber>5002345678</exampleNumber>
23601       </personalNumber>
23602     </territory>
23603
23604     <!-- Viet Nam (Vietnam) -->
23605     <territory id="VN" countryCode="84" internationalPrefix="00"
23606                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
23607                nationalPrefixOptionalWhenFormatting="true">
23608       <references>
23609         <sourceUrl>http://www.itu.int/oth/T02020000E4/en</sourceUrl>
23610         <sourceUrl>http://en.wikipedia.org/wiki/%2B84</sourceUrl>
23611       </references>
23612       <availableFormats>
23613         <numberFormat pattern="([17]99)(\d{4})">
23614           <leadingDigits>[17]99</leadingDigits>
23615           <format>$1 $2</format>
23616         </numberFormat>
23617         <numberFormat pattern="([48])(\d{4})(\d{4})">
23618           <leadingDigits>[48]</leadingDigits>
23619           <format>$1 $2 $3</format>
23620         </numberFormat>
23621         <numberFormat pattern="([235-7]\d)(\d{4})(\d{3})">
23622           <leadingDigits>
23623             2[025-79]|
23624             3[0136-9]|
23625             5[2-9]|
23626             6[0-46-8]|
23627             7[02-79]
23628           </leadingDigits>
23629           <format>$1 $2 $3</format>
23630         </numberFormat>
23631         <numberFormat pattern="(80)(\d{5})">
23632           <leadingDigits>80</leadingDigits>
23633           <format>$1 $2</format>
23634         </numberFormat>
23635         <numberFormat pattern="(69\d)(\d{4,5})">
23636           <leadingDigits>69</leadingDigits>
23637           <format>$1 $2</format>
23638         </numberFormat>
23639         <numberFormat pattern="([235-7]\d{2})(\d{4})(\d{3})">
23640           <leadingDigits>
23641             2[1348]|
23642             3[25]|
23643             5[01]|
23644             65|
23645             7[18]
23646           </leadingDigits>
23647           <format>$1 $2 $3</format>
23648         </numberFormat>
23649         <numberFormat pattern="(9\d)(\d{3})(\d{2})(\d{2})">
23650           <leadingDigits>9</leadingDigits>
23651           <format>$1 $2 $3 $4</format>
23652         </numberFormat>
23653         <numberFormat pattern="(1[2689]\d)(\d{3})(\d{4})">
23654           <leadingDigits>
23655             1(?:
23656               [26]|
23657               8[68]|
23658               99
23659             )
23660           </leadingDigits>
23661           <format>$1 $2 $3</format>
23662         </numberFormat>
23663         <numberFormat nationalPrefixFormattingRule="$FG"
23664           pattern="(1[89]00)(\d{4,6})">
23665           <leadingDigits>1[89]0</leadingDigits>
23666           <format>$1 $2</format>
23667         </numberFormat>
23668       </availableFormats>
23669       <generalDesc>
23670         <nationalNumberPattern>
23671           [17]\d{6,9}|
23672           [2-69]\d{7,9}|
23673           8\d{6,8}
23674         </nationalNumberPattern>
23675         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
23676       </generalDesc>
23677       <noInternationalDialling>
23678         <nationalNumberPattern>
23679           [17]99\d{4}|
23680           69\d{5,6}
23681         </nationalNumberPattern>
23682         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
23683         <exampleNumber>1992000</exampleNumber>
23684       </noInternationalDialling>
23685       <fixedLine>
23686         <nationalNumberPattern>
23687           (?:
23688             2(?:
23689               [025-79]|
23690               1[0189]|
23691               [348][01]
23692             )|
23693             3(?:
23694               [0136-9]|
23695               [25][01]
23696             )|
23697             4\d|
23698             5(?:
23699               [01][01]|
23700               [2-9]
23701             )|
23702             6(?:
23703               [0-46-8]|
23704               5[01]
23705             )|
23706             7(?:
23707               [02-79]|
23708               [18][01]
23709             )|
23710             8[1-9]
23711           )\d{7}
23712         </nationalNumberPattern>
23713         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
23714         <exampleNumber>2101234567</exampleNumber>
23715       </fixedLine>
23716       <mobile>
23717         <nationalNumberPattern>
23718           (?:
23719             9\d|
23720             1(?:
23721               2\d|
23722               6[2-9]|
23723               8[68]|
23724               99
23725             )
23726           )\d{7}
23727         </nationalNumberPattern>
23728         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
23729         <exampleNumber>912345678</exampleNumber>
23730       </mobile>
23731       <tollFree>
23732         <nationalNumberPattern>1800\d{4,6}</nationalNumberPattern>
23733         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
23734         <exampleNumber>1800123456</exampleNumber>
23735       </tollFree>
23736       <premiumRate>
23737         <nationalNumberPattern>1900\d{4,6}</nationalNumberPattern>
23738         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
23739         <exampleNumber>1900123456</exampleNumber>
23740       </premiumRate>
23741       <uan>
23742         <!-- These include non-geographic fixed numbers, such as for government ministries. While
23743         listed as "private networks", they may actually be callable from within Vietnam. (They are
23744         "private" in the sense that ordinary people could not be assigned these numbers.) -->
23745         <nationalNumberPattern>
23746           [17]99\d{4}|
23747           69\d{5,6}|
23748           80\d{5}
23749         </nationalNumberPattern>
23750         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
23751         <exampleNumber>1992000</exampleNumber>
23752       </uan>
23753     </territory>
23754
23755     <!-- Vanuatu -->
23756     <territory id="VU" countryCode="678" internationalPrefix="00">
23757       <references>
23758         <sourceUrl>http://www.itu.int/oth/T02020000E2/en</sourceUrl>
23759       </references>
23760       <!-- Should be formatted in one block, apart from the mobile numbers. -->
23761       <availableFormats>
23762         <numberFormat pattern="(\d{3})(\d{4})">
23763           <leadingDigits>[579]</leadingDigits>
23764           <format>$1 $2</format>
23765         </numberFormat>
23766       </availableFormats>
23767       <generalDesc>
23768         <nationalNumberPattern>[2-57-9]\d{4,6}</nationalNumberPattern>
23769         <possibleNumberPattern>\d{5,7}</possibleNumberPattern>
23770       </generalDesc>
23771       <fixedLine>
23772         <nationalNumberPattern>
23773           (?:
23774             2[02-9]\d|
23775             3(?:
23776               [5-7]\d|
23777               8[0-8]
23778             )|
23779             48[4-9]|
23780             88\d
23781           )\d{2}
23782         </nationalNumberPattern>
23783         <possibleNumberPattern>\d{5}</possibleNumberPattern>
23784         <exampleNumber>22123</exampleNumber>
23785       </fixedLine>
23786       <mobile>
23787         <nationalNumberPattern>
23788           (?:
23789             5(?:
23790               7[2-5]|
23791               [3-69]\d
23792             )|
23793             7[013-7]\d
23794           )\d{4}
23795         </nationalNumberPattern>
23796         <possibleNumberPattern>\d{7}</possibleNumberPattern>
23797         <exampleNumber>5912345</exampleNumber>
23798       </mobile>
23799       <!-- Using this for non-geographical numbers, since they have not been clearly defined, and
23800            for government fixed-line numbers. -->
23801       <uan>
23802         <nationalNumberPattern>
23803           3[03]\d{3}|
23804           900\d{4}
23805         </nationalNumberPattern>
23806         <possibleNumberPattern>\d{5,7}</possibleNumberPattern>
23807         <exampleNumber>30123</exampleNumber>
23808       </uan>
23809     </territory>
23810
23811     <!-- Wallis and Futuna (Territoire français d'outre-mer) -->
23812     <territory id="WF" countryCode="681" internationalPrefix="00">
23813       <references>
23814         <sourceUrl>http://www.itu.int/oth/T02020000E6/en</sourceUrl>
23815       </references>
23816       <availableFormats>
23817         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
23818           <format>$1 $2 $3</format>
23819         </numberFormat>
23820       </availableFormats>
23821       <generalDesc>
23822         <nationalNumberPattern>[5-7]\d{5}</nationalNumberPattern>
23823         <possibleNumberPattern>\d{6}</possibleNumberPattern>
23824       </generalDesc>
23825       <fixedLine>
23826         <!-- Web searching only finds examples with the 72 prefix but the ITU document states that
23827              50 and 68 are possible, so they are included here. -->
23828         <nationalNumberPattern>
23829           (?:
23830             50|
23831             68|
23832             72
23833           )\d{4}
23834         </nationalNumberPattern>
23835         <exampleNumber>501234</exampleNumber>
23836       </fixedLine>
23837       <mobile>
23838         <nationalNumberPattern>
23839           (?:
23840             50|
23841             68|
23842             72
23843           )\d{4}
23844         </nationalNumberPattern>
23845         <exampleNumber>501234</exampleNumber>
23846       </mobile>
23847     </territory>
23848
23849     <!-- Samoa -->
23850     <territory id="WS" countryCode="685" internationalPrefix="0">
23851       <references>
23852         <sourceUrl>http://www.itu.int/oth/T02020000B4/en</sourceUrl>
23853       </references>
23854       <availableFormats>
23855         <numberFormat pattern="(8\d{2})(\d{3,4})">
23856           <leadingDigits>8</leadingDigits>
23857           <format>$1 $2</format>
23858         </numberFormat>
23859         <numberFormat pattern="(7\d)(\d{5})">
23860           <leadingDigits>7</leadingDigits>
23861           <format>$1 $2</format>
23862         </numberFormat>
23863         <numberFormat pattern="(\d{5})">
23864           <leadingDigits>[2-6]</leadingDigits>
23865           <format>$1</format>
23866         </numberFormat>
23867       </availableFormats>
23868       <generalDesc>
23869         <nationalNumberPattern>[2-8]\d{4,6}</nationalNumberPattern>
23870         <possibleNumberPattern>\d{5,7}</possibleNumberPattern>
23871       </generalDesc>
23872       <fixedLine>
23873         <nationalNumberPattern>
23874           (?:
23875             [2-5]\d|
23876             6[1-9]|
23877             84\d{2}
23878           )\d{3}
23879         </nationalNumberPattern>
23880         <possibleNumberPattern>\d{5,7}</possibleNumberPattern>
23881         <exampleNumber>22123</exampleNumber>
23882       </fixedLine>
23883       <mobile>
23884         <nationalNumberPattern>
23885           (?:
23886             60|
23887             7[25-7]\d
23888           )\d{4}
23889         </nationalNumberPattern>
23890         <possibleNumberPattern>\d{6,7}</possibleNumberPattern>
23891         <exampleNumber>601234</exampleNumber>
23892       </mobile>
23893       <tollFree>
23894         <!-- The 800 number series is new, and is used by companies such as the ANZ bank in Samoa to
23895              provide 24 hour eMerchant support. It is marked as "Customized Services" in the plan
23896              for now, so may be also used for other purposes than toll free, but until we have
23897              further evidence of these we will keep it as toll free. -->
23898         <nationalNumberPattern>800\d{3}</nationalNumberPattern>
23899         <possibleNumberPattern>\d{6}</possibleNumberPattern>
23900         <exampleNumber>800123</exampleNumber>
23901       </tollFree>
23902       <!-- Current research suggests other types of numbers are not used in Samoa. -->
23903     </territory>
23904
23905     <!-- Yemen -->
23906     <territory id="YE" countryCode="967" internationalPrefix="00"
23907                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
23908       <references>
23909         <sourceUrl>http://www.itu.int/oth/T02020000E7/en</sourceUrl>
23910       </references>
23911       <availableFormats>
23912         <numberFormat pattern="([1-7])(\d{3})(\d{3,4})">
23913           <leadingDigits>
23914             [1-6]|
23915             7[24-68]
23916           </leadingDigits>
23917           <format>$1 $2 $3</format>
23918         </numberFormat>
23919         <numberFormat pattern="(7\d{2})(\d{3})(\d{3})">
23920           <leadingDigits>7[0137]</leadingDigits>
23921           <format>$1 $2 $3</format>
23922         </numberFormat>
23923       </availableFormats>
23924       <generalDesc>
23925         <nationalNumberPattern>[1-7]\d{6,8}</nationalNumberPattern>
23926         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
23927       </generalDesc>
23928       <fixedLine>
23929         <nationalNumberPattern>
23930           (?:
23931             1(?:
23932               7\d|
23933               [2-68]
23934             )|
23935             2[2-68]|
23936             3[2358]|
23937             4[2-58]|
23938             5[2-6]|
23939             6[3-58]|
23940             7[24-68]
23941           )\d{5}
23942         </nationalNumberPattern>
23943         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
23944         <exampleNumber>1234567</exampleNumber>
23945       </fixedLine>
23946       <mobile>
23947         <!-- Adding 70 from numbers found online. -->
23948         <nationalNumberPattern>7[0137]\d{7}</nationalNumberPattern>
23949         <possibleNumberPattern>\d{9}</possibleNumberPattern>
23950         <exampleNumber>712345678</exampleNumber>
23951       </mobile>
23952       <!-- No tollFree or premiumRate information can be found. -->
23953     </territory>
23954
23955     <!-- Mayotte -->
23956     <territory id="YT" countryCode="262" internationalPrefix="00" nationalPrefix="0"
23957                nationalPrefixFormattingRule="$NP$FG" leadingDigits="269|63">
23958       <references>
23959         <!-- Some information at the following source, but most from collection of internet data.
23960              -->
23961         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_France</sourceUrl>
23962         <!-- Verifies the fixed-line prefixes, but the mobile prefixes listed here seem out of date.
23963              -->
23964         <sourceUrl>http://www.comores-online.com/mwezinet/internet/262</sourceUrl>
23965       </references>
23966       <!-- Formatting as per La Réunion. -->
23967       <generalDesc>
23968         <nationalNumberPattern>[268]\d{8}</nationalNumberPattern>
23969         <possibleNumberPattern>\d{9}</possibleNumberPattern>
23970       </generalDesc>
23971       <fixedLine>
23972         <nationalNumberPattern>2696[0-4]\d{4}</nationalNumberPattern>
23973         <exampleNumber>269601234</exampleNumber>
23974       </fixedLine>
23975       <mobile>
23976         <nationalNumberPattern>639\d{6}</nationalNumberPattern>
23977         <exampleNumber>639123456</exampleNumber>
23978       </mobile>
23979       <!-- Same as in France. -->
23980       <tollFree>
23981         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
23982         <exampleNumber>801234567</exampleNumber>
23983       </tollFree>
23984     </territory>
23985
23986     <!-- South Africa -->
23987     <territory id="ZA" countryCode="27" internationalPrefix="00"
23988                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
23989                mobileNumberPortableRegion="true">
23990       <references>
23991         <sourceUrl>http://www.itu.int/oth/T02020000C1/en</sourceUrl>
23992         <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_South_Africa</sourceUrl>
23993       </references>
23994       <availableFormats>
23995         <numberFormat pattern="(860)(\d{3})(\d{3})">
23996           <leadingDigits>860</leadingDigits>
23997           <format>$1 $2 $3</format>
23998         </numberFormat>
23999         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
24000           <leadingDigits>
24001             [1-79]|
24002             8(?:
24003               [0-47]|
24004               6[1-9]
24005             )
24006           </leadingDigits>
24007           <format>$1 $2 $3</format>
24008         </numberFormat>
24009         <numberFormat pattern="(\d{2})(\d{3,4})">
24010           <leadingDigits>8[1-4]</leadingDigits>
24011           <format>$1 $2</format>
24012         </numberFormat>
24013         <numberFormat pattern="(\d{2})(\d{3})(\d{2,3})">
24014           <leadingDigits>8[1-4]</leadingDigits>
24015           <format>$1 $2 $3</format>
24016         </numberFormat>
24017       </availableFormats>
24018       <generalDesc>
24019         <nationalNumberPattern>
24020           [1-79]\d{8}|
24021           8(?:
24022             [067]\d{7}|
24023             [1-4]\d{3,7}
24024           )
24025         </nationalNumberPattern>
24026         <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
24027       </generalDesc>
24028       <fixedLine>
24029         <!-- Wikipedia is missing 020, and the 024 code it lists for Somerset West stopped being
24030              used in 1996. -->
24031         <nationalNumberPattern>
24032           (?:
24033             1[0-8]|
24034             2[0-378]|
24035             3[1-69]|
24036             4\d|
24037             5[1346-8]
24038           )\d{7}
24039         </nationalNumberPattern>
24040         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24041         <exampleNumber>101234567</exampleNumber>
24042       </fixedLine>
24043       <mobile>
24044         <!-- Wikipedia says 085 is for cellular: ITU says it is protected. Also note that we are
24045              still supporting numbers beginning with 8 that are fewer than 9 digits since they are
24046              in prominent places online, even though the ITU document says numbers must be 10 digits
24047              long (including the national prefix). -->
24048         <nationalNumberPattern>
24049           (?:
24050             6[0-5]|
24051             7[0-46-9]
24052           )\d{7}|
24053           8[1-4]\d{3,7}
24054         </nationalNumberPattern>
24055         <exampleNumber>711234567</exampleNumber>
24056       </mobile>
24057       <tollFree>
24058         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
24059         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24060         <exampleNumber>801234567</exampleNumber>
24061       </tollFree>
24062       <premiumRate>
24063         <nationalNumberPattern>
24064           86[2-9]\d{6}|
24065           90\d{7}
24066         </nationalNumberPattern>
24067         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24068         <exampleNumber>862345678</exampleNumber>
24069       </premiumRate>
24070       <sharedCost>
24071         <nationalNumberPattern>860\d{6}</nationalNumberPattern>
24072         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24073         <exampleNumber>860123456</exampleNumber>
24074       </sharedCost>
24075       <voip>
24076         <nationalNumberPattern>87\d{7}</nationalNumberPattern>
24077         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24078         <exampleNumber>871234567</exampleNumber>
24079       </voip>
24080       <uan>
24081         <!-- MaxiCall numbers cost as much as national long distance, so they are classified as UAN
24082              numbers. -->
24083         <nationalNumberPattern>861\d{6}</nationalNumberPattern>
24084         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24085         <exampleNumber>861123456</exampleNumber>
24086       </uan>
24087     </territory>
24088
24089     <!-- Zambia -->
24090     <territory id="ZM" countryCode="260" internationalPrefix="00"
24091                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
24092       <references>
24093         <sourceUrl>http://www.itu.int/oth/T02020000E8/en</sourceUrl>
24094       </references>
24095       <availableFormats>
24096         <numberFormat pattern="([29]\d)(\d{7})">
24097           <leadingDigits>[29]</leadingDigits>
24098           <format>$1 $2</format>
24099         </numberFormat>
24100         <numberFormat pattern="(800)(\d{3})(\d{3})">
24101           <leadingDigits>8</leadingDigits>
24102           <format>$1 $2 $3</format>
24103         </numberFormat>
24104       </availableFormats>
24105       <generalDesc>
24106         <nationalNumberPattern>[289]\d{8}</nationalNumberPattern>
24107         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24108       </generalDesc>
24109       <fixedLine>
24110         <nationalNumberPattern>21[1-8]\d{6}</nationalNumberPattern>
24111         <exampleNumber>211234567</exampleNumber>
24112       </fixedLine>
24113       <mobile>
24114         <!-- Adding extra prefixes 50 and 6[1-57-9] since SMS messages have been successfully
24115              delivered to these numbers, and numbers like this can be found on the Internet. Adding
24116              prefix 960 based on information received from MTN Zambia. The 97 range has been
24117              expanded based on their IR21 document, which states the range 97[1-9] is used. -->
24118         <nationalNumberPattern>
24119           9(?:
24120             5[05]|
24121             6\d|
24122             7[1-9]
24123           )\d{6}
24124         </nationalNumberPattern>
24125         <exampleNumber>955123456</exampleNumber>
24126       </mobile>
24127       <tollFree>
24128         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
24129         <exampleNumber>800123456</exampleNumber>
24130       </tollFree>
24131     </territory>
24132
24133     <!-- Zimbabwe -->
24134     <territory id="ZW" countryCode="263" internationalPrefix="00"
24135                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
24136       <references>
24137         <sourceUrl>http://www.itu.int/oth/T02020000E9/en</sourceUrl>
24138       </references>
24139       <availableFormats>
24140         <!-- One-digit area codes -->
24141         <numberFormat pattern="([49])(\d{3})(\d{2,5})">
24142           <leadingDigits>
24143             4|
24144             9[2-9]
24145           </leadingDigits>
24146           <format>$1 $2 $3</format>
24147         </numberFormat>
24148         <!-- Mobile numbers -->
24149         <numberFormat pattern="([179]\d)(\d{3})(\d{3,4})">
24150           <leadingDigits>
24151             [19]1|
24152             7
24153           </leadingDigits>
24154           <format>$1 $2 $3</format>
24155         </numberFormat>
24156         <numberFormat pattern="(86\d{2})(\d{3})(\d{3})">
24157           <leadingDigits>86[24]</leadingDigits>
24158           <format>$1 $2 $3</format>
24159         </numberFormat>
24160         <!-- Three-digit area codes (listed before the two-digit ones since some overlap) -->
24161         <numberFormat pattern="([2356]\d{2})(\d{3,5})">
24162           <leadingDigits>
24163             2(?:
24164               [278]|
24165               0[45]|
24166               [49]8
24167             )|
24168             3(?:
24169               08|
24170               17|
24171               3[78]|
24172               [78]
24173             )|
24174             5[15][78]|
24175             6(?:
24176               [29]8|
24177               37|
24178               [68][78]
24179             )
24180           </leadingDigits>
24181           <format>$1 $2</format>
24182         </numberFormat>
24183         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
24184           <leadingDigits>
24185             2(?:
24186               [278]|
24187               0[45]|
24188               48
24189             )|
24190             3(?:
24191               08|
24192               17|
24193               3[78]|
24194               [78]
24195             )|
24196             5[15][78]|
24197             6(?:
24198               [29]8|
24199               37|
24200               [68][78]
24201             )|
24202             80
24203           </leadingDigits>
24204           <format>$1 $2 $3</format>
24205         </numberFormat>
24206         <!-- Two-digit area codes -->
24207         <numberFormat pattern="([1-356]\d)(\d{3,5})">
24208           <leadingDigits>
24209             1[3-9]|
24210             2(?:
24211               [1-469]|
24212               0[0-35-9]|
24213               [45][0-79]
24214             )|
24215             3(?:
24216               0[0-79]|
24217               1[0-689]|
24218               [24-69]|
24219               3[0-69]
24220             )|
24221             5(?:
24222               [02-46-9]|
24223               [15][0-69]
24224             )|
24225             6(?:
24226               [0145]|
24227               [29][0-79]|
24228               3[0-689]|
24229               [68][0-69]
24230             )
24231           </leadingDigits>
24232           <format>$1 $2</format>
24233         </numberFormat>
24234         <numberFormat pattern="([1-356]\d)(\d{3})(\d{3})">
24235           <leadingDigits>
24236             1[3-9]|
24237             2(?:
24238               [1-469]|
24239               0[0-35-9]|
24240               [45][0-79]
24241             )|
24242             3(?:
24243               0[0-79]|
24244               1[0-689]|
24245               [24-69]|
24246               3[0-69]
24247             )|
24248             5(?:
24249               [02-46-9]|
24250               [15][0-69]
24251             )|
24252             6(?:
24253               [0145]|
24254               [29][0-79]|
24255               3[0-689]|
24256               [68][0-69]
24257             )
24258           </leadingDigits>
24259           <format>$1 $2 $3</format>
24260         </numberFormat>
24261         <!-- Four-digit area codes -->
24262         <numberFormat pattern="([25]\d{3})(\d{3,5})">
24263           <leadingDigits>
24264             (?:
24265               25|
24266               54
24267             )8
24268           </leadingDigits>
24269           <leadingDigits>
24270             258[23]|
24271             5483
24272           </leadingDigits>
24273           <format>$1 $2</format>
24274         </numberFormat>
24275         <numberFormat pattern="([25]\d{3})(\d{3})(\d{3})">
24276           <leadingDigits>
24277             (?:
24278               25|
24279               54
24280             )8
24281           </leadingDigits>
24282           <leadingDigits>
24283             258[23]|
24284             5483
24285           </leadingDigits>
24286           <format>$1 $2 $3</format>
24287         </numberFormat>
24288         <!-- VOIP numbers -->
24289         <numberFormat pattern="(8\d{3})(\d{6})">
24290           <leadingDigits>86</leadingDigits>
24291           <format>$1 $2</format>
24292         </numberFormat>
24293       </availableFormats>
24294       <generalDesc>
24295         <!-- A complicated nationalNumberPattern is necessary here, since the numbers are extremely
24296              variable in length and the possible prefixes clash with the country code. -->
24297         <nationalNumberPattern>
24298           2(?:
24299             [012457-9]\d{3,8}|
24300             6\d{3,6}
24301           )|
24302           [13-79]\d{4,8}|
24303           8[06]\d{8}
24304         </nationalNumberPattern>
24305         <possibleNumberPattern>\d{3,10}</possibleNumberPattern>
24306       </generalDesc>
24307       <fixedLine>
24308         <!-- Numbering is grouped by subscriber-number length. -->
24309         <nationalNumberPattern>
24310           (?:
24311             1[3-9]|
24312             2(?:
24313               0[45]|
24314               [16]|
24315               2[28]|
24316               [49]8?|
24317               58[23]|
24318               7[246]|
24319               8[1346-9]
24320             )|
24321             3(?:
24322               08?|
24323               17?|
24324               3[78]|
24325               [2456]|
24326               7[1569]|
24327               8[379]
24328             )|
24329             5(?:
24330               [07-9]|
24331               1[78]|
24332               483|
24333               5(?:
24334                 7?|
24335                 8
24336               )
24337             )|
24338             6(?:
24339               0|
24340               28|
24341               37?|
24342               [45][68][78]|
24343               98?
24344             )|
24345             848
24346           )\d{3,6}|
24347           (?:
24348             2(?:
24349               27|
24350               5|
24351               7[135789]|
24352               8[25]
24353             )|
24354             3[39]|
24355             5[1-46]|
24356             6[126-8]
24357           )\d{4,6}|
24358           2(?:
24359             (?:
24360               0|
24361               70
24362             )\d{5,6}|
24363             2[05]\d{7}
24364           )|
24365           (?:
24366             4\d|
24367             9[2-8]
24368           )\d{4,7}
24369         </nationalNumberPattern>
24370         <exampleNumber>1312345</exampleNumber>
24371       </fixedLine>
24372       <!-- The ITU document list 8622 and 8644 as VoIP, but an online search reveals that they are
24373            also being used by the carriers as mobile prefixes. -->
24374       <mobile>
24375         <nationalNumberPattern>
24376           7[1378]\d{7}|
24377           86(?:
24378             22|
24379             44
24380           )\d{6}
24381         </nationalNumberPattern>
24382         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
24383         <exampleNumber>711234567</exampleNumber>
24384       </mobile>
24385       <tollFree>
24386         <nationalNumberPattern>800\d{7}</nationalNumberPattern>
24387         <possibleNumberPattern>\d{10}</possibleNumberPattern>
24388         <exampleNumber>8001234567</exampleNumber>
24389       </tollFree>
24390       <!-- No premiumRate information can be found. -->
24391       <voip>
24392         <nationalNumberPattern>
24393           86(?:
24394             1[12]|
24395             30|
24396             55|
24397             77|
24398             8[367]|
24399             99
24400           )\d{6}
24401         </nationalNumberPattern>
24402         <possibleNumberPattern>\d{10}</possibleNumberPattern>
24403         <exampleNumber>8686123456</exampleNumber>
24404       </voip>
24405     </territory>
24406
24407     <!-- Universal International Toll Free Number -->
24408     <territory id="001" countryCode="800" leadingZeroPossible="true">
24409       <references>
24410         <sourceUrl>http://www.itu.int/en/ITU-T/inr/unum/Pages/uifn.aspx</sourceUrl>
24411       </references>
24412       <availableFormats>
24413         <numberFormat pattern="(\d{4})(\d{4})">
24414           <format>$1 $2</format>
24415         </numberFormat>
24416       </availableFormats>
24417       <generalDesc>
24418         <nationalNumberPattern>\d{8}</nationalNumberPattern>
24419         <possibleNumberPattern>\d{8}</possibleNumberPattern>
24420         <exampleNumber>12345678</exampleNumber>
24421       </generalDesc>
24422       <fixedLine>
24423         <nationalNumberPattern>NA</nationalNumberPattern>
24424         <possibleNumberPattern>NA</possibleNumberPattern>
24425       </fixedLine>
24426       <mobile>
24427         <nationalNumberPattern>NA</nationalNumberPattern>
24428         <possibleNumberPattern>NA</possibleNumberPattern>
24429       </mobile>
24430       <tollFree>
24431         <nationalNumberPattern>\d{8}</nationalNumberPattern>
24432       </tollFree>
24433     </territory>
24434
24435     <!-- Universal International Shared Cost Number -->
24436     <territory id="001" countryCode="808" leadingZeroPossible="true">
24437       <references>
24438         <sourceUrl>http://www.itu.int/rec/T-REC-E.169-200205-I/en</sourceUrl>
24439       </references>
24440       <availableFormats>
24441         <numberFormat pattern="(\d{4})(\d{4})">
24442           <format>$1 $2</format>
24443         </numberFormat>
24444       </availableFormats>
24445       <generalDesc>
24446         <nationalNumberPattern>\d{8}</nationalNumberPattern>
24447         <possibleNumberPattern>\d{8}</possibleNumberPattern>
24448         <exampleNumber>12345678</exampleNumber>
24449       </generalDesc>
24450       <fixedLine>
24451         <nationalNumberPattern>NA</nationalNumberPattern>
24452         <possibleNumberPattern>NA</possibleNumberPattern>
24453       </fixedLine>
24454       <mobile>
24455         <nationalNumberPattern>NA</nationalNumberPattern>
24456         <possibleNumberPattern>NA</possibleNumberPattern>
24457       </mobile>
24458       <sharedCost>
24459         <nationalNumberPattern>\d{8}</nationalNumberPattern>
24460       </sharedCost>
24461     </territory>
24462
24463     <!-- Inmarsat Global Limited -->
24464     <territory id="001" countryCode="870">
24465       <references>
24466         <sourceUrl>http://www.itu.int/oth/T0202000065/en</sourceUrl>
24467         <sourceUrl>http://www.inmarsat.com</sourceUrl>
24468       </references>
24469       <availableFormats>
24470         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
24471           <format>$1 $2 $3</format>
24472         </numberFormat>
24473       </availableFormats>
24474       <generalDesc>
24475         <nationalNumberPattern>[35-7]\d{8}</nationalNumberPattern>
24476         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24477         <exampleNumber>301234567</exampleNumber>
24478       </generalDesc>
24479       <fixedLine>
24480         <nationalNumberPattern>NA</nationalNumberPattern>
24481         <possibleNumberPattern>NA</possibleNumberPattern>
24482       </fixedLine>
24483       <mobile>
24484         <!-- Assigning these to mobile since Inmarsat considers them to be mobile numbers. -->
24485         <nationalNumberPattern>
24486           (?:
24487             [356]\d|
24488             7[6-8]
24489           )\d{7}
24490         </nationalNumberPattern>
24491       </mobile>
24492     </territory>
24493
24494     <!-- VISIONng -->
24495     <!-- Number length has been derived from examples found online. -->
24496     <territory id="001" countryCode="878">
24497       <references>
24498         <sourceUrl>http://www.itu.int/oth/T02020000E5/en</sourceUrl>
24499       </references>
24500       <availableFormats>
24501         <!-- Formatting chosen based on online examples. -->
24502         <numberFormat pattern="(\d{2})(\d{5})(\d{5})">
24503           <format>$1 $2 $3</format>
24504         </numberFormat>
24505       </availableFormats>
24506       <generalDesc>
24507         <nationalNumberPattern>1\d{11}</nationalNumberPattern>
24508         <possibleNumberPattern>\d{12}</possibleNumberPattern>
24509         <exampleNumber>101234567890</exampleNumber>
24510       </generalDesc>
24511       <fixedLine>
24512         <nationalNumberPattern>NA</nationalNumberPattern>
24513         <possibleNumberPattern>NA</possibleNumberPattern>
24514       </fixedLine>
24515       <mobile>
24516         <nationalNumberPattern>NA</nationalNumberPattern>
24517         <possibleNumberPattern>NA</possibleNumberPattern>
24518       </mobile>
24519       <voip>
24520         <nationalNumberPattern>10\d{10}</nationalNumberPattern>
24521       </voip>
24522     </territory>
24523
24524     <!-- Iridium -->
24525     <!-- Globalstar also reports using this prefix, but we cannot find any online numbers with the
24526          Globalstar prefixes, so are not sure how exactly these work, and what length the numbers
24527          are. For this reason, we only support Iridium numbers at the moment. -->
24528     <territory id="001" countryCode="881">
24529       <references>
24530         <sourceUrl>http://www.iridium.com</sourceUrl>
24531         <sourceUrl>http://www.itu.int/oth/T0202000069/en</sourceUrl>
24532       </references>
24533       <availableFormats>
24534         <!-- Formatting chosen based on ITU document and Iridium website FAQ. -->
24535         <numberFormat pattern="(\d)(\d{3})(\d{5})">
24536           <leadingDigits>[67]</leadingDigits>
24537           <format>$1 $2 $3</format>
24538         </numberFormat>
24539       </availableFormats>
24540       <generalDesc>
24541         <nationalNumberPattern>[67]\d{8}</nationalNumberPattern>
24542         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24543         <exampleNumber>612345678</exampleNumber>
24544       </generalDesc>
24545       <fixedLine>
24546         <nationalNumberPattern>NA</nationalNumberPattern>
24547         <possibleNumberPattern>NA</possibleNumberPattern>
24548       </fixedLine>
24549       <mobile>
24550         <nationalNumberPattern>[67]\d{8}</nationalNumberPattern>
24551       </mobile>
24552     </territory>
24553
24554     <territory id="001" countryCode="882">
24555       <references>
24556         <!-- BebbiCell (Formerly Global Networks Switzerland AG) +88234 -->
24557         <sourceUrl>http://www.itu.int/oth/T0202000054/en</sourceUrl>
24558         <sourceUrl>http://www.gsm.aq/numberplan.php</sourceUrl>
24559         <sourceUrl>http://www.global.aq</sourceUrl>
24560         <!-- Maritime Communications Partner (MCP) +88232 -->
24561         <sourceUrl>http://www.itu.int/oth/T02020000F4/en</sourceUrl>
24562         <!-- Oration Technologies +88237 -->
24563         <sourceUrl>http://www.itu.int/oth/T02020000A0/en</sourceUrl>
24564         <!-- Telespazio S.p.A. +88213 -->
24565         <sourceUrl>http://www.itu.int/oth/T02020000CC/en</sourceUrl>
24566         <!-- Thuraya +88216 -->
24567         <sourceUrl>http://www.itu.int/oth/T02020000CF/en</sourceUrl>
24568       </references>
24569       <availableFormats>
24570         <numberFormat pattern="(\d{2})(\d{4})(\d{3})">
24571           <leadingDigits>3[23]</leadingDigits>
24572           <format>$1 $2 $3</format>
24573         </numberFormat>
24574         <numberFormat pattern="(\d{2})(\d{5})">
24575           <leadingDigits>
24576             16|
24577             342
24578           </leadingDigits>
24579           <format>$1 $2</format>
24580         </numberFormat>
24581         <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
24582           <leadingDigits>34[57]</leadingDigits>
24583           <format>$1 $2 $3</format>
24584         </numberFormat>
24585         <numberFormat pattern="(\d{3})(\d{4})(\d{4})">
24586           <leadingDigits>348</leadingDigits>
24587           <format>$1 $2 $3</format>
24588         </numberFormat>
24589         <numberFormat pattern="(\d{2})(\d{2})(\d{4})">
24590           <leadingDigits>1</leadingDigits>
24591           <format>$1 $2 $3</format>
24592         </numberFormat>
24593         <numberFormat pattern="(\d{2})(\d{3,4})(\d{4})">
24594           <leadingDigits>16</leadingDigits>
24595           <format>$1 $2 $3</format>
24596         </numberFormat>
24597         <numberFormat pattern="(\d{2})(\d{4,5})(\d{5})">
24598           <leadingDigits>16</leadingDigits>
24599           <format>$1 $2 $3</format>
24600         </numberFormat>
24601       </availableFormats>
24602       <generalDesc>
24603         <nationalNumberPattern>[13]\d{6,11}</nationalNumberPattern>
24604         <possibleNumberPattern>\d{7,12}</possibleNumberPattern>
24605         <exampleNumber>3451234567</exampleNumber>
24606       </generalDesc>
24607       <fixedLine>
24608         <nationalNumberPattern>NA</nationalNumberPattern>
24609         <possibleNumberPattern>NA</possibleNumberPattern>
24610       </fixedLine>
24611       <mobile>
24612         <!-- Bebbicell Mobile numbers, MCP & Oration. We are guessing the number length for
24613              Oration based on numbers found online. -->
24614         <nationalNumberPattern>
24615           3(?:
24616             2\d{3}|
24617             37\d{2}|
24618             4(?:
24619               2|
24620               7\d{3}
24621             )
24622           )\d{4}
24623         </nationalNumberPattern>
24624         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
24625       </mobile>
24626       <voip>
24627         <!-- Telespazio S.p.A., Thuraya and Bebbicell VOIP numbers. -->
24628         <nationalNumberPattern>
24629           1(?:
24630             3(?:
24631               0[0347]|
24632               [13][0139]|
24633               2[035]|
24634               4[013568]|
24635               6[0459]|
24636               7[06]|
24637               8[15678]|
24638               9[0689]
24639             )\d{4}|
24640             6\d{5,10}
24641           )|
24642           345\d{7}
24643         </nationalNumberPattern>
24644         <possibleNumberPattern>\d{7,12}</possibleNumberPattern>
24645       </voip>
24646       <voicemail>
24647         <nationalNumberPattern>348[57]\d{7}</nationalNumberPattern>
24648         <possibleNumberPattern>\d{11}</possibleNumberPattern>
24649       </voicemail>
24650     </territory>
24651
24652     <territory id="001" countryCode="883">
24653       <references>
24654         <!-- bandwidth.com -->
24655         <sourceUrl>http://www.itu.int/oth/T02020000FB/en</sourceUrl>
24656         <!-- SipMe -->
24657         <sourceUrl>http://www.itu.int/oth/T02020000FC/en</sourceUrl>
24658         <!-- Voxbone -->
24659         <sourceUrl>http://www.itu.int/oth/T02020000F3/en</sourceUrl>
24660       </references>
24661       <availableFormats>
24662         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
24663           <leadingDigits>510</leadingDigits>
24664           <format>$1 $2 $3</format>
24665         </numberFormat>
24666         <numberFormat pattern="(\d{3})(\d{3})(\d{3})(\d{3})">
24667           <leadingDigits>510</leadingDigits>
24668           <format>$1 $2 $3 $4</format>
24669         </numberFormat>
24670         <!-- When only 8 digits follow the "area code" formatting as XXXX XXXX
24671              seems preferred (see Bandwidth.com and SipMe). -->
24672         <numberFormat pattern="(\d{4})(\d{4})(\d{4})">
24673           <leadingDigits>51[13]</leadingDigits>
24674           <format>$1 $2 $3</format>
24675         </numberFormat>
24676       </availableFormats>
24677       <generalDesc>
24678         <!-- Wikipedia also listed a few other +883 ranges, but no information on their lengths and
24679              costs can be found online, so we don't include them here for now. -->
24680         <nationalNumberPattern>51\d{7}(?:\d{3})?</nationalNumberPattern>
24681         <possibleNumberPattern>\d{9}(?:\d{3})?</possibleNumberPattern>
24682         <exampleNumber>510012345</exampleNumber>
24683       </generalDesc>
24684       <fixedLine>
24685         <nationalNumberPattern>NA</nationalNumberPattern>
24686         <possibleNumberPattern>NA</possibleNumberPattern>
24687       </fixedLine>
24688       <mobile>
24689         <nationalNumberPattern>NA</nationalNumberPattern>
24690         <possibleNumberPattern>NA</possibleNumberPattern>
24691       </mobile>
24692       <voip>
24693         <nationalNumberPattern>
24694           51(?:
24695             00\d{5}(?:\d{3})?|
24696             [13]0\d{8}
24697           )
24698         </nationalNumberPattern>
24699       </voip>
24700     </territory>
24701
24702     <!-- United Nations- OCHA -->
24703     <!-- Numbers here are classified as UAN, as they are non-geographical and universally
24704          accessible. In addition, the end-user tariff to reach these numbers is lower or similar to
24705          the tariff of a national call. -->
24706     <territory id="001" countryCode="888" leadingZeroPossible="true">
24707       <references>
24708         <sourceUrl>http://www.itu.int/oth/T02020000FA/en</sourceUrl>
24709       </references>
24710       <availableFormats>
24711         <numberFormat pattern="(\d{3})(\d{3})(\d{5})">
24712           <format>$1 $2 $3</format>
24713         </numberFormat>
24714       </availableFormats>
24715       <generalDesc>
24716         <nationalNumberPattern>\d{11}</nationalNumberPattern>
24717         <possibleNumberPattern>\d{11}</possibleNumberPattern>
24718         <exampleNumber>12345678901</exampleNumber>
24719       </generalDesc>
24720       <fixedLine>
24721         <nationalNumberPattern>NA</nationalNumberPattern>
24722         <possibleNumberPattern>NA</possibleNumberPattern>
24723       </fixedLine>
24724       <mobile>
24725         <nationalNumberPattern>NA</nationalNumberPattern>
24726         <possibleNumberPattern>NA</possibleNumberPattern>
24727       </mobile>
24728       <uan>
24729         <nationalNumberPattern>\d{11}</nationalNumberPattern>
24730       </uan>
24731     </territory>
24732
24733     <!-- Universal International Premium Rate Number -->
24734     <territory id="001" countryCode="979" leadingZeroPossible="true">
24735       <references>
24736         <sourceUrl>http://www.itu.int/rec/T-REC-E.169-200205-I/en</sourceUrl>
24737       </references>
24738       <availableFormats>
24739         <numberFormat pattern="(\d)(\d{4})(\d{4})">
24740           <format>$1 $2 $3</format>
24741         </numberFormat>
24742       </availableFormats>
24743       <generalDesc>
24744         <nationalNumberPattern>\d{9}</nationalNumberPattern>
24745         <possibleNumberPattern>\d{9}</possibleNumberPattern>
24746         <exampleNumber>123456789</exampleNumber>
24747       </generalDesc>
24748       <fixedLine>
24749         <nationalNumberPattern>NA</nationalNumberPattern>
24750         <possibleNumberPattern>NA</possibleNumberPattern>
24751       </fixedLine>
24752       <mobile>
24753         <nationalNumberPattern>NA</nationalNumberPattern>
24754         <possibleNumberPattern>NA</possibleNumberPattern>
24755       </mobile>
24756       <premiumRate>
24757         <nationalNumberPattern>\d{9}</nationalNumberPattern>
24758       </premiumRate>
24759     </territory>
24760   </territories>
24761 </phoneNumberMetadata>