JAVA/JS/CPP: v7.0.2 metadata updates.
[platform/upstream/libphonenumber.git] / resources / PhoneNumberMetadata.xml
index 6534260..40f569f 100644 (file)
@@ -13,7 +13,6 @@
      limitations under the License.
 
      @author: Shaopeng Jia
-     @author: Lara Rennie
 
      Metadata on Phone Number Plan and formatting rules
      Note: Territories are in alphabetical order by their IDs, which are based on ISO 3166-1
 
      Country code, international and national prefix information main source:
      http://www.itu.int/pub/T-SP-E.164C-2011
-
-     Emergency numbers Wikipedia source:
-     http://en.wikipedia.org/wiki/Emergency_telephone_number
 -->
 
 <!DOCTYPE phoneNumberMetadata [
     <!ELEMENT phoneNumberMetadata (territories)>
     <!ELEMENT territories (territory+)>
-    <!ELEMENT territory (availableFormats?, generalDesc?, noInternationalDialling?,
+    <!ELEMENT territory (references?, availableFormats?, generalDesc?, noInternationalDialling?,
         areaCodeOptional?, fixedLine?, mobile?, pager?, tollFree?, premiumRate?,
-        sharedCost?, personalNumber?, voip?, uan?, voicemail?, emergency?)>
+        sharedCost?, personalNumber?, voip?, uan?, voicemail?)>
+    <!ELEMENT references (sourceUrl+)>
     <!ELEMENT generalDesc (nationalNumberPattern, possibleNumberPattern, exampleNumber?)>
     <!ELEMENT noInternationalDialling (nationalNumberPattern, possibleNumberPattern?,
         exampleNumber?)>
@@ -60,7 +57,7 @@
     <!ELEMENT voip (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
     <!ELEMENT uan (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
     <!ELEMENT voicemail (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
-    <!ELEMENT emergency (nationalNumberPattern?, possibleNumberPattern?, exampleNumber?)>
+    <!ELEMENT sourceUrl (#PCDATA)>
     <!ELEMENT availableFormats (numberFormat+)>
     <!ELEMENT nationalNumberPattern (#PCDATA)>
     <!ELEMENT possibleNumberPattern (#PCDATA)>
@@ -84,6 +81,7 @@
     <!ATTLIST territory nationalPrefixOptionalWhenFormatting (true) #IMPLIED>
     <!ATTLIST territory leadingZeroPossible (true) #IMPLIED>
     <!ATTLIST territory carrierCodeFormattingRule CDATA #IMPLIED>
+    <!ATTLIST territory mobileNumberPortableRegion (true) #IMPLIED>
     <!ATTLIST numberFormat nationalPrefixFormattingRule CDATA #IMPLIED>
     <!ATTLIST numberFormat nationalPrefixOptionalWhenFormatting (true) #IMPLIED>
     <!ATTLIST numberFormat carrierCodeFormattingRule CDATA #IMPLIED>
 <phoneNumberMetadata>
   <territories>
     <!-- Ascension Island -->
-    <!-- www.itu.int/oth/T02020000AF -->
     <territory id="AC" countryCode="247" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000AF/en</sourceUrl>
+      </references>
       <!-- Formatted as a block. -->
       <generalDesc>
-        <nationalNumberPattern>[2-467]\d{3}</nationalNumberPattern>
-        <possibleNumberPattern>\d{4}</possibleNumberPattern>
+        <nationalNumberPattern>[2-7]\d{3,5}</nationalNumberPattern>
+        <possibleNumberPattern>\d{4,6}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
         <nationalNumberPattern>
         <exampleNumber>6889</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>NA</nationalNumberPattern>
-        <possibleNumberPattern>NA</possibleNumberPattern>
+        <nationalNumberPattern>5\d{5}</nationalNumberPattern>
+        <possibleNumberPattern>\d{6}</possibleNumberPattern>
+        <exampleNumber>501234</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf
-             http://www.noonsite.com/Countries/AscensionIsland/?rc=GeneralInfo
-             Note the 4-digit emergency numbers fit the fixed-line pattern, therefore are not
-             included. This is consistent with how we handle such numbers in other countries. -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Andorra -->
-    <!-- http://www.itu.int/oth/T0202000005/en -->
     <territory id="AD" countryCode="376" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000005/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})">
           <leadingDigits>[346-9]</leadingDigits>
       </mobile>
       <tollFree>
         <!-- Note that the definitions of 1800 and 1802 numbers differ in the plan and on the
-             Andorran www.sta.ad website, but we consider both to be freephone here. -->
+             Andorran http://www.sta.ad website, but we consider both to be freephone here. -->
         <nationalNumberPattern>180[02]\d{4}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>18001234</exampleNumber>
         <possibleNumberPattern>\d{6}</possibleNumberPattern>
         <exampleNumber>912345</exampleNumber>
       </premiumRate>
-      <emergency>
-      <!-- http://www.fco.gov.uk/en/travel-and-living-abroad/travel-advice-by-country/europe/andorra
-           -->
-        <nationalNumberPattern>11[0268]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
-    <!--  United Arab Emirates -->
-    <!-- http://www.itu.int/oth/T02020000DC/en -->
+    <!-- United Arab Emirates -->
     <territory id="AE" countryCode="971" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000DC/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([2-4679])(\d{3})(\d{4})">
           <leadingDigits>[2-4679][2-8]</leadingDigits>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>600212345</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          99[789]
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Afghanistan -->
-    <!-- http://www.itu.int/oth/T0202000001/en -->
     <territory id="AF" countryCode="93" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000001/en</sourceUrl>
+      </references>
       <availableFormats>
+        <!-- Formatting based primarily on ITU document. -->
         <numberFormat pattern="([2-7]\d)(\d{3})(\d{4})">
+          <leadingDigits>
+            [2-6]|
+            7[013-9]
+          </leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
+        <!-- Formatting 729 numbers differently based on numbers seen online. -->
+        <numberFormat pattern="(729)(\d{3})(\d{3})">
+          <leadingDigits>729</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
       </availableFormats>
         <exampleNumber>234567890</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>7[057-9]\d{7}</nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
-        <exampleNumber>701234567</exampleNumber>
-      </mobile>
-      <emergency>
         <nationalNumberPattern>
-          1(?:
-            02|
-            19
+          7(?:
+            [05-9]\d{7}|
+            29\d{6}
           )
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>119</exampleNumber>
-      </emergency>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <exampleNumber>701234567</exampleNumber>
+      </mobile>
     </territory>
 
     <!-- Antigua and Barbuda -->
-    <!-- http://www.itu.int/oth/T0202000008/en -->
     <territory id="AG" countryCode="1" leadingDigits="268" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000008/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>2684801234</exampleNumber>
       </voip>
-      <emergency>
-        <!-- http://barbados.usembassy.gov/emergency-antigua_barbuda.html -->
-        <nationalNumberPattern>
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Anguilla -->
-    <!-- http://www.itu.int/oth/T0202000007/en -->
     <territory id="AI" countryCode="1" leadingDigits="264" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000007/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://barbados.usembassy.gov/emergency-anguilla.html -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Albania -->
-    <!-- http://www.itu.int/oth/T0202000002/en -->
     <territory id="AL" countryCode="355" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000002/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formats mostly follow http://tirana.usembassy.gov/list_of_doctors.html -->
         <numberFormat pattern="(4)(\d{3})(\d{4})">
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>70012345</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>12[789]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>129</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Armenia -->
-    <!-- http://www.itu.int/oth/T020200000A/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B374 -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Nagorno-Karabakh_Republic -->
     <!-- We think the national dialling prefix is 0 - it seems this was a change in 2005 (or 2008)
          along with the new city codes. However, their official document makes no mention of it,
          websites disagree, and we are not sure if the change has actually been made. -->
     <territory id="AM" countryCode="374" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
+               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
+               mobileNumberPortableRegion="true" >
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200000A/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B374</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Nagorno-Karabakh_Republic</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{6})">
           <leadingDigits>
         </numberFormat>
         <numberFormat pattern="(\d{2})(\d{6})" nationalPrefixFormattingRule="$NP$FG">
           <leadingDigits>
+            4[139]|
             [5-7]|
             9[1-9]
           </leadingDigits>
         <!-- Part of the range 97 is used by Nagorno-Karabakh Republic. -->
         <nationalNumberPattern>
           (?:
+            4[139]|
             55|
             77|
             9[1-9]
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>60271234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>10[123]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>102</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Angola -->
-    <!-- http://www.itu.int/oth/T0202000006/en -->
     <territory id="AO" countryCode="244" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000006/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
           <format>$1 $2 $3</format>
         <exampleNumber>222123456</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Expanded the 92 prefix possibilities to match numbers found online. Unitel are
-             launching the prefix 94 apparently on 25th April 2012. -->
-        <nationalNumberPattern>9[1-4]\d{7}</nationalNumberPattern>
+        <!-- Expanded the 92 prefix possibilities to match numbers found online. Unitel
+             apparently launched the prefix 94 on 25th April 2012, and Movicel has 99. -->
+        <nationalNumberPattern>9[1-49]\d{7}</nationalNumberPattern>
         <exampleNumber>923123456</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1096.html -->
-        <nationalNumberPattern>11[235]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>113</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Argentina -->
-    <!-- http://www.itu.int/oth/T0202000009/en -->
-    <!-- http://www.cnc.gov.ar/infotecnica/numeracion/Index.asp - click on Indicativos Interurbanos.
+    <!-- The national prefix for parsing here consists of a 0 (optional), followed by the area code
+         (which is captured, so that it can be retained), followed by 15, which is the mobile token,
+         which will be stripped if present. We expect the following combinations: 0AC15 and AC15
+         (where the 0 and 15 will be stripped, and it will be transformed into 9AC), 0, and 15 (in
+         the latter two cases we just strip the 0 or 15 as appropriate and leave the number as is.)
          -->
     <territory id="AR" countryCode="54" internationalPrefix="00" nationalPrefix="0"
        nationalPrefixForParsing="
                9[124]
              )
            )
-         )15
+         )?15
        )?"
-       nationalPrefixTransformRule="9$1" nationalPrefixFormattingRule="$NP$FG">
+       nationalPrefixTransformRule="9$1" nationalPrefixFormattingRule="$NP$FG"
+       mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000009/en</sourceUrl>
+        <!-- On the following link, click on Indicativos Interurbanos to access detailed
+             information. -->
+        <sourceUrl>http://www.cnc.gov.ar/infotecnica/numeracion/Index.asp</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+54</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([68]\d{2})(\d{3})(\d{4})">
           <leadingDigits>[68]</leadingDigits>
           <format>$1-$2-$3</format>
         </numberFormat>
+        <!-- Format local numbers in two groups. The leading digits are 2-9 since the ITU document
+             says that the digit zero and one will not be present at the start of the subscriber
+             number (which starts with an "Exchange characteristic"). -->
+        <numberFormat pattern="(\d{2})(\d{4})" nationalPrefixFormattingRule="$FG">
+          <leadingDigits>[2-9]</leadingDigits>
+          <format>$1-$2</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
+        <numberFormat pattern="(\d{3})(\d{4})" nationalPrefixFormattingRule="$FG">
+          <leadingDigits>[2-9]</leadingDigits>
+          <format>$1-$2</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
+        <numberFormat pattern="(\d{4})(\d{4})" nationalPrefixFormattingRule="$FG">
+          <leadingDigits>[2-9]</leadingDigits>
+          <format>$1-$2</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
         <numberFormat pattern="(9)(11)(\d{4})(\d{4})">
           <leadingDigits>911</leadingDigits>
           <format>$2 15-$3-$4</format>
         </numberFormat>
         <numberFormat pattern="(9)(\d{3})(\d{3})(\d{4})">
           <!-- Some 4-digit area codes actually are caught by this rule. Preference is given however
-               to the 3-digit area codes, since they are considerably larger communities.  -->
+               to the 3-digit area codes, since they are considerably larger communities. -->
           <leadingDigits>
             9(?:
               2[234689]|
               )
             )
           </leadingDigits>
-          <!-- We exclude here several 294X four-digit area codes: 2940, 2942, 2945, 2946 and 2948 -
-               and several 38[3578]X four-digit area codes. -->
+          <!-- We exclude here several 294X four-digit area codes: 2940, 2942, 2945, 2946 and 2948,
+               298[23], and several 38[3578]X four-digit area codes. -->
           <leadingDigits>
             9(?:
               2(?:
                 6[01346]|
                 80|
                 9(?:
-                  [17-9]|
-                  4[13479]
+                  [179]|
+                  4[13479]|
+                  8[014-9]
                 )
               )|
               3(?:
           <format>$2 15-$3-$4</format>
           <intlFormat>$1 $2 $3-$4</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(9)(\d{4})(\d{3})(\d{3})">
-          <!-- The formatting pattern here for these newly introduced area codes is based on the ITU
-               document. We have not found sufficient examples online to know if this is actually
-               being followed by the general population, or whether the back-up pattern for
-               four-digit area codes (below) is preferred. -->
-          <leadingDigits>93[58]</leadingDigits>
-          <leadingDigits>
-            9(?:
-              3(?:
-                53|
-                8[78]
-              )
-            )
-          </leadingDigits>
-          <leadingDigits>
-            9(?:
-              3(?:
-                537|
-                8(?:
-                  73|
-                  88
-                )
-              )
-            )
-          </leadingDigits>
-          <format>$2 15-$3-$4</format>
-        </numberFormat>
+        <!-- Both 4-3-3 and 4-2-4 have been seen online; we prefer the latter since it matches the
+             Argentinian ITU doc and wikipedia. -->
         <numberFormat pattern="(9)(\d{4})(\d{2})(\d{4})">
           <leadingDigits>9[23]</leadingDigits>
           <format>$2 15-$3-$4</format>
           <intlFormat>$1 $2 $3-$4</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(11)(\d{4})(\d{4})">
+        <numberFormat pattern="(11)(\d{4})(\d{4})" nationalPrefixOptionalWhenFormatting="true">
           <leadingDigits>1</leadingDigits>
           <format>$1 $2-$3</format>
         </numberFormat>
         <!-- These patterns are a copy of the mobile patterns with the leading 9 removed. -->
-        <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
+        <numberFormat pattern="(\d{3})(\d{3})(\d{4})" nationalPrefixOptionalWhenFormatting="true">
           <leadingDigits>
             2(?:
               2[013]|
               8[013578]
             )
           </leadingDigits>
-          <!-- Several 294X four-digit area codes exist: 2940, 2942, 2945, 2946 and 2948. -->
+          <!-- We exclude here several 294X four-digit area codes: 2940, 2942, 2945, 2946 and 2948,
+               298[23], and several 38[3578]X four-digit area codes. -->
           <leadingDigits>
             2(?:
               2[013]|
               6[01346]|
               80|
               9(?:
-                [17-9]|
-                4[13479]
+                [179]|
+                4[13479]|
+                8[014-9]
               )
             )|
             3(?:
           </leadingDigits>
           <format>$1 $2-$3</format>
         </numberFormat>
-        <numberFormat pattern="(\d{4})(\d{3})(\d{3})">
-          <leadingDigits>
-            3(?:
-              53|
-              8[78]
-            )
-          </leadingDigits>
-          <leadingDigits>
-            3(?:
-              537|
-              8(?:
-                73|
-                88
-              )
-            )
-          </leadingDigits>
-          <format>$1 $2-$3</format>
-        </numberFormat>
-        <numberFormat pattern="(\d{4})(\d{2})(\d{4})">
+        <numberFormat pattern="(\d{4})(\d{2})(\d{4})" nationalPrefixOptionalWhenFormatting="true">
           <leadingDigits>[23]</leadingDigits>
           <format>$1 $2-$3</format>
         </numberFormat>
+        <!-- Format short numbers as a block. -->
+        <numberFormat pattern="(\d{3})" nationalPrefixFormattingRule="$FG">
+          <leadingDigits>
+            1[012]|
+            911
+          </leadingDigits>
+          <format>$1</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
+        <!-- We restrict the second digit after 1 here so we can recognise and strip the 15 mobile
+           carrier prefix when we see it. -->
         <nationalNumberPattern>
-          [1-368]\d{9}|
+          11\d{8}|
+          [2368]\d{9}|
           9\d{10}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>8101234567</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[017]|
-            28
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>101</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- American Samoa -->
-    <!-- http://www.itu.int/oth/T0202000004/en -->
     <territory id="AS" countryCode="1" leadingDigits="684" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000004/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
         <exampleNumber>6846221234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 24[246], operated from Blue Sky. -->
+        <!-- Added 25[246], operated from Blue Sky. Added 731, 770, operated by ASTCA. -->
         <nationalNumberPattern>
           684(?:
-            733|
-            25[2468]
+            25[2468]|
+            7(?:
+              3[13]|
+              70
+            )
           )\d{4}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf
-             http://www.airportairport.com/American-Samoa.html
-             http://www.frommers.com/destinations/americansamoa/3038020157.html -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Austria -->
-    <!-- http://www.rtr.at/en/tk/E129 -->
     <territory id="AT" countryCode="43" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.rtr.at/en/tk/E129</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(1)(\d{3,12})">
           <leadingDigits>1</leadingDigits>
               2[1-8]|
               35|
               4[1-8]|
-              [57-9]
+              [5-79]
             )
           </leadingDigits>
             <format>$1 $2</format>
         <possibleNumberPattern>\d{5,13}</possibleNumberPattern>
         <exampleNumber>50123</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            [12]2|
-            33|
-            44
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Australia -->
     <!-- Metadata shared with Cocos Islands (CC) and Christmas Islands (CX) -->
-    <!-- http://www.itu.int/oth/T020200000D/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia -->
     <territory id="AU" countryCode="61" mainCountryForCode="true"
                internationalPrefix="(?:14(?:1[14]|34|4[17]|[56]6|7[47]|88))?001[14-689]"
-               preferredInternationalPrefix="0011" nationalPrefix="0">
+               preferredInternationalPrefix="0011" nationalPrefix="0"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200000D/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
           pattern="([2378])(\d{4})(\d{4})">
       </fixedLine>
       <mobile>
         <!-- Includes MobileSat and Thuraya satellite services. According to the wikipedia page,
-             other ranges 14[1-3] are not currently used. -->
+             other ranges 14[1-3] are not currently used. Note CC and CX should be updated as well
+             if this pattern changes. -->
         <nationalNumberPattern>
           14(?:
             5\d|
             [0-2]\d|
             3[0-57-9]|
             4[47-9]|
-            5[0-35-9]|
+            5[0-25-9]|
             6[6-9]|
-            [79][07-9]|
-            8[17-9]
+            7[03-9]|
+            8[17-9]|
+            9[017-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>1800123456</exampleNumber>
       </tollFree>
       <premiumRate>
-        <nationalNumberPattern>
-          19(?:
-            0[0126]\d{6}|
-            [13-5]\d{3}|
-            [679]\d{5}
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
+        <nationalNumberPattern>190[0126]\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>1900123456</exampleNumber>
       </premiumRate>
       <sharedCost>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>550123456</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          000|
-          112
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Aruba -->
-    <!-- http://www.itu.int/oth/T020200000B/en -->
     <territory id="AW" countryCode="297" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200000B/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         </nationalNumberPattern>
         <exampleNumber>5011234</exampleNumber>
       </voip>
-      <emergency>
-        <!-- http://www.yellowpages-aruba.com/home/emergency-numbers -->
-        <nationalNumberPattern>
-          100|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Åland Islands. -->
     <!-- Metadata shared with Finland. -->
-    <!-- http://www.ficora.fi/en/index/palvelut/palvelutaiheittain/numerointi/numerotyypitjaalueet.html -->
     <territory id="AX" countryCode="358" internationalPrefix="00|99[049]" nationalPrefix="0"
                nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.ficora.fi/en/index/palvelut/palvelutaiheittain/numerointi/numerotyypitjaalueet.html</sourceUrl>
+      </references>
       <!-- The general desc and fixed line are numbers different from Finland metadata. -->
       <generalDesc>
         <nationalNumberPattern>
         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
         <exampleNumber>10112345</exampleNumber>
       </uan>
-      <emergency>
-        <!-- http://www.arrivalguides.com/en/Travelguides/Europe/Finland/ALAND -->
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Azerbaijan -->
-    <!-- http://www.itu.int/oth/T020200000F/en -->
     <territory id="AZ" countryCode="994" internationalPrefix="00" nationalPrefix="0"
-               nationalPrefixFormattingRule="($NP$FG)">
+               nationalPrefixFormattingRule="($NP$FG)" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200000F/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
           <leadingDigits>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>900200123</exampleNumber>
       </premiumRate>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_978.html
-             http://wikitravel.org/en/Azerbaijan#Emergency_contact_numbers -->
-        <nationalNumberPattern>
-          1(?:
-            0[123]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>101</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bosnia and Herzegovina -->
-    <!-- http://www.rak.ba/eng/index.php?uid=1272016657 (accessible from
-         http://www.cra.ba/en/telecom/numbering/) -->
-    <!-- http://en.wikipedia.org/wiki/+387 -->
     <territory id="BA" countryCode="387" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <!-- accessible from http://www.cra.ba/en/telecom/numbering/ -->
+        <sourceUrl>http://www.rak.ba/eng/index.php?uid=1272016657</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+387</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
           <leadingDigits>[3-5]</leadingDigits>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>70223456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>12[234]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>122</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Barbados -->
-    <!-- http://www.itu.int/oth/T0202000013/en -->
     <territory id="BB" countryCode="1" leadingDigits="246" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000013/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>[235]11</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>211</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bangladesh -->
-    <!-- http://www.itu.int/oth/T0202000012/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Bangladesh -->
-    <!-- http://www.btrc.gov.bd/engineering/national_numbering_plan_2005.pdf -->
     <territory id="BD" countryCode="880" internationalPrefix="00[12]?"
                preferredInternationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000012/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Bangladesh</sourceUrl>
+        <sourceUrl>http://www.btrc.gov.bd/sites/default/files/national_numbering_plan_2005_0.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(2)(\d{7})">
           <leadingDigits>2</leadingDigits>
               5[5-7]|
               6[0167]|
               7[15]|
-              8[016-8]
+              8[0146-8]
             )
           )\d{4}|
           3(?:
                 3|
                 4\d
               )
-            )|
+            )
           )\d{3}|
           4(?:
             0(?:
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9604123456</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          10[0-2]|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Belgium -->
-    <!-- http://www.bipt.be/en/161/ShowContent/502/Database/Databases.aspx -->
-    <!-- http://www.telefoonzones.be/ -->
     <territory id="BE" countryCode="32" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.bipt.be/en/161/ShowContent/502/Database/Databases.aspx</sourceUrl>
+        <sourceUrl>http://www.telefoonzones.be/</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(4[6-9]\d)(\d{2})(\d{2})(\d{2})">
           <leadingDigits>4[6-9]</leadingDigits>
         <numberFormat pattern="([15-8]\d)(\d{2})(\d{2})(\d{2})">
           <leadingDigits>
             [156]|
-            7[0178]|
+            7[018]|
             8(?:
               0[1-9]|
               [1-79]
         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Note that 80 is a valid area code, so we explicitly check for this case that the third
-             digit begins with 1-9 -->
+        <!-- According to the published Excel document the third digit must be 1-9. -->
         <nationalNumberPattern>
           (?:
             1[0-69]|
-            [23][2-8]|
             [49][23]|
             5\d|
             6[013-57-9]|
-            71
-          )\d{6}|
-          8(?:
-            0[1-9]|
-            [1-79]\d
-          )\d{5}
+            71|
+            8[0-79]
+          )[1-9]\d{5}|
+          [23][2-8]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>12345678</exampleNumber>
       <premiumRate>
         <nationalNumberPattern>
           (?:
-            90|
-            7[07]
-          )\d{6}
+            70[2-7]|
+            90\d
+          )\d{5}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>90123456</exampleNumber>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>78123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[01]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Burkina Faso -->
-    <!-- http://www.itu.int/oth/T0202000021/en -->
-    <!-- http://www.onatel.bf/onatelsa/plandenumerotation_burkina.pdf -->
     <territory id="BF" countryCode="226" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000021/en</sourceUrl>
+        <sourceUrl>http://www.onatel.bf/onatelsa/plandenumerotation_burkina.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <!-- The national numbering plan from ITU suggests grouping of 2, 2 and 4, but we have
              chosen to use the standard from numbers found on the internet instead. -->
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- The prefix 50 48 has been added based on numbers found online, while 40 49 has been
-             deleted since we haven't found any numbers with this prefix and it is not mentioned in
-             the Onatel document.
-             IMPORTANT: Note that the ITU documents of Mar/Apr 2013 seem to have major errors in the
-             fixed-line table, so we have not changed our patterns based on these. -->
         <nationalNumberPattern>
           (?:
             20(?:
               9[016-9]
             )|
             40(?:
-              4[56]|
+              4[569]|
               5[4-6]|
               7[0179]
             )|
-            50[34]\d
+            50(?:
+              [34]\d|
+              50
+            )
           )\d{4}
         </nationalNumberPattern>
         <exampleNumber>20491234</exampleNumber>
       <mobile>
         <nationalNumberPattern>
           6(?:
-            [0-256]\d|
-            8[0-5]|
-            4[0-4]
+            [0-689]\d|
+            7[0-5]
           )\d{5}|
           7\d{7}
         </nationalNumberPattern>
         <exampleNumber>70123456</exampleNumber>
       </mobile>
-      <!-- http://www.diplomatie.gouv.fr/fr/conseils-aux-voyageurs_909/conseils-par-pays_12191/burkina-faso_12217/index.html -->
-      <emergency>
-        <nationalNumberPattern>1[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bulgaria -->
-    <!-- http://www.itu.int/oth/T0202000020/en -->
     <territory id="BG" countryCode="359" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000020/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formatting rules follow the conventions seen in web-search results. A space has been
              used to separate the area code from the rest of the number, based on sites like
         <nationalNumberPattern>700\d{5}</nationalNumberPattern>
         <exampleNumber>70012345</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            50|
-            6[06]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bahrain -->
-    <!-- http://www.itu.int/oth/T0202000011/en -->
-    <!-- http://www.tra.org.bh/en/pdf/National_Numbering_Plan_2.pdf -->
-    <!-- http://www.tra.org.bh/en/marketNumbering.aspx -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Bahrain -->
-    <territory id="BH" countryCode="973" internationalPrefix="00">
+    <territory id="BH" countryCode="973" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000011/en</sourceUrl>
+        <sourceUrl>http://www.tra.org.bh/en/marketNumbering.aspx</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Bahrain</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <format>$1 $2</format>
         <nationalNumberPattern>[136-9]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
-      <!-- Universal Service numbers are under both Mobile and Fixed-Line, as they can be assigned
-           to either. -->
+      <!-- Some ranges were previously described as "universal", but in subsequent versions of the
+           ITU doc they have been specified to be mobile or fixed-line. We follow the ITU
+           designations, even though some publications still refer to them as universal. -->
+      <!-- According to http://en.wikipedia.org/wiki/Telephone_numbers_in_Bahrain, the ranges
+           "6966-6969, 6996, 6999" are assigned to Rapid. However this contradicts the ITU doc
+           which lists "6966, 6969, 6996, 6999". We follow ITU here. -->
       <fixedLine>
         <nationalNumberPattern>
           (?:
             1(?:
-              3[3-6]|
+              3[13-6]|
               6[0156]|
               7\d
             )\d|
             6(?:
               1[16]\d|
+              500|
               6(?:
                 0\d|
                 3[12]|
-                44
+                44|
+                88
               )|
-              9(?:
-                69|
-                9[6-9]
-              )
+              9[69][69]
             )|
-            77\d{2}
+            7(?:
+              7\d{2}|
+              178
+            )
           )\d{4}
         </nationalNumberPattern>
         <exampleNumber>17001234</exampleNumber>
       </fixedLine>
+      <!-- 31 is assigned to Royal Court, as per documents on Bahrain's own telecom site, even
+           though it is omitted from the ITU document. 356 was added based on numbers found
+           online. -->
       <mobile>
         <nationalNumberPattern>
           (?:
             3(?:
               [1-4679]\d|
-              5[035]|
-              8[348]
+              5[01356]|
+              8[0-48]
             )\d|
             6(?:
-              1[16]\d|
               3(?:
                 00|
                 33|
                 6[16]
               )|
-              500|
               6(?:
-                [069]\d|
-                3[03-9]|
-                44|
-                88
-              )|
-              9(?:
-                69|
-                9[6-9]
+                [69]\d|
+                3[03-9]
               )
-            )|
-            77\d{2}
+            )
           )\d{4}
         </nationalNumberPattern>
         <exampleNumber>36001234</exampleNumber>
         <nationalNumberPattern>84\d{6}</nationalNumberPattern>
         <exampleNumber>84123456</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Burundi -->
-    <!-- http://www.itu.int/oth/T0202000022/en -->
     <territory id="BI" countryCode="257" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000022/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat
-          pattern="([27]\d)(\d{2})(\d{2})(\d{2})">
+          pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[27]\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>[267]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
              satellite phones. -->
         <nationalNumberPattern>
           (?:
-            29|
+            [26]9|
             7[14-9]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>79561234</exampleNumber>
       </mobile>
-      <!-- http://www.diplomatie.gouv.fr/fr/conseils-aux-voyageurs_909/conseils-par-pays_12191/burundi_12220/index.html -->
-      <emergency>
-        <nationalNumberPattern>11[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>117</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Benin -->
-    <!-- http://www.itu.int/oth/T0202000017/en -->
     <territory id="BJ" countryCode="229" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000017/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
       <mobile>
         <!-- We have restricted the pattern here to the first two digits, as beyond this the data
              seems to be no longer accurate. The prefixes 9[46] have also been added, along with
-             6[67] (seemingly prefixes for Mobile MTN), and 64 for BeninCell. Glo Mobile has been
+             6[167] (seemingly prefixes for Mobile MTN), and 64 for BeninCell. Glo Mobile has been
              reported as having prefixes 68 and 9[89]. -->
         <nationalNumberPattern>
           (?:
-            6[46-8]|
+            6[146-8]|
             9[03-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>81123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>11[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>117</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Saint Barthélemy, French Antilles -->
          available in these regions are used. In these cases, if getRegionCodeForNumber is used, one
          of these region codes will be returned, although numbers will be valid for both regions.
          -->
-    <!-- http://www.itu.int/oth/T0202000058/en -->
     <territory id="BL" countryCode="590" internationalPrefix="00" nationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000058/en</sourceUrl>
+      </references>
       <!-- Formatting rules borrowed from Guadeloupe. -->
       <generalDesc>
         <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
         </nationalNumberPattern>
         <exampleNumber>690301234</exampleNumber>
       </mobile>
-      <!-- http://www.comstbarth.fr/urgences.asp -->
-      <emergency>
-        <nationalNumberPattern>18</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>18</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bermuda -->
-    <!-- http://www.itu.int/oth/T0202000018/en -->
     <territory id="BM" countryCode="1" leadingDigits="441" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000018/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[4589]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1067.html -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Brunei Darussalam -->
-    <!-- http://www.itu.int/oth/T020200001F/en -->
     <territory id="BN" countryCode="673" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200001F/en</sourceUrl>
+      </references>
       <!-- Format is from http://aiti.gov.bn/contact.html -->
       <availableFormats>
         <numberFormat pattern="([2-578]\d{2})(\d{4})">
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <nationalNumberPattern>[2-5]\d{6}</nationalNumberPattern>
+        <nationalNumberPattern>
+          2(?:
+            [013-9]\d|
+            2[0-7]
+          )\d{4}|
+          [3-5]\d{6}
+        </nationalNumberPattern>
         <exampleNumber>2345678</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>[78]\d{6}</nationalNumberPattern>
+        <nationalNumberPattern>
+          22[89]\d{4}|
+          [78]\d{6}
+        </nationalNumberPattern>
         <exampleNumber>7123456</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.information.gov.bn/VER2/content/view/52/62/ -->
-        <nationalNumberPattern>99[135]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>991</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bolivia -->
-    <!-- http://www.itu.int/oth/T020200001A/en -->
-    <!-- http://www.bolivia.com/Servicios/Plandenumeracion.pdf -->
     <territory id="BO" countryCode="591" internationalPrefix="00(1\d)?" nationalPrefix="0"
                nationalPrefixForParsing="0(1\d)?" carrierCodeFormattingRule="$NP$CC $FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200001A/en</sourceUrl>
+        <sourceUrl>http://www.bolivia.com/Servicios/Plandenumeracion.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([234])(\d{7})">
           <leadingDigits>[234]</leadingDigits>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>71234567</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>11[089]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>110</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bonaire, Sint Eustatius and Saba -->
-    <!-- http://www.itu.int/oth/T02020000F8/en -->
     <territory id="BQ" countryCode="599" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000F8/en</sourceUrl>
+      </references>
       <!-- Shares formatting patterns with CW. -->
       <generalDesc>
         <nationalNumberPattern>[347]\d{6}</nationalNumberPattern>
         <nationalNumberPattern>
           (?:
             318[023]|
-            416[0239]|
+            416[023]|
             7(?:
               1[578]|
               50
       <mobile>
         <nationalNumberPattern>
           (?:
-            318[1456]|
-            416[15-8]|
+            318[14-68]|
+            416[15-9]|
             7(?:
               0[01]|
+              7[07]|
               [89]\d
             )\d
-          )\d{3}|
+          )\d{3}
         </nationalNumberPattern>
         <exampleNumber>3181234</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.rijksdienstcn.com/index.php?view=pagina&id=126&set_language=EN -->
-        <nationalNumberPattern>
-          112|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Brazil -->
-    <!-- http://en.wikipedia.org/wiki/%2B55 -->
-    <!-- http://www.itu.int/oth/T020200001D/en -->
     <territory id="BR" countryCode="55"
-               internationalPrefix="00(?:1[45]|2[135]|[34]1|43)"
+               internationalPrefix="00(?:1[45]|2[135]|31|4[13])"
                nationalPrefix="0"
-               nationalPrefixForParsing="0(?:(1[245]|2[135]|[34]1)(\d{10,11}))?"
-               nationalPrefixTransformRule="$2">
+               nationalPrefixForParsing="0(?:(1[245]|2[135]|31|4[13])(\d{10,11}))?"
+               nationalPrefixTransformRule="$2" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B55</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T020200001D/en</sourceUrl>
+      </references>
       <!-- The national prefix for parsing here also contains a capturing group for the main number,
            since the carrier codes here may also be area codes, so we want to check the length of
            the number after capturing. We also need a nationalTransformRule to repopulate with the
           <format>$1-$2</format>
           <intlFormat>NA</intlFormat>
         </numberFormat>
+        <!-- Format short numbers as a block. -->
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{3,5})">
+          <leadingDigits>1[125689]</leadingDigits>
+          <format>$1</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
         <numberFormat nationalPrefixFormattingRule="($FG)"
             pattern="(\d{2})(\d{5})(\d{4})"
             carrierCodeFormattingRule="$NP $CC ($FG)">
           <leadingDigits>
             (?:
               1[1-9]|
-              2[12478]
+              2[12478]|
+              9[1-9]
             )9
           </leadingDigits>
           <format>$1 $2-$3</format>
         </nationalNumberPattern>
         <exampleNumber>1123456789</exampleNumber>
       </fixedLine>
-      <!--  Also includes the new 11-digit mobile numbers that are being rolled out since 2012,
-            which are added at the end. -->
       <mobile>
-        <nationalNumberPattern>
-          1(?:
-            1(?:
-              5[347]|
-              [6-9]\d|
-            )|
-            [2-9][6-9]\d
-          )\d{6}|
+        <!-- Since 2012, Brazil has been migrating from 10 to 11 digits by inserting a 9 before the
+             last 8 digits. The following pattern is divided into 3 sections: ranges for which the
+             migration has been completed, ranges which are in transition, and ranges which are
+             still in the old format. (Ranges which were supposed to have been deprecated in
+             Oct. 2013 are still working as of Jan. 2014.) Note that mobile radio services are
+             still 10 digits, with the subscriber number (the last 8 digits) beginning with 7. -->
+        <nationalNumberPattern>
+          1[1-9](?:
+            7|
+            9\d
+          )\d{7}|
           (?:
             2[12478]|
+            9[1-9]
+          )9?[6-9]\d{7}|
+          (?:
             3[1-578]|
-            [4689][1-9]|
+            [468][1-9]|
             5[13-5]|
             7[13-579]
-          )[6-9]\d{7}|
-          (?:
-            1(?:
-              19\d|
-              [2-9]9[6-9]
-            )|
-            2[12478]9[6-9]
-          )\d{7}
+          )[6-9]\d{7}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10,11}</possibleNumberPattern>
-        <exampleNumber>1161234567</exampleNumber>
+        <exampleNumber>11961234567</exampleNumber>
       </mobile>
       <tollFree>
         <nationalNumberPattern>800\d{6,7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>40041234</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            28|
-            9[023]
-          )|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>190</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bahamas -->
-    <!-- http://www.itu.int/oth/T0202000010/en -->
     <territory id="BS" countryCode="1" leadingDigits="242" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000010/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
             461|
             502|
             6(?:
+              0[12]|
               12|
               7[67]|
               8[78]|
           242300\d{4}|
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_989.html -->
-        <nationalNumberPattern>91[19]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Bhutan -->
-    <!-- http://www.itu.int/oth/T0202000019/en -->
     <territory id="BT" countryCode="975" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000019/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Format is from
              http://www.tourism.gov.bt/tour-operators/bhutan-abbot-tours-and-travels.html -->
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>17123456</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.rbp.gov.bt/requestpolice.php -->
-        <!-- http://www.jdwnrh.gov.bt/sfo2011/?page_id=51 -->
-        <nationalNumberPattern>11[023]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>113</exampleNumber>
-      </emergency>
       <!-- No information on other types of phone numbers for Bhutan has been found. -->
     </territory>
 
     <!-- Botswana -->
-    <!-- http://www.itu.int/oth/T020200001C/en -->
     <territory id="BW" countryCode="267" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200001C/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>[2-6]</leadingDigits>
         <exampleNumber>2401234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- 77[01] has been added after numbers in use have been seen online. -->
         <nationalNumberPattern>
           7(?:
-            [1-35]\d{6}|
-            [46][0-7]\d{5}|
-            7[01]\d{5}
-          )
+            [1-356]\d|
+            4[0-7]|
+            7[014-7]
+          )\d{5}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>71123456</exampleNumber>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>79101234</exampleNumber>
       </voip>
-      <emergency>
-        <!-- http://www.gov.bw/en/Ministries%2D%2DAuthorities/Ministries/State-President/Botswana-Police-Service-/About-the-BPS/Toll-Free-Numbers/ -->
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1071.html -->
-        <nationalNumberPattern>99[789]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Belarus -->
-    <!-- http://www.eng.beltelecom.by/en/subscribers/phone-codes -->
     <!-- Information on national prefix provided by a Belarussian person. -->
     <territory id="BY" countryCode="375" preferredInternationalPrefix="8~10"
-               internationalPrefix="810" nationalPrefixForParsing="80?"
-               nationalPrefix="8">
+               internationalPrefix="810" nationalPrefixForParsing="8?0?"
+               nationalPrefix="8" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.eng.beltelecom.by/en/subscribers/phone-codes</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="$NP 0$FG"
-          pattern="([1-4]\d)(\d{3})(\d{4})">
-          <leadingDigits>[1-4]</leadingDigits>
-          <format>$1 $2 $3</format>
-        </numberFormat>
-        <numberFormat nationalPrefixFormattingRule="$NP $FG"
-          pattern="([89]\d{2})(\d{3})(\d{4})">
+          pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
           <leadingDigits>
-            8[01]|
-            9
+            17[0-3589]|
+            2[4-9]|
+            [34]
           </leadingDigits>
-          <format>$1 $2 $3</format>
+          <leadingDigits>
+            17(?:
+              [02358]|
+              1[0-2]|
+              9[0189]
+            )|
+            2[4-9]|
+            [34]
+          </leadingDigits>
+          <format>$1 $2-$3-$4</format>
         </numberFormat>
-        <numberFormat nationalPrefixFormattingRule="$NP $FG"
+        <numberFormat nationalPrefixFormattingRule="$NP 0$FG"
+          pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
+          <leadingDigits>
+            1(?:
+              5[24]|
+              6[235]|
+              7[467]
+            )|
+            2(?:
+              1[246]|
+              2[25]|
+              3[26]
+            )
+          </leadingDigits>
+          <leadingDigits>
+            1(?:
+              5[24]|
+              6(?:
+                2|
+                3[04-9]|
+                5[0346-9]
+              )|
+              7(?:
+                [46]|
+                7[37-9]
+              )
+            )|
+            2(?:
+              1[246]|
+              2[25]|
+              3[26]
+            )
+          </leadingDigits>
+          <format>$1 $2-$3-$4</format>
+        </numberFormat>
+        <numberFormat nationalPrefixFormattingRule="$NP 0$FG"
+          pattern="(\d{4})(\d{2})(\d{3})">
+          <leadingDigits>
+            1(?:
+              5[169]|
+              6[3-5]|
+              7[179]
+            )|
+            2(?:
+              1[35]|
+              2[34]|
+              3[3-5]
+            )
+          </leadingDigits>
+          <leadingDigits>
+            1(?:
+              5[169]|
+              6(?:
+                3[1-3]|
+                4|
+                5[125]
+              )|
+              7(?:
+                1[3-9]|
+                7[0-24-6]|
+                9[2-7]
+              )
+            )|
+            2(?:
+              1[35]|
+              2[34]|
+              3[3-5]
+            )
+          </leadingDigits>
+          <format>$1 $2-$3</format>
+        </numberFormat>
+        <numberFormat nationalPrefixFormattingRule="$NP $FG"
+          pattern="([89]\d{2})(\d{3})(\d{4})">
+          <leadingDigits>
+            8[01]|
+            9
+          </leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
+        <numberFormat nationalPrefixFormattingRule="$NP $FG"
           pattern="(8\d{2})(\d{4})(\d{4})">
           <leadingDigits>82</leadingDigits>
           <format>$1 $2 $3</format>
       <noInternationalDialling>
         <nationalNumberPattern>
           8(?:
-            [01]|
-            20
+            [013]|
+            [12]0
           )\d{8}|
           902\d{7}
         </nationalNumberPattern>
             1(?:
               5(?:
                 1[1-5]|
-                2\d|
+                [24]\d|
                 6[2-4]|
                 9[1-7]
               )|
                 4[0-8]
               )|
               3(?:
-                2\d|
+                [26]\d|
                 3[02-79]|
                 4[024-7]|
-                5[0-7]
+                5[03-7]
               )
             )
           )\d{5}
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9021234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[123]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Belize -->
-    <!-- http://www.itu.int/oth/T0202000016/en -->
     <!-- The trunk prefix, formally 0, was dropped in the last reorganisation of the numbering plan.
          -->
     <territory id="BZ" countryCode="501" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000016/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>[2-8]</leadingDigits>
       </mobile>
       <!-- We don't know how these would be dialled internationally - it is possible that they can't
            be dialled internationally at all - so we represent the leading 0 as part of the number.
-           Information from www.belizetelemedia.net. -->
+           Information from http://www.belizetelemedia.net. -->
       <tollFree>
         <nationalNumberPattern>0800\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{11}</possibleNumberPattern>
         <exampleNumber>08001234123</exampleNumber>
       </tollFree>
-      <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-      <emergency>
-        <nationalNumberPattern>
-          9(?:
-            0|
-            11
-          )
-          </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Canada -->
-    <!-- http://www.cnac.ca/canadian_dial_plan/canadian_dial_plan.htm -->
-    <territory id="CA" countryCode="1" internationalPrefix="011" nationalPrefix="1">
+    <territory id="CA" countryCode="1" internationalPrefix="011" nationalPrefix="1"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.cnac.ca/canadian_dial_plan/canadian_dial_plan.htm</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>
               03|
               1[68]|
               3[178]|
-              5[06]
+              50
             )|
             5(?:
-              0[06]|
+              06|
               1[49]|
               79|
               8[17]
               47
             )|
             7(?:
-              0[059]|
-              80|
-              78
+              0[59]|
+              78|
+              8[02]
             )|
             8(?:
               [06]7|
               03|
               1[68]|
               3[178]|
-              5[06]
+              50
             )|
             5(?:
-              0[06]|
+              06|
               1[49]|
               79|
               8[17]
               47
             )|
             7(?:
-              0[059]|
-              80|
-              78
+              0[59]|
+              78|
+              8[02]
             )|
             8(?:
               [06]7|
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Cocos Islands -->
     <!-- Metadata shared with Australia. -->
     <!-- References state Cocos Islands have fixed line numbers starting +61 8 9162. -->
-    <!-- http://en.wikipedia.org/wiki/List_of_country_calling_codes -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia -->
     <territory id="CC" countryCode="61" preferredInternationalPrefix="0011"
                internationalPrefix="(?:14(?:1[14]|34|4[17]|[56]6|7[47]|88))?001[14-689]"
                nationalPrefix="0">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/List_of_country_calling_codes</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia</sourceUrl>
+      </references>
       <!-- Uses AU formatting rules. -->
       <!-- General desc and fixed line rules different from Australia. -->
       <generalDesc>
       <!-- Mobile, toll free, premium rate, personal number and VOIP copied from Australia. -->
       <mobile>
         <nationalNumberPattern>
+          14(?:
+            5\d|
+            71
+          )\d{5}|
           4(?:
             [0-2]\d|
             3[0-57-9]|
             4[47-9]|
-            5[0-37-9]|
+            5[0-25-9]|
             6[6-9]|
-            7[07-9]|
-            8[7-9]
+            7[03-9]|
+            8[17-9]|
+            9[017-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>550123456</exampleNumber>
       </voip>
-      <emergency>
-        <!-- We assume this is the same as for Australia, since they have the same country code and
-             share their police force, and no better information can be found. -->
-        <nationalNumberPattern>
-          000|
-          112
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Congo, Dem. Rep. of the (formerly Zaire) -->
-    <!-- http://www.itu.int/oth/T0202000037/en -->
     <territory id="CD" countryCode="243" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000037/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
           <leadingDigits>12</leadingDigits>
         </nationalNumberPattern>
         <exampleNumber>991234567</exampleNumber>
       </mobile>
-      <!-- No national emergency numbers were located for Congo. -->
     </territory>
 
     <!-- Central African Republic -->
-    <!-- http://www.itu.int/oth/T0202000028/en -->
     <territory id="CF" countryCode="236" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000028/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
         <nationalNumberPattern>8776\d{4}</nationalNumberPattern>
         <exampleNumber>87761234</exampleNumber>
       </premiumRate>
-      <!-- No emergency numbers information can be found. -->
     </territory>
 
     <!-- Congo (Rep. of the) (Brazzaville) -->
-    <!-- http://www.itu.int/oth/T020200002E/en -->
     <territory id="CG" countryCode="242" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200002E/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
           <leadingDigits>[02]</leadingDigits>
         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
         <exampleNumber>800123456</exampleNumber>
       </tollFree>
-      <!-- No emergency numbers information can be found. -->
     </territory>
 
     <!-- Switzerland -->
-    <!-- http://www.bakom.admin.ch/themen/telekom/00479/00604/index.html?lang=en
-         under Technical prescriptions: Numbering plan for international carriers -->
     <territory id="CH" countryCode="41" internationalPrefix="00"
-               nationalPrefix="0"  nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0"  nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <!-- Under Technical prescriptions: Numbering plan for international carriers. -->
+        <sourceUrl>http://www.bakom.admin.ch/themen/telekom/00479/00604/index.html?lang=en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([2-9]\d)(\d{3})(\d{2})(\d{2})">
           <leadingDigits>
             2[12467]|
             3[1-4]|
             4[134]|
-            5[12568]|
+            5[256]|
             6[12]|
             [7-9]1
           )\d{7}
         <exampleNumber>212345678</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>7[46-9]\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>7[5-9]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
-        <exampleNumber>741234567</exampleNumber>
+        <exampleNumber>781234567</exampleNumber>
       </mobile>
+      <pager>
+        <!-- https://www.eofcom.admin.ch/eofcom/public/listEofcom_e164Allocated.do -->
+        <nationalNumberPattern>74[0248]\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <exampleNumber>740123456</exampleNumber>
+      </pager>
       <tollFree>
         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>878123456</exampleNumber>
       </personalNumber>
+      <uan>
+        <!-- Used for corporate networks. -->
+        <nationalNumberPattern>5[18]\d{7}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <exampleNumber>581234567</exampleNumber>
+      </uan>
       <voicemail>
         <nationalNumberPattern>860\d{9}</nationalNumberPattern>
         <possibleNumberPattern>\d{12}</possibleNumberPattern>
         <exampleNumber>860123456789</exampleNumber>
       </voicemail>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1[278]|
-            44
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Côte d'Ivoire -->
-    <!-- http://www.itu.int/oth/T0202000031/en -->
     <territory id="CI" countryCode="225" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000031/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Using format from online yellow pages over format implied in national numbering plan.
              -->
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[02-6]\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>[02-7]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
         <exampleNumber>21234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Added the prefixes 4[0-2] (Moov), 5[5-9] & 65 because SMS messages have been
-             successfully delivered. Supported by numbers found on the internet. -->
-        <nationalNumberPattern>
+        <!-- Added the prefixes 4[0-2] (Moov), 5[5-9] & 6[15] because SMS messages have been
+             successfully delivered. Supported by numbers found on the internet. The prefix 56 was
+             assigned to MTN in July 2013:
+             http://www.atci.ci/images/stories/pdf/decisions-dg/decision_002.pdf
+             The prefix 75 is from an open-source bug report.
+             50 has been removed since Warid seems to have stopped operation in Côte d'Ivoire. -->
+          <nationalNumberPattern>
           (?:
             0[1-9]|
             4[0-24-9]|
-            5[05-9]|
-            6[05679]
+            5[4-9]|
+            6[015-79]|
+            7[57]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>01234567</exampleNumber>
       </mobile>
-      <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1[01]|
-            [78]0
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>110</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Cook Islands -->
-    <!-- http://www.itu.int/oth/T020200002F/en -->
     <territory id="CK" countryCode="682" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200002F/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})">
           <format>$1 $2</format>
         </nationalNumberPattern>
         <exampleNumber>71234</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.frommers.com/destinations/cookislands/3036020157.html and other tourist
-             sites agree on the following numbers. -->
-        <nationalNumberPattern>99[689]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>998</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Chile -->
-    <!-- http://www.itu.int/oth/T020200002A/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B56 -->
     <!-- Carriers listed here: http://www.turismochile.com/datos/carrier.php -->
     <territory id="CL" countryCode="56"
                internationalPrefix="(?:0|1(?:1[0-69]|2[0-57]|5[13-58]|69|7[0167]|8[018]))0"
                nationalPrefix="0"
                nationalPrefixForParsing="0|(1(?:1[0-69]|2[0-57]|5[13-58]|69|7[0167]|8[018]))"
-               nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefixFormattingRule="$NP$FG" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200002A/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B56</sourceUrl>
+        <sourceUrl>http://www.subtel.gob.cl/base_numeracion/tabla_numeracion_ido_idd.xlsx</sourceUrl>
+      </references>
       <!-- When dialling mobile numbers from landlines, or vice versa, you need a prefix of 0, which
-      we strip here. National destinations may be dialled with a carrier if they are not local so
-      we extract these carrier codes as well. -->
+           we strip here. National destinations may be dialled with a carrier if they are not local
+           so we extract these carrier codes as well. -->
       <availableFormats>
-        <numberFormat pattern="(2)(\d{3,4})(\d{4})"
+        <numberFormat pattern="(\d)(\d{4})(\d{4})"
           nationalPrefixFormattingRule="($FG)"
           carrierCodeFormattingRule="$CC ($FG)">
-          <leadingDigits>2</leadingDigits>
+          <leadingDigits>22</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="(\d{2})(\d{2,3})(\d{4})"
+        <numberFormat pattern="(\d{2})(\d{3})(\d{4})"
           nationalPrefixFormattingRule="($FG)"
           carrierCodeFormattingRule="$CC ($FG)">
           <leadingDigits>
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="(9)([5-9]\d{3})(\d{4})">
+        <numberFormat pattern="(9)(\d{4})(\d{4})">
           <leadingDigits>9</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
           <leadingDigits>1</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
+        <numberFormat pattern="(\d{5})(\d{4})"
+          nationalPrefixFormattingRule="($FG)"
+          carrierCodeFormattingRule="$CC ($FG)">
+          <leadingDigits>219</leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+        <!-- Format some short numbers as a block. -->
+        <numberFormat nationalPrefixFormattingRule="$FG"
+          pattern="(\d{4,5})">
+          <leadingDigits>[1-9]</leadingDigits>
+          <format>$1</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
             123
           )\d{7,8}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{6,11}</possibleNumberPattern>
+        <possibleNumberPattern>\d{7,11}</possibleNumberPattern>
       </generalDesc>
       <noInternationalDialling>
         <nationalNumberPattern>600\d{7,8}</nationalNumberPattern>
         <exampleNumber>6001234567</exampleNumber>
       </noInternationalDialling>
       <fixedLine>
-        <!-- Nov 2012: The prefixing of '2' to all fixed line numbers, which is being rolled
-             out between October 2012 and June 2013 means that temporarily the regular
-             expressions for areas will get very messy as some adopt the leading '2' but
-             others do not. Eventually when the conversion is complete things should simplify
-             again. Note that area codes 32 or 41 were transitioned in 2007.
-             IMPORTANT: A literal reading of the transition rules suggest that all numbers get
-             a '2' prefix, but some numbers are already 7 digits long (but these always start
-             with a '2'). The prefixing seems almost certain to only apply to 6-digit numbers and
-             will unify all fixed line numbers to be 9 digits in total. The fact that the new seven
-             digit numbers currently only start with a '2' is likely to change in the future.
-             Note also that at some stage it is likely that Santiago numbers (area code '2') will
-             have a prefix of "2\d" and not "22" (it's like 10 2-digit area codes wrapped into one).
+        <!-- In mid-2013, Chile switched from 8 digits to 9 digits for fixed-line numbers, by
+             inserting a '2' after the area code (which are 2 digits, with the exception of '2').
+             As of Aug. 2014, all of the prefixes have been switched over to the new plan.
+             IMPORTANT: The fact that Santiago numbers have a prefix of "22", and that numbers in
+             other areas have '2' as their third digit, is likely to change in the future. At some
+             stage, Santiago numbers will probably switch to prefix "2\d", and the third digit in
+             other areas will probably be allowed to take on other values.
              See: http://www.gob.cl/especiales/informate-de-la-nueva-forma-de-marcar/
                   http://www.subtel.cl/index.php?option=com_content&view=article&id=3081:&catid=3:noticias
              -->
         <nationalNumberPattern>
+          2(?:
+            2\d{7}|
+            1962\d{4}
+          )|
           (?:
-            [23]2|
-            41|
-            58
-          )\d{7}|
-          (?:
-            3[3-5]|
-            4[235]|
-            5[1-357]|
-            6[13-57]|
-            7[1-35]
-          )\d{6,7}
+            3[2-5]|
+            [47][1-35]|
+            5[1-3578]|
+            6[13-57]
+          )\d{7}
         </nationalNumberPattern>
         <!-- Area codes do not need to be dialled when dialling within the same area, so the
-             smallest possible number is length 6. -->
-        <!-- Nov 2012: The prefixing of '2' to all 6-digit fixed line numbers means that while
-             the maximum possible number length stays as 9, the minimum length will become '7'
-             when all area codes are migrated. -->
-        <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
+             smallest possible number is length 7. -->
+        <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
         <exampleNumber>221234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>9[5-9]\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>9[4-9]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
         <exampleNumber>961234567</exampleNumber>
       </mobile>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>441234567</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>13[123]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>133</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Cameroon -->
-    <!-- http://www.itu.int/oth/T0202000024/en -->
     <territory id="CM" countryCode="237" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000024/en</sourceUrl>
+        <sourceUrl>http://www.itu.int/dms_pub/itu-t/opb/sp/T-SP-OB.1063-2014-OAS-PDF-E.pdf</sourceUrl>
+      </references>
       <availableFormats>
-        <!-- Formatting on the internet is consistently with the first 2 extracted, and usually in
-             the same format as France (all 2 digit groups) so we use this instead of the guidance
-             of the national numbering plan (which has 1 3 2 2 and 4 4 as its two formatting
-             examples.) -->
-        <numberFormat pattern="([237-9]\d)(\d{2})(\d{2})(\d{2})">
+        <!-- Formatting in the ITU update document aligns with formatting online (all 2 digit
+             groups). For the new number format with 9 digits the first digit has it's own group.
+             -->
+        <numberFormat pattern="([26])(\d{2})(\d{2})(\d{2})(\d{2})">
+          <leadingDigits>[26]</leadingDigits>
+          <format>$1 $2 $3 $4 $5</format>
+        </numberFormat>
+        <numberFormat pattern="([2357-9]\d)(\d{2})(\d{2})(\d{2})">
           <leadingDigits>
-            [2379]|
+            [23579]|
             88
           </leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[237-9]\d{7}</nationalNumberPattern>
-        <possibleNumberPattern>\d{8}</possibleNumberPattern>
+        <nationalNumberPattern>[235-9]\d{7,8}</nationalNumberPattern>
+        <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Technically, the numbers are required only to start with a 2 or a 3, but all numbers at
-             the moment start with 22 or 33 since they have been migrated from seven digit numbers
-             beginning with these numbers. This rule should be relaxed if/when we start getting
-             numbers beginning in other ways. -->
+        <!-- Temporarily allow both old (22|33) and new 2(22|33) format. -->
+        <!-- CDMA numbers are described in a subcategory to fixed line numbers in the ITU update
+             document, so those prefixes are added to fixed line (24[23]). -->
         <nationalNumberPattern>
+          2(?:
+             22|
+             33|
+             4[23]
+          )\d{6}|
           (?:
             22|
             33
           )\d{6}
         </nationalNumberPattern>
-        <exampleNumber>22123456</exampleNumber>
+        <exampleNumber>222123456</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>[79]\d{7}</nationalNumberPattern>
-        <exampleNumber>71234567</exampleNumber>
+        <!-- Temporarily allow both old [579]\d{7} and new 6[5-79]\d{7} format. -->
+        <nationalNumberPattern>
+          6[5-79]\d{7}|
+          [579]\d{7}
+        </nationalNumberPattern>
+        <exampleNumber>671234567</exampleNumber>
       </mobile>
       <tollFree>
         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>80012345</exampleNumber>
       </tollFree>
       <premiumRate>
              with 88 (usually 880). No information can be found as to whether these are premium rate
              or shared cost. -->
         <nationalNumberPattern>88\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>88012345</exampleNumber>
       </premiumRate>
-      <!-- http://www.diplomatie.gouv.fr/fr/conseils-aux-voyageurs_909/conseils-par-pays_12191/cameroun_12221/index.html -->
-      <emergency>
-        <!-- Numbers must be prefixed with a 1 when dialled from a mobile. -->
-        <nationalNumberPattern>1?1[37]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>113</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- China -->
-    <!-- http://www.itu.int/oth/T020200002B/en -->
     <territory id="CN" countryCode="86" internationalPrefix="(1[1279]\d{3})?00"
                preferredInternationalPrefix="00" nationalPrefix="0"
                nationalPrefixForParsing="(1[1279]\d{3})|0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200002B/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(80\d{2})(\d{4})"
                       nationalPrefixOptionalWhenFormatting="true"
           <leadingDigits>[48]00</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <!-- 95xxx shared cost numbers. Without this rule, the numbers will be formatted
-             incorrectly by the AsYouTypeFormatter because they overlap with area code 095x.
-             Note although ITU says the format is more like 95 xxx, in reality no space is used
-             when writing such numbers in China -->
-        <numberFormat pattern="(\d{5})">
-          <leadingDigits>95</leadingDigits>
+        <!-- 100xx and 95xxx(x) short numbers without area codes. Without this rule, these short
+             numbers will be formatted incorrectly by the AsYouTypeFormatter because they overlap
+             with area codes 010, 095x. These numbers are defined in ShortNumberMetadata.xml but
+             must be accounted for here. Note although ITU says the format is more like 95 xxx, in
+             reality no space is used when writing such numbers in China. -->
+        <numberFormat pattern="(\d{5,6})">
+          <leadingDigits>
+            100|
+            95
+          </leadingDigits>
           <format>$1</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
+        <!-- 100xx and 95xxx(x) numbers with area codes (these numbers without an area code are now
+             dealt with by ShortNumberMetadata.xml) and 96xxx(x) numbers with area codes (we don't
+             support these as short numbers because they are only unique within a province, not
+             within a country). -->
+        <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(\d{2})(\d{5,6})"
+                      carrierCodeFormattingRule="$CC $FG">
+          <leadingDigits>
+            (?:
+              10|
+              2\d
+            )[19]
+          </leadingDigits>
+          <leadingDigits>
+            (?:
+              10|
+              2\d
+            )(?:
+              10|
+              9[56]
+            )
+          </leadingDigits>
+          <leadingDigits>
+            (?:
+              10|
+              2\d
+            )(?:
+              100|
+              9[56]
+            )
+          </leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+        <numberFormat nationalPrefixFormattingRule="$NP$FG" pattern="(\d{3})(\d{5,6})"
+                      carrierCodeFormattingRule="$CC $FG">
+          <leadingDigits>[3-9]</leadingDigits>
+          <leadingDigits>[3-9]\d{2}[19]</leadingDigits>
+          <leadingDigits>
+            [3-9]\d{2}(?:
+              10|
+              9[56]
+            )
+          </leadingDigits>
+          <format>$1 $2</format>
         </numberFormat>
         <!-- Local numbers -->
         <!-- Chinese fixed-line numbers can be dialed from a cell phone without area code and they
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="(1[3-58]\d)(\d{4})(\d{4})" carrierCodeFormattingRule="$CC $FG">
-          <leadingDigits>1[3-58]</leadingDigits>
+        <numberFormat pattern="(\d{3})(\d{4})(\d{4})" carrierCodeFormattingRule="$CC $FG">
+          <leadingDigits>1[3-578]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat pattern="(10800)(\d{3})(\d{4})">
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
-          [1-7]\d{7,11}|
+          [1-7]\d{6,11}|
           8[0-357-9]\d{6,9}|
-          9(?:
-            5\d{3}|
-            \d{9}
-          )
+          9\d{7,9}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{4,12}</possibleNumberPattern>
       </generalDesc>
       <noInternationalDialling>
-        <!-- 95xxx numbers have been verified to be unreachable from overseas by placing actual
-             calls. -->
         <nationalNumberPattern>
           (?:
             4|
             (?:
               10
             )?8
-          )00\d{7}|
-          95\d{3}
+          )00\d{7}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{5,12}</possibleNumberPattern>
+        <possibleNumberPattern>\d{10,12}</possibleNumberPattern>
         <exampleNumber>4001234567</exampleNumber>
       </noInternationalDialling>
       <fixedLine>
         <!-- 0432 increased to 8 digits on October 24, 2009. 0791 increased to 8 digits on August
              28, 2011. 0551 increased to 8 digits and 0565 was cancelled on Dec 8, 2012. 0871
              increased to 8 digits on December 16, 2012. 0475 is the prefix for Tongliao but is not
-             in the ITU data. -->
+             in the ITU data.
+             10xxx and 95xxx(x) numbers with area codes are also included here, as they behave
+             exactly like fixed-line numbers. We don't support them for 4-digit area codes though,
+             as they don't seem to be used there based on making actual phone calls.
+         -->
         <nationalNumberPattern>
-          21\d{8,10}|
+          21(?:
+            100\d{2}|
+            95\d{3,4}|
+            \d{8,10}
+          )|
           (?:
             10|
             2[02-57-9]|
               71|
               98
             )
-          )\d{8}|
+          )(?:
+            100\d{2}|
+            95\d{3,4}|
+            \d{8}
+          )|
           (?:
             3(?:
               1[02-9]|
               4[13]|
               5[1-5]
             )
-          )\d{7}|
+          )(?:
+            100\d{2}|
+            95\d{3,4}|
+            \d{7}
+          )|
           80(?:
             29|
             6[03578]|
         <exampleNumber>1012345678</exampleNumber>
       </fixedLine>
       <mobile>
+        <!-- 170, 176, 177 and 178 prefixes are introduced in early 2014 for 4G networks. -->
         <nationalNumberPattern>
           1(?:
-            3\d|
+            [38]\d|
             4[57]|
-            [58][0-35-9]
+            5[0-35-9]|
+            7[06-8]
           )\d{8}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{11}</possibleNumberPattern>
         <exampleNumber>16812345</exampleNumber>
       </premiumRate>
       <sharedCost>
-        <!-- 95xxx numbers are covered by the ITU doc, but the following doc contains more info:
-             http://baike.baidu.com/view/3269670.htm -->
+        <!-- 96xxx(x) numbers with area codes are included here. Their costs are not well
+             documented, but they are thought to be mostly local costs with certain exceptions. We
+             don't support them for 4-digit area codes though, as they don't seem to be used there
+             based on online searches. -->
         <nationalNumberPattern>
           400\d{7}|
-          95\d{3}
+          (?:
+            10|
+            2[0-57-9]|
+            3(?:
+              [157]\d|
+              35|
+              49|
+              9[1-68]
+            )|
+            4(?:
+              [17]\d|
+              2[179]|
+              [35][1-9]|
+              6[4789]|
+              8[23]
+            )|
+            5(?:
+              [1357]\d|
+              2[37]|
+              4[36]|
+              6[1-46]|
+              80|
+              9[1-9]
+            )|
+            6(?:
+              3[1-5]|
+              6[0238]|
+              9[12]
+            )|
+            7(?:
+              01|
+              [1579]\d|
+              2[248]|
+              3[014-9]|
+              4[3-6]|
+              6[023689]
+            )|
+            8(?:
+              1[236-8]|
+              2[5-7]|
+              [37]\d|
+              5[1-9]|
+              8[3678]|
+              9[1-8]
+            )|
+            9(?:
+              0[1-3689]|
+              1[1-79]|
+              [379]\d|
+              4[13]|
+              5[1-5]
+            )
+          )96\d{3,4}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{5}(?:\d{5})?</possibleNumberPattern>
+        <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
         <exampleNumber>4001234567</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1[09]|
-            20
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>119</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Colombia -->
-    <!-- http://www.itu.int/oth/T020200002C/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Colombia -->
-    <territory id="CO" countryCode="57" internationalPrefix="00[579]|#555|#999"
-               nationalPrefix="0" nationalPrefixForParsing="0([3579]|4(?:44|56))?">
+    <!-- Extra international dialling prefixes from http://www.claro.com.co and
+         http://www.tigo.com.co. -->
+    <!-- 05 and 005 are for Orbitel: co.orbitel.com -->
+    <territory id="CO" countryCode="57" internationalPrefix="00(?:4(?:[14]4|56)|[579])"
+               nationalPrefix="0" nationalPrefixForParsing="0([3579]|4(?:44|56))?"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200002C/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Colombia</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{7})" carrierCodeFormattingRule="$NP$CC $FG"
           nationalPrefixFormattingRule="($FG)">
         <exampleNumber>12345678</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Virgin Mobile Colombia have reported that they are now using the 319 prefix. -->
         <nationalNumberPattern>
           3(?:
-            0[0-24]|
+            0[0-5]|
             1\d|
-            2[01]
+            2[0-2]|
+            5[01]
           )\d{7}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <possibleNumberPattern>\d{11}</possibleNumberPattern>
         <exampleNumber>19001234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1[29]|
-            23|
-            32|
-            56
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Costa Rica -->
-    <!-- http://www.itu.int/oth/T0202000030/en -->
     <territory id="CR" countryCode="506" internationalPrefix="00"
-               nationalPrefixForParsing="(19(?:0[0-2468]|19|20|66|77))"
+               nationalPrefixForParsing="(19(?:0[012468]|1[09]|20|66|77|99))"
                carrierCodeFormattingRule="$CC $FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000030/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <leadingDigits>
       <mobile>
         <nationalNumberPattern>
           5(?:
-            0[0-4]|
-            7[01]
+            0[01]|
+            7[0-3]
+          )\d{5}|
+          6(?:
+            [0-2]\d|
+            30
           )\d{5}|
-          [67][0-2]\d{6}|
+          7[0-3]\d{6}|
           8[3-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>9001234567</exampleNumber>
       </premiumRate>
       <voip>
-        <!-- Including trunking service numbers starting with 5100. -->
+        <!-- Including trunking service numbers starting with 5100. 4001 (callmyway.com) was added
+             from an open-source bug report supported by numbers found online. -->
         <nationalNumberPattern>
           210[0-6]\d{4}|
           4(?:
             0(?:
-              [04]0\d{4}|
+              0[01]\d{4}|
               10[0-3]\d{3}|
               2(?:
-                00\d|
-                900
-              )\d{2}|
+                00\d{3}|
+                900\d{2}
+              )|
               3[01]\d{4}|
+              40\d{4}|
               5\d{5}|
+              60\d{4}|
               70[01]\d{3}|
               8[0-2]\d{4}
             )|
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>40001234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Cuba -->
-    <!-- www.itu.int/oth/T0202000033/en -->
     <territory id="CU" countryCode="53" internationalPrefix="119"
                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000033/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{6,7})">
           <leadingDigits>7</leadingDigits>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>51234567</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>10[456]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>106</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Cape Verde -->
-    <!-- http://www.itu.int/oth/T0202000026/en -->
     <territory id="CV" countryCode="238" internationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000026/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{2})(\d{2})">
           <format>$1 $2 $3</format>
         </nationalNumberPattern>
         <exampleNumber>9911234</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.capeverde.com/travel-tips/safety.html -->
-        <nationalNumberPattern>13[012]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>132</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Curaçao -->
-    <!-- http://www.itu.int/oth/T02020000F5/en -->
     <territory id="CW" countryCode="599" internationalPrefix="00" mainCountryForCode="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000F5/en</sourceUrl>
+      </references>
       <!-- All the formatting patterns for country-code 599 are here. -->
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
             [48]\d{2}|
             50\d|
             7(?:
-              2[0-2]|
+              2[0-24]|
               [34]\d|
               6[35-7]|
-              77
+              77|
+              8[7-9]
             )
           )\d{4}
         </nationalNumberPattern>
               3[01]
             )|
             6(?:
-              [1679]\d|
+              [16-9]\d|
               3[01]
             )
           )\d{4}
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>1011234</exampleNumber>
       </sharedCost>
-      <emergency>
-        <!-- http://www.rijksdienstcn.com/index.php?view=pagina&id=126&set_language=EN -->
-        <nationalNumberPattern>
-          112|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
-    </territory>
-
-    <!-- Cyprus -->
-    <!-- http://www.itu.int/oth/T0202000034/en -->
-    <territory id="CY" countryCode="357" internationalPrefix="00">
-      <availableFormats>
-        <!-- Format from http://www.cyprusyellowpages.com/-->
-        <numberFormat pattern="(\d{2})(\d{6})">
-          <format>$1 $2</format>
-        </numberFormat>
-      </availableFormats>
-      <generalDesc>
-        <nationalNumberPattern>[257-9]\d{7}</nationalNumberPattern>
-        <possibleNumberPattern>\d{8}</possibleNumberPattern>
-      </generalDesc>
-      <fixedLine>
-        <nationalNumberPattern>2[2-6]\d{6}</nationalNumberPattern>
-        <exampleNumber>22345678</exampleNumber>
-      </fixedLine>
-      <mobile>
-        <!-- Includes paging numbers (they are mixed into the same block). -->
-        <nationalNumberPattern>9[5-79]\d{6}</nationalNumberPattern>
-        <exampleNumber>96123456</exampleNumber>
-      </mobile>
-      <tollFree>
-        <nationalNumberPattern>800\d{5}</nationalNumberPattern>
-        <exampleNumber>80001234</exampleNumber>
-      </tollFree>
-      <premiumRate>
-        <nationalNumberPattern>90[09]\d{5}</nationalNumberPattern>
-        <exampleNumber>90012345</exampleNumber>
-      </premiumRate>
-      <sharedCost>
-        <nationalNumberPattern>80[1-9]\d{5}</nationalNumberPattern>
-        <exampleNumber>80112345</exampleNumber>
-      </sharedCost>
-      <personalNumber>
-        <nationalNumberPattern>700\d{5}</nationalNumberPattern>
-        <exampleNumber>70012345</exampleNumber>
-      </personalNumber>
-      <uan>
-        <!-- Using for Corporate Network numbers and Universal Service numbers. -->
-        <nationalNumberPattern>
-          (?:
-            50|
-            77
-          )\d{6}
-        </nationalNumberPattern>
-        <exampleNumber>77123456</exampleNumber>
-      </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Christmas Islands -->
     <!-- Metadata shared with Australia. -->
     <!-- References state Christmas Islands have fixed line numbers starting +61 8 9164. -->
-    <!-- http://en.wikipedia.org/wiki/List_of_country_calling_codes -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia -->
     <territory id="CX" countryCode="61" preferredInternationalPrefix="0011"
                internationalPrefix="(?:14(?:1[14]|34|4[17]|[56]6|7[47]|88))?001[14-689]"
                nationalPrefix="0">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/List_of_country_calling_codes</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Australia</sourceUrl>
+      </references>
       <!-- Uses AU formatting rules. -->
       <!-- General desc and fixed line rules different from Australia. -->
       <generalDesc>
       <!-- Mobile, toll free, premium rate, personal number and VOIP copied from Australia. -->
       <mobile>
         <nationalNumberPattern>
+          14(?:
+            5\d|
+            71
+          )\d{5}|
           4(?:
             [0-2]\d|
             3[0-57-9]|
             4[47-9]|
-            5[0-37-9]|
+            5[0-25-9]|
             6[6-9]|
-            7[07-9]|
-            8[7-9]
+            7[03-9]|
+            8[17-9]|
+            9[017-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>550123456</exampleNumber>
       </voip>
-      <emergency>
-        <!-- We assume this is the same as for Australia, since they have the same country code and
-             share their police force, and no better information can be found. -->
+    </territory>
+
+    <!-- Cyprus -->
+    <territory id="CY" countryCode="357" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000034/en</sourceUrl>
+      </references>
+      <availableFormats>
+        <!-- Format from http://www.cyprusyellowpages.com -->
+        <numberFormat pattern="(\d{2})(\d{6})">
+          <format>$1 $2</format>
+        </numberFormat>
+      </availableFormats>
+      <generalDesc>
+        <nationalNumberPattern>[257-9]\d{7}</nationalNumberPattern>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
+      </generalDesc>
+      <fixedLine>
+        <nationalNumberPattern>2[2-6]\d{6}</nationalNumberPattern>
+        <exampleNumber>22345678</exampleNumber>
+      </fixedLine>
+      <mobile>
+        <!-- Includes paging numbers (they are mixed into the same block). -->
+        <nationalNumberPattern>9[5-79]\d{6}</nationalNumberPattern>
+        <exampleNumber>96123456</exampleNumber>
+      </mobile>
+      <tollFree>
+        <nationalNumberPattern>800\d{5}</nationalNumberPattern>
+        <exampleNumber>80001234</exampleNumber>
+      </tollFree>
+      <premiumRate>
+        <nationalNumberPattern>90[09]\d{5}</nationalNumberPattern>
+        <exampleNumber>90012345</exampleNumber>
+      </premiumRate>
+      <sharedCost>
+        <nationalNumberPattern>80[1-9]\d{5}</nationalNumberPattern>
+        <exampleNumber>80112345</exampleNumber>
+      </sharedCost>
+      <personalNumber>
+        <nationalNumberPattern>700\d{5}</nationalNumberPattern>
+        <exampleNumber>70012345</exampleNumber>
+      </personalNumber>
+      <uan>
+        <!-- Using for Corporate Network numbers and Universal Service numbers. -->
         <nationalNumberPattern>
-          000|
-          112
+          (?:
+            50|
+            77
+          )\d{6}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
+        <exampleNumber>77123456</exampleNumber>
+      </uan>
     </territory>
 
     <!-- Czech Rep. -->
-    <!-- http://www.itu.int/oth/T0202000035/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B420 -->
-    <territory id="CZ" countryCode="420" internationalPrefix="00">
+    <territory id="CZ" countryCode="420" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000035/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B420</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([2-9]\d{2})(\d{3})(\d{3})">
           <leadingDigits>
         <possibleNumberPattern>\d{9,12}</possibleNumberPattern>
         <exampleNumber>93123456789</exampleNumber>
       </voicemail>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            5[058]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Germany -->
-    <!-- http://www.itu.int/oth/T0202000051/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_germany -->
     <territory id="DE" countryCode="49" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000051/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_germany</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Mobile number formatting rules. We follow the ITU document here for guidance on how
              these should best be formatted, even though actual usage varies. -->
           <leadingDigits>15</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
-        <numberFormat pattern="(\d{2})(\d{4,11})">
+        <numberFormat pattern="(\d{2})(\d{3,11})">
           <leadingDigits>
             3[02]|
             40|
             (?:
               18|
               90
-            )0
+            )0|
+            137
           </leadingDigits>
           <leadingDigits>
-            180|
+            1(?:
+              37|
+              80
+            )|
             900[1359]
           </leadingDigits>
           <format>$1 $2 $3</format>
           <leadingDigits>700</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
+        <numberFormat pattern="(138)(\d{4})">
+          <leadingDigits>138</leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
         <!-- When deciding whether to assume a leading 49 is a country code or not, the number is
               )|
               5\d{1,2}|
               6[1-8]\d?
-            )\d{2,7}
+            )\d{2,8}
           )
         </nationalNumberPattern>
         <possibleNumberPattern>\d{2,15}</possibleNumberPattern>
         <nationalNumberPattern>
           [246]\d{5,13}|
           3(?:
-            [03-9]\d{4,13}|
-            2\d{9}
+            0\d{3,13}|
+            2\d{9}|
+            [3-9]\d{4,13}
           )|
           5(?:
             0[2-8]|
         <!-- According to
              http://www.bundesnetzagentur.de/SharedDocs/Downloads/DE/BNetzA/Sachgebiete/Telekommunikation/Regulierung/Nummernverwaltung/Mobilfunkdienste/NummernplanMobileDienstepdf.pdf?__blob=publicationFile
              numbers beginning with 162, 163 and 17 can all be 10 or 11 digits long.
+             The ranges 15[056] have been removed from the ITU doc, but information found online
+             indicates that they may still be working.
              -->
         <nationalNumberPattern>
           1(?:
         <exampleNumber>8001234567890</exampleNumber>
       </tollFree>
       <premiumRate>
+        <!-- Includes the more expensive of the "televoting" line numbers. See the shared cost
+             section for more information. -->
         <nationalNumberPattern>
+          137[7-9]\d{6}|
           900(?:
             [135]\d{6}|
             9\d{7}
         <exampleNumber>9001234567</exampleNumber>
       </premiumRate>
       <sharedCost>
-        <nationalNumberPattern>180\d{5,11}</nationalNumberPattern>
-        <possibleNumberPattern>\d{8,14}</possibleNumberPattern>
+        <!-- Includes some mass-traffic numbers, used for e.g. phone voting, raffles, since their
+             costs when dialling from a fixed-line phone is similar.
+             Prices:
+             http://www.billiger-telefonieren.de/0180-0137-0900-sonderrufnummern/
+             Documentation:
+             http://www.bundesnetzagentur.de/SharedDocs/Downloads/DE/Sachgebiete/Telekommunikation/Unternehmen_Institutionen/Nummerierung/Rufnummern/0137/0137_Nummernplan.pdf?__blob=publicationFile&v=2
+        -->
+        <nationalNumberPattern>
+          1(?:
+            3(?:
+              7[1-6]\d{6}|
+              8\d{4}
+            )|
+            80\d{5,11}
+          )
+        </nationalNumberPattern>
+        <possibleNumberPattern>\d{7,14}</possibleNumberPattern>
         <exampleNumber>18012345</exampleNumber>
       </sharedCost>
       <personalNumber>
         <possibleNumberPattern>\d{12,13}</possibleNumberPattern>
         <exampleNumber>177991234567</exampleNumber>
       </voicemail>
-      <emergency>
-        <nationalNumberPattern>11[02]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Djibouti -->
-    <!-- http://www.itu.int/oth/T020200003A/en -->
     <territory id="DJ" countryCode="253" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200003A/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
         <nationalNumberPattern>77[6-8]\d{5}</nationalNumberPattern>
         <exampleNumber>77831001</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>1[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Denmark -->
-    <!-- http://www.dba.erhvervsstyrelsen.dk/numbering-lists -->
-    <territory id="DK" countryCode="45" internationalPrefix="00">
+    <territory id="DK" countryCode="45" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.dba.erhvervsstyrelsen.dk/numbering-lists</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
           (?:
             [2-7]\d|
             8[126-9]|
-            9[126-9]
+            9[1-36-9]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>32123456</exampleNumber>
           (?:
             [2-7]\d|
             8[126-9]|
-            9[126-9]
+            9[1-36-9]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>20123456</exampleNumber>
         <nationalNumberPattern>90\d{6}</nationalNumberPattern>
         <exampleNumber>90123456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Dominica -->
-    <!-- http://www.itu.int/oth/T020200003B/en -->
     <territory id="DM" countryCode="1" leadingDigits="767" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200003B/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[57-9]\d{9}</nationalNumberPattern>
               2[01]|
               4[0-25-9]
             )|
-            50[0-4]
+            50[0-4]|
+            70[1-3]
           )\d{4}
         </nationalNumberPattern>
         <exampleNumber>7674201234</exampleNumber>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
-        <exampleNumber>5002345678</exampleNumber>
-      </personalNumber>
-      <emergency>
-        <!-- http://barbados.usembassy.gov/emergency-dominica.html -->
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1102.html -->
-        <nationalNumberPattern>
-          333|
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
+        <exampleNumber>5002345678</exampleNumber>
+      </personalNumber>
     </territory>
 
     <!-- Dominican Rep. -->
-    <!-- http://www.itu.int/oth/T020200003C/en -->
     <territory id="DO" countryCode="1" leadingDigits="8[024]9" nationalPrefix="1"
-               internationalPrefix="011">
+               internationalPrefix="011" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200003C/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
    </territory>
 
     <!-- Algeria -->
-    <!-- http://www.itu.int/oth/T0202000003/en -->
-    <!-- www.arpt.dz -->
     <territory id="DZ" countryCode="213" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000003/en</sourceUrl>
+        <sourceUrl>http://www.arpt.dz</sourceUrl>
+      </references>
       <availableFormats>
-        <!-- Formatting from www.pagesjaunes-dz.com. -->
+        <!-- Formatting from http://www.pagesjaunes-dz.com. -->
         <numberFormat pattern="([1-4]\d)(\d{2})(\d{2})(\d{2})">
           <leadingDigits>[1-4]</leadingDigits>
           <format>$1 $2 $3 $4</format>
       </fixedLine>
       <mobile>
         <!-- Adding 65 and 78 from numbers found online. Also, prefix 670 is added since the carrier
-             Mobilis Algeria provided it, and 54 for Nedjma.-->
+             Mobilis Algeria provided it, and 54 for Nedjma. Prefixes 67[1-4] were also added for
+             Mobilis Algeria based on evidence found online. -->
         <nationalNumberPattern>
           (?:
             5[4-6]|
           )\d{7}|
           6(?:
             [569]\d|
-            70
+            7[0-4]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>983123456</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>1[47]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
    </territory>
 
     <!-- Ecuador -->
-    <!-- http://en.wikipedia.org/wiki/+593 -->
-    <!-- http://www.conatel.gob.ec/site_conatel/index.php?option=com_content&view=category&layout=blog&id=52&Itemid=153
-         -->
-    <!-- http://www.itu.int/oth/T020200003D/en -->
     <territory id="EC" countryCode="593" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
+               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/+593</sourceUrl>
+        <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>
+        <sourceUrl>http://www.itu.int/oth/T020200003D/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{3})(\d{4})">
           <leadingDigits>
           <intlFormat>$1-$2-$3</intlFormat>
         </numberFormat>
         <!-- Formatting for the new longer mobile numbers comes from the advertisements about the
-             change on the www.conatel.gob.ec site. -->
+             change on the http://www.conatel.gob.ec site. -->
         <numberFormat pattern="(\d{2})(\d{3})(\d{4})" nationalPrefixFormattingRule="$NP$FG">
           <leadingDigits>9</leadingDigits>
           <format>$1 $2 $3</format>
         <nationalNumberPattern>
           9(?:
             39|
-            [4-6][89]|
-            7[7-9]|
+            [45][89]|
+            [67][7-9]|
             [89]\d
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>28901234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[12]|
-            12
-          )|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Estonia -->
-    <!-- http://www.itu.int/oth/T0202000043/en -->
-    <!-- http://www.tja.ee/public/Legislation_side/Numbering_/Estonian_NP_eng.htm -->
-    <territory id="EE" countryCode="372" internationalPrefix="00">
+    <territory id="EE" countryCode="372" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000043/en</sourceUrl>
+        <sourceUrl>http://www.tja.ee/public/Legislation_side/Numbering_/Estonian_NP_eng.htm</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([3-79]\d{2})(\d{4})">
           <leadingDigits>
         <exampleNumber>8002123</exampleNumber>
       </noInternationalDialling>
       <fixedLine>
-        <!-- Supporting eFax numbers here as well. -->
         <nationalNumberPattern>
           (?:
             3[23589]|
-            4(?:
-              0\d|
-              [3-8]
-            )|
+            4[3-8]|
             6\d|
             7[1-9]|
             88
           )\d{5}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>3212345</exampleNumber>
       </fixedLine>
       <mobile>
         <exampleNumber>80012345</exampleNumber>
       </tollFree>
       <premiumRate>
-        <nationalNumberPattern>900\d{4}</nationalNumberPattern>
-        <possibleNumberPattern>\d{7}</possibleNumberPattern>
+        <!-- Supporting eFax numbers here as well. We aren't sure the exact cost, but have
+             had user reports that they are expensive to dial. -->
+        <nationalNumberPattern>
+          (?:
+            40\d{2}|
+            900
+          )\d{4}
+        </nationalNumberPattern>
+        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
         <exampleNumber>9001234</exampleNumber>
       </premiumRate>
       <personalNumber>
         <possibleNumberPattern>\d{4,5}</possibleNumberPattern>
         <exampleNumber>12123</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>11[02]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Egypt -->
-    <!-- http://www.itu.int/oth/T020200003E/en -->
     <territory id="EG" countryCode="20" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+       <references>
+         <sourceUrl>http://www.itu.int/oth/T020200003E/en</sourceUrl>
+       </references>
        <availableFormats>
          <!-- Note that no explicit formatting rule is here for 5-digit numbers starting with a 16
               or 19. These are formatted without national prefix, as a block, so do not need to be
          </numberFormat>
          <numberFormat pattern="(\d{2})(\d{6,7})">
            <leadingDigits>
-             1(?:
-               3|
-               5[23]
-             )|
+             1[35]|
              [4-6]|
              [89][2-9]
            </leadingDigits>
       <fixedLine>
         <!-- Short numbers used for businesses (starting with 16 or 19) are covered here. Note also
              that the plan says numbers starting with 15 should be followed by seven digit
-             subscriber numbers, but all numbers we have found online are in fact six digit.
+             subscriber numbers, but some numbers we have found online are in fact six digit.
              Subscriber numbers starting with 5 are also permitted for the area codes 040, with 5, 6
              and 7 for the area code 050, with 5 and 7 for 082, with 6 for 084, with 7 for 086 and
              092 and with 5 and 6 for 96. -->
         <nationalNumberPattern>
           (?:
-            1(
+            1(?:
               3[23]\d|
-              5[23]
+              5(?:
+                [23]|
+                9\d
+              )
             )|
             2[2-4]\d{2}|
             3\d{2}|
       <mobile>
         <!-- Adding the extra prefixes 102 and 121 from user reports that Vodafone and Mobinil have
              started allocating numbers beginning with these prefixes, along with 115 from numbers
-             found online. -->
+             found online. Etisalat is using 110. -->
         <nationalNumberPattern>
           1(?:
-            0[01269]|
-            1[1245]|
+            0[0-269]|
+            1[0-245]|
             2[0-278]
           )\d{7}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9001234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            2[23]|
-            80
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>122</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Western Sahara -->
     <!-- Country calling code shared with Morocco (MA). -->
     <!-- Two area codes are defined in the Morocco ITU document; 05288 XXXXX and 05289 XXXXX -->
-    <!-- http://www.itu.int/oth/T0202000090/en -->
     <territory id="EH" countryCode="212" leadingDigits="528[89]" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000090/en</sourceUrl>
+      </references>
       <!-- Uses MA formatting rules and shares general description
            (non-geographical numbers for Morocco are still valid). -->
       <generalDesc>
       <!-- The following sections are copied verbatim from Morocco to allow these non-geographical
            numbers to be recognized as available from within Western Sahara. -->
       <mobile>
-        <!-- Prefixes 60[1-578], 62[01457-9], 63[04-8] and 68[01] are from numbers found online,
-             bug-reports, and information provided directly by the carriers. -->
         <nationalNumberPattern>
           6(?:
             0[0-8]|
-            [124-7]\d|
-            3[03-8]|
-            8[01]|
-            99
+            [12-79]\d|
+            8[01]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>650123456</exampleNumber>
         <nationalNumberPattern>89\d{7}</nationalNumberPattern>
         <exampleNumber>891234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            [59]|
-            77
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Eritrea -->
-    <!-- http://www.itu.int/oth/T0202000042/en -->
     <territory id="ER" countryCode="291" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000042/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{3})(\d{3})">
           <format>$1 $2 $3</format>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>7123456</exampleNumber>
       </mobile>
-      <!-- No emergency numbers information can be found. -->
     </territory>
 
     <!-- Spain -->
-    <!-- http://www.mityc.es/telecomunicaciones/es-ES/Servicios/Numeracion/Paginas/Plan.aspx -->
-    <territory id="ES" countryCode="34" internationalPrefix="00">
+    <territory id="ES" countryCode="34" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.mityc.es/telecomunicaciones/es-ES/Servicios/Numeracion/Paginas/Plan.aspx</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([5-9]\d{2})(\d{2})(\d{2})(\d{2})">
+          <leadingDigits>
+            [568]|
+            [79][0-8]
+          </leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
       </availableFormats>
         <nationalNumberPattern>51\d{7}</nationalNumberPattern>
         <exampleNumber>511234567</exampleNumber>
       </uan>
-      <emergency>
-        <!-- We include the Civil Guard here since it seems to perform similar duties as the police
-             force. -->
-        <nationalNumberPattern>
-          0(?:
-            [69][12]|
-            8[05]
-          )|
-          112
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Ethiopia -->
-    <!-- http://www.itu.int/oth/T0202000044/en -->
     <territory id="ET" countryCode="251" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000044/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([1-59]\d)(\d{3})(\d{4})">
           <format>$1 $2 $3</format>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>911234567</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.addisculturetourism.gov.et/en/component/k2/itemlist/category/64.html?layout=category -->
-        <!-- http://www.netglobers.com/africa/ethiopia-emergency-numbers-in-ethiopia-.html -->
-        <!-- http://www.addisababacity.gov.et/index.php?option=com_content&view=article&id=139&Itemid=136 -->
-        <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-        <!-- The 91, 92, and 93 numbers are for the city of Addis Ababa. -->
-        <nationalNumberPattern>
-          9(?:
-            11?|
-            [23]|
-            9[17]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>991</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Finland -->
     <!-- Metadata shared with Åland (AX) -->
-    <!-- http://www.ficora.fi/en/index/palvelut/palvelutaiheittain/numerointi/numerotyypitjaalueet.html -->
     <territory id="FI" countryCode="358" internationalPrefix="00|99[049]" nationalPrefix="0"
-               nationalPrefixFormattingRule="$NP$FG" mainCountryForCode="true">
+               nationalPrefixFormattingRule="$NP$FG" mainCountryForCode="true"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.ficora.fi/en/index/palvelut/palvelutaiheittain/numerointi/numerotyypitjaalueet.html</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3,7})">
           <leadingDigits>
         </numberFormat>
         <numberFormat pattern="(\d{2})(\d{4,10})">
           <leadingDigits>
-            2[09]|
             [14]|
+            2[09]|
             50|
             7[135]
           </leadingDigits>
         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
         <exampleNumber>10112345</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Fiji -->
-    <!-- http://www.itu.int/oth/T0202000048/en -->
-    <!-- www.tfl.com.fj -->
     <territory id="FJ" countryCode="679" internationalPrefix="0(?:0|52)"
                preferredInternationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000048/en</sourceUrl>
+        <sourceUrl>http://www.tfl.com.fj</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>[36-9]</leadingDigits>
       <fixedLine>
         <!-- Adding the prefixes 30X, 31X and 62X, since numbers with these prefixes have been found
              online, including in the white pages. 35X and 85X were found in the exchanges listed on
-             www.tfl.com.fj. -->
+             http://www.tfl.com.fj. -->
         <nationalNumberPattern>
           (?:
             3[0-5]|
         <exampleNumber>3212345</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 7[67], 8[367], and 9[034678] from numbers found online and numbers where SMSs
+        <!-- Adding 7[5-8], 8[03679], and 9[034678] from numbers found online and numbers where SMSs
              have been received from. Adding 9[15] and 84 from Vodafone Fiji IR21. -->
         <nationalNumberPattern>
           (?:
-            7[0-467]|
-            8[3467]|
+            7[0-8]|
+            8[034679]|
             9\d
           )\d{5}
         </nationalNumberPattern>
         <exampleNumber>7012345</exampleNumber>
       </mobile>
       <tollFree>
-        <!-- Information found on www.tfl.com.fj. It is not clear if these are internationally
-             diallable, or if so, how. -->
+        <!-- Information found on http://www.tfl.com.fj. It is not clear if these are
+             internationally diallable, or if so, how. -->
         <nationalNumberPattern>0800\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{11}</possibleNumberPattern>
         <exampleNumber>08001234567</exampleNumber>
       </tollFree>
-      <emergency>
-        <nationalNumberPattern>91[17]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Falkland Islands (Malvinas) -->
-    <!-- http://www.itu.int/oth/T0202000046/en -->
     <territory id="FK" countryCode="500" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000046/en</sourceUrl>
+      </references>
       <!-- All numbers are formatted together, as a block. -->
       <generalDesc>
         <nationalNumberPattern>[2-7]\d{4}</nationalNumberPattern>
         <nationalNumberPattern>[56]\d{4}</nationalNumberPattern>
         <exampleNumber>51234</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Micronesia, Federated States of -->
-    <!-- http://www.itu.int/oth/T020200008B/en -->
     <territory id="FM" countryCode="691" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200008B/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         </nationalNumberPattern>
         <exampleNumber>3501234</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_971.html -->
-        <nationalNumberPattern>
-          911|
-          320221
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}(?:\d{3})?</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Faroe Islands -->
-    <!-- http://www.itu.int/oth/T0202000047/en -->
     <territory id="FO" countryCode="298" internationalPrefix="00"
                nationalPrefixForParsing="(10(?:01|[12]0|88))"
                carrierCodeFormattingRule="$CC $FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000047/en</sourceUrl>
+      </references>
       <!-- All numbers are formatted together, as a block. -->
       <availableFormats>
         <numberFormat pattern="(\d{6})">
         </nationalNumberPattern>
         <exampleNumber>601234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- France -->
-    <!-- http://www.itu.int/oth/T020200004A/en -->
-    <!-- http://www.arcep.fr/index.php?id=8146 -->
-    <!-- http://en.wikipedia.org/wiki/%2B33 -->
-    <territory id="FR" countryCode="33" internationalPrefix="[04579]0"
-               preferredInternationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
-      <!-- 4-digit premium-rate numbers will be formatted as a block without a national prefix. -->
+    <territory id="FR" countryCode="33" internationalPrefix="00" nationalPrefix="0"
+               nationalPrefixFormattingRule="$NP$FG" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200004A/en</sourceUrl>
+        <sourceUrl>http://www.arcep.fr/index.php?id=8146</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B33</sourceUrl>
+      </references>
+      <!-- Short numbers will be formatted as a block without a national prefix. -->
       <availableFormats>
         <numberFormat pattern="([1-79])(\d{2})(\d{2})(\d{2})(\d{2})">
           <leadingDigits>[1-79]</leadingDigits>
           <format>$1 $2 $3 $4 $5</format>
         </numberFormat>
+        <numberFormat pattern="(1\d{2})(\d{3})" nationalPrefixFormattingRule="$FG">
+          <leadingDigits>11</leadingDigits>
+          <format>$1 $2</format>
+          <intlFormat>NA</intlFormat>
+        </numberFormat>
         <numberFormat nationalPrefixFormattingRule="$NP $FG"
           pattern="(8\d{2})(\d{2})(\d{2})(\d{2})">
           <leadingDigits>8</leadingDigits>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>
-          [124-9]\d{8}|
-          3\d{3}(?:\d{5})?
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{4}(?:\d{5})?</possibleNumberPattern>
+        <nationalNumberPattern>[1-9]\d{8}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
       </generalDesc>
-      <noInternationalDialling>
-        <nationalNumberPattern>3\d{3}</nationalNumberPattern>
-        <possibleNumberPattern>\d{4}</possibleNumberPattern>
-        <exampleNumber>3123</exampleNumber>
-      </noInternationalDialling>
       <fixedLine>
         <nationalNumberPattern>[1-5]\d{8}</nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>123456789</exampleNumber>
       </fixedLine>
       <mobile>
           6\d{8}|
           7[5-9]\d{7}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>612345678</exampleNumber>
       </mobile>
       <tollFree>
         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>801234567</exampleNumber>
       </tollFree>
       <premiumRate>
-        <!-- We are putting 4-digit premium-rate numbers here for now, since they are used by
-             agencies such as CPAM and the national unemployment agency. -->
-        <nationalNumberPattern>
-          3\d{3}|
-          89[1-37-9]\d{6}
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{4}(?:\d{5})?</possibleNumberPattern>
+        <nationalNumberPattern>89[1-37-9]\d{6}</nationalNumberPattern>
         <exampleNumber>891123456</exampleNumber>
       </premiumRate>
       <sharedCost>
             90
           )\d{6}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>810123456</exampleNumber>
       </sharedCost>
       <voip>
         <!-- 087 numbers used to be used for this. -->
         <nationalNumberPattern>9\d{8}</nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>912345678</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            [578]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Gabon -->
-    <!-- http://www.itu.int/oth/T020200004E/en -->
-    <!-- www.arcep.ga -->
-    <territory id="GA" countryCode="241" internationalPrefix="00" leadingZeroPossible="true">
+    <!-- Note: We cannot set nationalPrefix="0" while fixed line numbers can start with a zero
+         as this breaks parsing (it treats all leading zeros as national prefixes. -->
+    <territory id="GA" countryCode="241" internationalPrefix="00" leadingZeroPossible="true" >
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200004E/en</sourceUrl>
+        <sourceUrl>http://www.arcep.ga</sourceUrl>
+      </references>
       <availableFormats>
-        <numberFormat pattern="(0\d)(\d{2})(\d{2})(\d{2})">
+        <!-- If no leading zero was supplied, format with the national prefix. -->
+        <numberFormat pattern="(\d)(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="0$FG">
+          <leadingDigits>[2-7]</leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
+        <!-- This already has a leading zero so we format is "as is". -->
+        <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
+          <leadingDigits>0</leadingDigits>
+         <format>$1 $2 $3 $4</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>0\d{7}</nationalNumberPattern>
-        <possibleNumberPattern>\d{8}</possibleNumberPattern>
+        <nationalNumberPattern>0?\d{7}</nationalNumberPattern>
+        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
       </generalDesc>
       <!-- A 7-digit fixed-line plan was scheduled to be implemented on June 17, 2012 to unify fixed
-           line and mobile numbering. However, it seems that this has not happened; their own
-           website now lists numbers as "+241 01 44 68 11" and upon ringing numbers they will not
-           connect without the 0 from outside the country. This was last tested June 2013. -->
+           line and mobile numbering. However, this has only partially happened; mobile numbers can
+           now be dialed without a leading zero, but fixed line numbers still require it. Their own
+           website still lists fixed line numbers as "+241 01 44 68 11" and upon ringing they will
+           not connect from outside the country without the 0. This was last tested March 2014. -->
       <fixedLine>
         <nationalNumberPattern>01\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>01441234</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>0[2-7]\d{6}</nationalNumberPattern>
+        <!-- Mobile numbers can be 7 or 8 digits (with or without a leading zero). -->
+        <nationalNumberPattern>0?[2-7]\d{6}</nationalNumberPattern>
         <exampleNumber>06031234</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>
-          1730|
-          18|
-          13\d{2}
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,4}</possibleNumberPattern>
-        <exampleNumber>1730</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- United Kingdom -->
-    <!-- http://stakeholders.ofcom.org.uk/telecoms/numbering/ -->
-    <!-- http://en.wikipedia.org/wiki/List_of_United_Kingdom_dialling_codes -->
-    <!-- http://www.numberingplans.com/?page=dialling&sub=areacodes&ac=GB -->
     <!-- Note that this excludes Isle of Man, Jersey and Guernsey prefixes for the purposes of
          validation, although the formatting rules are shared. -->
     <territory id="GB" countryCode="44" internationalPrefix="00"
                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG"
-               mainCountryForCode="true">
+               mainCountryForCode="true" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://stakeholders.ofcom.org.uk/telecoms/numbering/</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/List_of_United_Kingdom_dialling_codes</sourceUrl>
+        <sourceUrl>http://www.numberingplans.com/?page=dialling&amp;sub=areacodes&amp;ac=GB</sourceUrl>
+      </references>
       <availableFormats>
         <!-- 2d, 55, 56, 70 and 76 pager numbers (excludes 7624) with 10 digits. -->
         <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5512345678</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Grenada -->
-    <!-- http://www.itu.int/oth/T0202000057/en -->
     <territory id="GD" countryCode="1" leadingDigits="473" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000057/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[4589]\d{9}</nationalNumberPattern>
               58|
               84
             )|
+            800|
             938
           )\d{4}
         </nationalNumberPattern>
         <nationalNumberPattern>
           473(?:
             4(?:
-              0[3-79]|
+              0[2-79]|
               1[04-9]|
               20|
               58
             )|
-            53[3-8]
+            5(?:
+              2[01]|
+              3[3-8]
+            )|
+            901
           )\d{4}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://barbados.usembassy.gov/emergency-grenada.html -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Georgia -->
-    <!-- http://www.itu.int/oth/T0202000050/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Georgia. -->
-    <territory id="GE" countryCode="995" preferredInternationalPrefix="8~10"
-               internationalPrefix="810" nationalPrefix="8">
+    <territory id="GE" countryCode="995" internationalPrefix="00" nationalPrefix="0"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000050/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Georgia_(country)</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Format isn't very strictly defined - the yellow pages omits area code and does 2 2 2,
              the communications commission uses 2 3 3. Wikipedia says 3 2 3. Some use 2 6. -->
-        <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="$NP $FG">
+        <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="$NP$FG">
           <leadingDigits>[348]</leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
-        <numberFormat pattern="(\d{3})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP $FG">
+        <numberFormat pattern="(\d{3})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
           <leadingDigits>7</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>555123456</exampleNumber>
       </mobile>
-      <!-- Information from www.yell.ge, examples such as Wissol Petroleum Georgia hotline. -->
+      <!-- Information from http://www.yell.ge, examples such as Wissol Petroleum Georgia
+           hotline. -->
       <tollFree>
         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
       </voip>
       <!-- It seems there may be special 6 digit numbers beginning with 91, but we are not sure, so
            these are omitted for now. -->
-      <emergency>
-        <!-- According to Wikipedia, 011, 022 and 033 will be replaced by 111, 122, 113 and 114 in
-             2011. We are not sure if that has happened, so we support both versions for now. -->
-        <nationalNumberPattern>
-          0(?:
-            11|
-            22|
-            33
-          )|
-          1(?:
-            1[123]|
-            22
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- French Guiana (French Dept. of) -->
-    <!-- http://www.itu.int/oth/T020200004C/en -->
-    <!-- http://www.arcep.fr/index.php?id=2137&bloc=0594&CMD=RESULTS_NUMEROTATION -->
-    <!-- http://www.arcep.fr/uploads/tx_gsavis/11-1297.pdf -->
-    <!-- Using a national prefix here as online numbers are formatted with it.  -->
+    <!-- Using a national prefix here as online numbers are formatted with it. -->
     <territory id="GF" countryCode="594" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200004C/en</sourceUrl>
+        <sourceUrl>http://www.arcep.fr/index.php?id=2137&amp;bloc=0594&amp;CMD=RESULTS_NUMEROTATION</sourceUrl>
+        <sourceUrl>http://www.arcep.fr/uploads/tx_gsavis/11-1297.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
       <!-- The 876 prefix is mentioned in the plan, but the plan is from 2006 and in France VOIP
            numbers were changed from 087 to the 09 prefix in 2009. It is likely this occurred here
            too. -->
-      <emergency>
-        <nationalNumberPattern>1[578]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Guernsey -->
     <!-- Inherits formatting rules from the UK. -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom -->
     <territory id="GG" countryCode="44" internationalPrefix="00"
                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom</sourceUrl>
+      </references>
       <generalDesc>
         <nationalNumberPattern>[135789]\d{6,9}</nationalNumberPattern>
         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5512345678</exampleNumber>
       </uan>
-      <emergency>
-        <!-- http://en.wikipedia.org/wiki/Guernsey#Emergency_services -->
-        <nationalNumberPattern>
-          112|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Ghana -->
-    <!-- http://www.itu.int/oth/T0202000052/en -->
-    <!-- http://www.nca.org.gh/index.php?option=com_content&view=article&id=90&Itemid=65 -->
     <territory id="GH" countryCode="233" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000052/en</sourceUrl>
+        <sourceUrl>http://www.nca.org.gh/index.php?option=com_content&amp;view=article&amp;id=90&amp;Itemid=65</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
           <leadingDigits>[235]</leadingDigits>
       <mobile>
         <nationalNumberPattern>
           (?:
-            2[034678]|
-            5[047]
-          )\d{7}
+            2[034678]\d|
+            5(?:
+              [047]\d|
+              54|
+              6[01]
+            )
+          )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>231234567</exampleNumber>
         <exampleNumber>80012345</exampleNumber>
       </tollFree>
       <!-- No premiumRate information can be found. -->
-      <emergency>
-        <nationalNumberPattern>
-          19[123]|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Gibraltar -->
     <territory id="GI" countryCode="350" internationalPrefix="00">
-      <!-- No formatting rules - numbers are always formatted as a block. -->
+      <references>
+        <sourceUrl>http://www.gra.gi/index.php?topic=numbering+plan&amp;section=legislation&amp;site=communications</sourceUrl>
+      </references>
+      <availableFormats>
+        <!-- Most numbers are formatted as a block -->
+        <numberFormat pattern="(\d{3})(\d{5})">
+          <leadingDigits>2</leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+      </availableFormats>
       <generalDesc>
         <nationalNumberPattern>[2568]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <nationalNumberPattern>
           2(?:
             00\d|
-            16[0-7]|
-            22[2457]
+            1(?:
+              6[24-7]|
+              9\d
+            )|
+            2(?:
+              00|
+              2[2457]
+            )
           )\d{4}
         </nationalNumberPattern>
         <exampleNumber>20012345</exampleNumber>
       <mobile>
         <nationalNumberPattern>
           (?:
-            5[4-8]|
-            60
+            5[46-8]|
+            62
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>57123456</exampleNumber>
         <nationalNumberPattern>87\d{6}</nationalNumberPattern>
         <exampleNumber>87123456</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            9[09]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Greenland -->
-    <!-- http://www.itu.int/oth/T0202000056/en -->
     <territory id="GL" countryCode="299" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000056/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3</format>
         <nationalNumberPattern>3[89]\d{4}</nationalNumberPattern>
         <exampleNumber>381234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Gambia -->
-    <!-- http://www.itu.int/oth/T020200004F/en -->
     <territory id="GM" countryCode="220" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200004F/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
       <mobile>
         <nationalNumberPattern>
           (?:
-            2[0-2]|
+            2[0-6]|
             [3679]\d
           )\d{5}
         </nationalNumberPattern>
         <exampleNumber>3012345</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1121.html -->
-        <!-- http://www.netglobers.com/africa/gambia-emergency-numbers-in-the-gambia.html -->
-        <nationalNumberPattern>1?1[678]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>117</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Guinea -->
-    <!-- http://www.itu.int/oth/T020200005B/en -->
     <territory id="GN" countryCode="224" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200005B/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <leadingDigits>3</leadingDigits>
         <exampleNumber>30241234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Limited to the new 9-digit mobile ranges, which came into effect March 29th 2013. -->
-        <nationalNumberPattern>
-          6(?:
-            [03]1|
-            2[128]|
-            5[57]|
-            6[2469]
-          )\d{6}
-        </nationalNumberPattern>
+        <!-- Prefixes here match those assigned to carriers, as per the ITU communication Jan 23rd
+             2013. -->
+        <nationalNumberPattern>6[02356]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>601123456</exampleNumber>
       </mobile>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>722123456</exampleNumber>
       </voip>
-      <!-- No national emergency numbers were located for Guinea. -->
     </territory>
 
     <!-- Guadeloupe -->
-    <!-- http://www.itu.int/oth/T0202000058/en -->
-    <!-- http://www.arcep.fr/index.php?id=interactivenumeros - ZABPQ-ZNE.xls -->
     <territory id="GP" countryCode="590" internationalPrefix="00"
                mainCountryForCode="true" nationalPrefix="0"
                nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000058/en</sourceUrl>
+        <!-- Linked from http://www.arcep.fr/index.php?id=interactivenumeros -->
+        <sourceUrl>http://www.arcep.fr/fileadmin/reprise/dossiers/numero/ZABPQ-ZNE.xls</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([56]90)(\d{2})(\d{4})">
           <format>$1 $2-$3</format>
         </nationalNumberPattern>
         <exampleNumber>690301234</exampleNumber>
       </mobile>
-      <!-- http://www.guadeloupe.franceantilles.fr/pratique/urgences/numeros-urgence-guadeloupe-14950.php -->
-      <emergency>
-        <nationalNumberPattern>1[578]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>18</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Equatorial Guinea -->
-    <!-- http://www.itu.int/oth/T0202000041/en -->
     <territory id="GQ" countryCode="240" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000041/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
           <leadingDigits>[235]</leadingDigits>
         <nationalNumberPattern>90\d[1-9]\d{5}</nationalNumberPattern>
         <exampleNumber>900123456</exampleNumber>
       </premiumRate>
-      <!-- No national emergency numbers were located for Equatorial Guinea. -->
     </territory>
 
     <!-- Greece -->
-    <!-- http://www.itu.int/oth/T0202000055/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B30 -->
-    <territory id="GR" countryCode="30" internationalPrefix="00">
+    <territory id="GR" countryCode="30" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000055/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B30</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([27]\d)(\d{4})(\d{4})">
           <leadingDigits>
           2(?:
             1\d{2}|
             2(?:
+              2[1-46-9]|
               3[1-8]|
               4[1-7]|
               5[1-4]|
               6[1-8]|
               7[1-5]|
-              [289][1-9]
+              [89][1-9]
             )|
             3(?:
               1\d|
               2[1-57]|
-              3[1-4]|
-              [45][1-3]|
+              [35][1-3]|
+              4[13]|
               7[1-7]|
-              8[1-6]|
+              8[124-6]|
               9[1-79]
             )|
             4(?:
             )|
             5(?:
               1\d|
-              [239][1-4]|
+              [29][1-4]|
+              3[1-5]|
               4[124]|
               5[1-6]
             )|
             6(?:
               1\d|
-              3[124]|
+              3[1245]|
               4[1-7]|
               5[13-9]|
               [269][1-6]|
               3[1-6]|
               4[1-7]|
               5[1-57]|
-              6[134]|
-              9[15-7]
+              6[135]|
+              9[125-7]
             )|
             8(?:
               1\d|
               2[1-5]|
               [34][1-4]|
-              9[1-7]
+              9[1-57]
             )
           )\d{6}
         </nationalNumberPattern>
         <nationalNumberPattern>70\d{8}</nationalNumberPattern>
         <exampleNumber>7012345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            00|
-            12|
-            66|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Guatemala -->
-    <!-- http://www.itu.int/oth/T020200005A/en -->
-    <!-- http://www.sit.gob.gt/index.php?page=plan-de-numeracion -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Guatemala -->
     <territory id="GT" countryCode="502" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200005A/en</sourceUrl>
+        <sourceUrl>http://www.sit.gob.gt/index.php?page=plan-de-numeracion</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Guatemala</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <leadingDigits>[2-7]</leadingDigits>
         <possibleNumberPattern>\d{11}</possibleNumberPattern>
         <exampleNumber>19001112222</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            10|
-            2[03]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>110</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Guam -->
-    <!-- http://www.nationalnanpa.com/nas/public/assigned_code_query_step1.do?method=resetCodeQueryModel -->
     <territory id="GU" countryCode="1" leadingDigits="671" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.nationalnanpa.com/nas/public/assigned_code_query_step1.do?method=resetCodeQueryModel</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://www.justice.gov.gu/compileroflaws/gca/10gca/10gc084.PDF -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Guinea-Bissau -->
-    <!-- http://www.itu.int/oth/T020200005C/en -->
     <territory id="GW" countryCode="245" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200005C/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[3567]\d{6}</nationalNumberPattern>
+        <nationalNumberPattern>[3-79]\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
         <exampleNumber>3201234</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>[5-7]\d{6}</nationalNumberPattern>
+        <nationalNumberPattern>
+          (?:
+            [5-7]\d|
+            9[012]
+          )\d{5}
+        </nationalNumberPattern>
         <exampleNumber>5012345</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- https://www.osac.gov/pages/ContentReportDetails.aspx?cid=10970 -->
-        <nationalNumberPattern>11[378]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>113</exampleNumber>
-      </emergency>
+      <voip>
+        <nationalNumberPattern>40\d{5}</nationalNumberPattern>
+        <exampleNumber>4012345</exampleNumber>
+      </voip>
     </territory>
 
     <!-- Guyana -->
-    <!-- http://www.itu.int/oth/T020200005D/en -->
     <territory id="GY" countryCode="592" internationalPrefix="001">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200005D/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         <nationalNumberPattern>9008\d{3}</nationalNumberPattern>
         <exampleNumber>9008123</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>91[123]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Hong Kong -->
-    <!-- http://www.ofca.gov.hk/en/industry_focus/telecommunications/portability/index.html -->
-    <territory id="HK" countryCode="852" internationalPrefix="00">
+    <territory id="HK" countryCode="852" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.ofca.gov.hk/en/industry_focus/telecommunications/portability/index.html</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <leadingDigits>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>81123456</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          99[29]
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
    </territory>
 
     <!-- Honduras -->
-    <!-- http://www.itu.int/oth/T020200005F/en -->
     <!-- It seems there is no longer a trunk prefix in use, based on websites like
          http://www.howtocallabroad.com/codes.html and on seeing how locals write their numbers in
          national format. -->
     <territory id="HN" countryCode="504" internationalPrefix="00" >
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200005F/en</sourceUrl>
+      </references>
       <availableFormats>
        <numberFormat pattern="(\d{4})(\d{4})">
          <format>$1-$2</format>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Extra prefixes 228X and 2292 were added from numbers found online.  -->
+        <!-- Extra prefixes 227[01389], 228X, 2292 & 260X were added from numbers found online. -->
         <nationalNumberPattern>
           2(?:
             2(?:
               [23]\d|
               4[056]|
               5[57]|
+              7[01389]|
               8[0146-9]|
               9[012]
             )|
             4(?:
-              2|3-59]|
+              2[3-59]|
               3[13-689]|
               4[0-68]|
               5[1-35]
               74
             )|
             6(?:
+              [056]\d|
               4[0-378]|
-              [56]\d|
               [78][0-8]|
               9[01]
             )|
         <nationalNumberPattern>[37-9]\d{7}</nationalNumberPattern>
         <exampleNumber>91234567</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>199</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>199</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Croatia -->
-    <!-- http://www.itu.int/oth/T0202000032/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B385 -->
     <territory id="HR" countryCode="385" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000032/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B385</sourceUrl>
+      </references>
       <availableFormats>
         <!-- The plan says 1 XXX XXXX but the government and local telecom websites are formatted 1
              XXXX XXX, so we prefer that formatting here. These same sources prefer XXX XXX to XX
         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
         <exampleNumber>741234567</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            92
-          )|
-          9[34]
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Haiti -->
-    <!-- http://www.itu.int/oth/T020200005E/en -->
-    <!-- http://www.numberingplans.com/ -->
     <territory id="HT" countryCode="509" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200005E/en</sourceUrl>
+        <sourceUrl>http://www.numberingplans.com/</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{4})">
           <format>$1 $2 $3</format>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>98901234</exampleNumber>
       </voip>
-      <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-      <emergency>
-        <nationalNumberPattern>11[48]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>118</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Hungary -->
-    <!-- http://www.itu.int/oth/T0202000061/en -->
     <territory id="HU" countryCode="36" internationalPrefix="00"
-               nationalPrefix="06" nationalPrefixFormattingRule="($FG)">
+               nationalPrefix="06" nationalPrefixFormattingRule="($FG)"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000061/en</sourceUrl>
+      </references>
       <!-- Although the national prefix is necessary for dialling, the preferred format (confirmed
            by a Hungarian person and following the yellow pages) is to omit this when formatting.
-           Yellow pages: www.aranyoldalak.hu -->
+           Yellow pages: http://www.aranyoldalak.hu -->
       <availableFormats>
         <numberFormat pattern="(1)(\d{3})(\d{4})">
           <leadingDigits>1</leadingDigits>
         <nationalNumberPattern>[1-9]\d{7,8}</nationalNumberPattern>
         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
       </generalDesc>
+      <noInternationalDialling>
+        <nationalNumberPattern>[48]0\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
+        <exampleNumber>80123456</exampleNumber>
+      </noInternationalDialling>
       <fixedLine>
         <!-- Includes numbers for corporate networks. -->
         <nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>40123456</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[457]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Indonesia -->
-    <!-- http://www.itu.int/oth/T0202000064/en (from 2001, very out-of-date) -->
-    <!-- http://en.wikipedia.org/wiki/%2B62 -->
     <territory id="ID" countryCode="62" internationalPrefix="0(?:0[1789]|10(?:00|1[67]))"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <!-- From 2001, very out of date. -->
+        <sourceUrl>http://www.itu.int/oth/T0202000064/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B62</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
-          pattern="(\d{2})(\d{7,8})">
+          pattern="(\d{2})(\d{5,8})">
           <leadingDigits>
             2[124]|
             [36]1
           <format>$1 $2</format>
         </numberFormat>
         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
-          pattern="(\d{3})(\d{5,7})">
+          pattern="(\d{3})(\d{5,8})">
           <leadingDigits>
             [4579]|
             2[035-9]|
           <leadingDigits>800</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
-        <numberFormat pattern="(809)(\d)(\d{3})(\d{3})">
-          <leadingDigits>809</leadingDigits>
+        <numberFormat pattern="(80\d)(\d)(\d{3})(\d{3})">
+          <leadingDigits>80[79]</leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
       </availableFormats>
              http://www.telkom.co.id/customer-services/area-and-country-code/?type=area.
              We also added 0770 after user feedback because it seems to be used on Bintan island.
              Where known, fixed mobile prefixes have been represented as Mobile. -->
+        <!-- Very short (5/6 digit) local numbers in Jakarta seem to be special cases for various
+             well known companies (Mc Donalds, KFC etc...). Some of these are listed in:
+             http://cms.binus.edu/datapage/file/io/Spring2014SE/International_Student_Handbook_BINUS.pdf
+             There seem to be numbers of this length for area code 22 as well based on numbers found
+             online. -->
         <nationalNumberPattern>
           2(?:
             1(?:
+              14\d{3}|
               [0-8]\d{6,7}|
+              500\d{3}|
               9\d{6}
             )|
-            [24]\d{7,8}
+            2\d{6,8}|
+            4\d{7,8}
           )|
           (?:
             2(?:
               4[1-6]
             )|
             7(?:
-              1[1-46-9]|
+              1[1-9]|
               2[14-9]|
               [36]\d|
               4[1-8]|
             )
           )\d{5,8}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
+        <possibleNumberPattern>\d{5,11}</possibleNumberPattern>
         <exampleNumber>612345678</exampleNumber>
       </fixedLine>
       <mobile>
         <possibleNumberPattern>\d{8,11}</possibleNumberPattern>
         <exampleNumber>8001234567</exampleNumber>
       </tollFree>
-      <!-- The infomation below is provided by an Indonesian -->
+      <uan>
+        <nationalNumberPattern>8071\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{10}</possibleNumberPattern>
+        <exampleNumber>8071123456</exampleNumber>
+      </uan>
+      <noInternationalDialling>
+        <nationalNumberPattern>8071\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{10}</possibleNumberPattern>
+        <exampleNumber>8071123456</exampleNumber>
+      </noInternationalDialling>
+      <!-- The information below is provided by an Indonesian -->
       <premiumRate>
         <nationalNumberPattern>809\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>8091234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>11[02389]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Ireland -->
-    <!-- http://www.comreg.ie/licensing_and_services/numbering_plan_for_ireland.552.440.html -->
-    <!-- http://www.comreg.ie/_fileupload/publications/ComReg1119.pdf -->
     <territory id="IE" countryCode="353" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
+               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.comreg.ie/licensing_and_services/numbering_plan_for_ireland.552.440.html</sourceUrl>
+        <sourceUrl>http://www.comreg.ie/_fileupload/publications/ComReg1119.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(1)(\d{3,4})(\d{4})">
           <leadingDigits>1</leadingDigits>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>8501234567</exampleNumber>
       </voicemail>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Israel -->
-    <!-- http://www.itu.int/oth/T020200006A/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B972 -->
-    <!-- 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
-         (in Hebrew) -->
     <!-- Formatting practice following wikipedia, and government sites. -->
     <territory id="IL" countryCode="972" internationalPrefix="0(?:0|1[2-9])"
-               nationalPrefix="0" nationalPrefixFormattingRule="$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200006A/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B972</sourceUrl>
+        <!-- in Hebrew -->
+        <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>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="$NP$FG"
           pattern="([2-489])(\d{3})(\d{4})">
           5(?:
             [02347-9]\d{2}|
             5(?:
+              01|
               2[23]|
               3[34]|
               4[45]|
               5[5689]|
               6[67]|
               7[78]|
-              8[89]
+              8[89]|
+              9[7-9]
             )|
             6[2-9]\d
           )\d{5}
             47\d|
             6(?:
               5\d|
-              8[08]
+              8[068]
             )|
             7\d{2}|
             8(?:
         <exampleNumber>771234567</exampleNumber>
       </voip>
       <uan>
-        <!-- 4-digit star numbers 1-599 numbers. The latter are actually labelled "interactive
+        <!-- 4-digit star numbers and 1-599 numbers. The latter are actually labelled "interactive
              voicemail" in the ITU document, but according to reports from businesses in Israel and
              the Hebrew version of the wikipedia page, these are actually a router for business
              calls, and incur a normal call cost on account of the caller. -->
         <possibleNumberPattern>\d{4}(?:\d{6})?</possibleNumberPattern>
         <exampleNumber>1599123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[012]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Isle of Man -->
     <!-- Inherits formatting rules from the UK. -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom -->
     <territory id="IM" countryCode="44" internationalPrefix="00"
                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom</sourceUrl>
+      </references>
       <generalDesc>
         <nationalNumberPattern>[135789]\d{6,9}</nationalNumberPattern>
         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5512345678</exampleNumber>
       </uan>
-      <emergency>
-        <!-- http://www.directory.im/directory_useful.aspx -->
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- India -->
-    <!-- http://www.dot.gov.in/numbering_plan/numberplanindex.htm -->
-    <!-- http://www.itu.int/oth/T0202000063/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B91 -->
-    <!-- http://www.coai.in/msccodes.php -->
     <!-- Note that several changes in area codes have occurred since the numbering plan was released
-         - fixed line changes are notified on the www.bsnl.co.in website. Area codes can be verified
-           here at http://dq.ndc.bsnl.co.in/bsnl-web/stdSearch.seam. -->
+         - fixed line changes are notified on the http://www.bsnl.co.in website. Area codes can be
+         verified here at http://dq.ndc.bsnl.co.in/bsnl-web/stdSearch.seam. -->
     <territory id="IN" countryCode="91" internationalPrefix="00" nationalPrefix="0"
-               nationalPrefixFormattingRule="$NP$FG" nationalPrefixOptionalWhenFormatting="true" >
+               nationalPrefixFormattingRule="$NP$FG" nationalPrefixOptionalWhenFormatting="true"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000063/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B91</sourceUrl>
+        <sourceUrl>http://www.coai.in/msccodes.php</sourceUrl>
+      </references>
        <availableFormats>
          <!-- Mobile numbers. -->
-         <numberFormat pattern="(\d{2})(\d{2})(\d{6})">
+         <numberFormat pattern="(\d{5})(\d{5})">
            <leadingDigits>
              7(?:
+               0[2-9]|
                2[0579]|
                3[057-9]|
                4[0-389]|
-               5[024-9]|
                6[0-35-9]|
-               7|
+               [57]|
                8[0-79]
              )|
              8(?:
                2[2356-9]|
                3[0-57-9]|
                [45]|
-               6[0245789]|
+               6[02457-9]|
                7[1-69]|
                8[0124-9]|
                9[02-9]
            </leadingDigits>
            <leadingDigits>
              7(?:
+               0(?:
+                 2[2-9]|
+                 [3-8]|
+                 9[0-8]
+               )|
                2(?:
                  0[04-9]|
                  5[09]|
                  8[389]
                )|
                5(?:
-                 0|
-                 [47]9|
-                 [25]0|
-                 6[6-9]|
-                 [89][7-9]
+                 [034678]|
+                 2[03-9]|
+                 5[017-9]|
+                 9[7-9]
                )|
                6(?:
-                 0[027]|
-                 12|
-                 20|
+                 0[0-27]|
+                 1[0-257-9]|
+                 2[0-4]|
                  3[19]|
-                 5[45]|
-                 6[5-9]|
-                 7[679]|
-                 9[1-46-9]
+                 5[4589]|
+                 [6-9]
                )|
                7(?:
                  0[2-9]|
              )|
              9
            </leadingDigits>
-           <format>$1 $2 $3</format>
+           <format>$1 $2</format>
          </numberFormat>
          <!-- 2 digits area code -->
          <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
                2[1-47]|
                3[15]|
                5[12]|
-               6[126-9]|
+               6[0-26-9]|
                7[0-24-9]|
                8[013-57]|
                9[014-7]
          <numberFormat pattern="(\d{4})(\d{3})(\d{3})">
            <leadingDigits>
              1(?:
-               [2-579]|
-               [68][1-9]
+               [23579]|
+               [468][1-9]
              )|
              [2-8]
            </leadingDigits>
            <leadingDigits>18[06]0</leadingDigits>
            <format>$1 $2 $3</format>
          </numberFormat>
+         <numberFormat nationalPrefixFormattingRule="$FG"
+           pattern="(140)(\d{3})(\d{4})">
+           <leadingDigits>140</leadingDigits>
+           <format>$1 $2 $3</format>
+         </numberFormat>
          <!-- Televoting numbers. Formatting information is from
               http://www.bsnl.co.in/service/telev.htm -->
          <numberFormat nationalPrefixFormattingRule="$FG"
                 [12]\d{9}
               )
             )
-           )
+          )
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8,13}</possibleNumberPattern>
         <exampleNumber>1800123456</exampleNumber>
               2[1-47]|
               3[15]|
               5[12]|
-              6[126-9]|
+              6[0-26-9]|
               7[0-24-9]|
               8[013-57]|
               9[014-7]
                 3[2-4]|
                 4[235-7]|
                 [57][2-689]|
-                6[24-58]|
+                6[24-578]|
                 8[1-6]
               )|
               8(?:
         <!-- A couple of additional prefixes found neither on the wikipedia page nor in the MSC
              codes list, are added because SMS messages have been successfully sent to these
              numbers. It seems almost impossible to know for some of these numbers whether they are
-             land-line or mobile, since the ranges overlap. Extra prefixes added: 8299, 8309.
-             New prefixes were added based on the document provided from mobile carriers:
-             https://code.google.com/p/libphonenumber/issues/detail?id=260 -->
+             land-line or mobile, since the ranges overlap. Extra prefixes added: 7601, 768[567],
+             7695, 8299, 8309. New prefixes were also added based on the document provided from
+             mobile carriers: https://code.google.com/p/libphonenumber/issues/detail?id=260 -->
         <nationalNumberPattern>
           (?:
             7(?:
+              0(?:
+                2[2-9]|
+                [3-8]\d|
+                9[0-8]
+              )|
               2(?:
                 0[04-9]|
                 5[09]|
                 8[389]
               )|
               5(?:
-                0\d|
-                [47]9|
-                [25]0|
-                6[6-9]|
-                [89][7-9]
+                [034678]\d|
+                2[03-9]|
+                5[017-9]|
+                9[7-9]
               )|
               6(?:
-                0[027]|
-                12|
-                20|
+                0[0127]|
+                1[0-257-9]|
+                2[0-4]|
                 3[19]|
-                5[45]|
-                6[5-9]|
-                7[679]|
-                9[1-46-9]
+                5[4589]|
+                [6-9]\d
               )|
               7(?:
                 0[2-9]|
         <possibleNumberPattern>\d{13}</possibleNumberPattern>
         <exampleNumber>1861123456789</exampleNumber>
       </premiumRate>
-      <uan>
+      <sharedCost>
+        <!-- While described as "universal numbers" in the numbering plan, evidence suggests
+             that 1860 number are best described as shared cost. See "Call Local Service" in:
+             http://www.tatadocomo.com/corporates/toll-free.aspx -->
         <nationalNumberPattern>1860\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{11}</possibleNumberPattern>
         <exampleNumber>18603451234</exampleNumber>
+      </sharedCost>
+      <uan>
+        <!-- Telemarketing numbers: http://en.wikipedia.org/wiki/Telephone_numbers_in_India -->
+        <nationalNumberPattern>140\d{7}</nationalNumberPattern>
+        <possibleNumberPattern>\d{10}</possibleNumberPattern>
+        <exampleNumber>1409305260</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[0128]|
-            12|
-            298
-          )|
-          2611
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3,4}</possibleNumberPattern>
-        <exampleNumber>108</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- British Indian Ocean Territory / Diego Garcia -->
-    <!-- http://www.itu.int/oth/T0202000039/en -->
     <territory id="IO" countryCode="246" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000039/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         <nationalNumberPattern>38\d{5}</nationalNumberPattern>
         <exampleNumber>3801234</exampleNumber>
       </mobile>
-      <!-- It seems that there are no emergency numbers for this island. -->
     </territory>
 
     <!-- Iraq -->
-    <!-- http://en.wikipedia.org/wiki/%2B964 -->
-    <!-- http://wtng.info/wtng-964-ik.html -->
     <territory id="IQ" countryCode="964" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B964</sourceUrl>
+        <sourceUrl>http://wtng.info/wtng-964-ik.html</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(1)(\d{3})(\d{4})">
           <leadingDigits>1</leadingDigits>
         <exampleNumber>7912345678</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <!-- No national emergency numbers were located for Iraq. -->
     </territory>
 
     <!-- Iran, Islamic Republic of -->
-    <!-- http://en.wikipedia.org/wiki/%2B98 -->
-    <!-- http://www.itu.int/oth/T0202000066/en -->
-    <!-- http://www.tct.ir/?siteid=1&pageid=195 -->
-    <!-- http://118.tct.ir/citycode.htm -->
     <territory id="IR" countryCode="98" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B98</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T0202000066/en</sourceUrl>
+        <sourceUrl>http://www.tct.ir/?siteid=1&amp;pageid=195</sourceUrl>
+        <sourceUrl>http://118.tct.ir/citycode.htm</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formatting follows wikipedia. -->
-        <numberFormat pattern="(2[15])(\d{3,5})">
-          <!-- We exclude the 255 and 256 prefixes, which do not belong to Qom as of yet. -->
-          <leadingDigits>
-            2(?:
-              1|
-              5[0-47-9]
-            )
-          </leadingDigits>
+        <numberFormat pattern="(21)(\d{3,5})">
+          <leadingDigits>21</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
-        <numberFormat pattern="(2[15])(\d{3})(\d{3,4})">
-          <leadingDigits>
-            2(?:
-              1|
-              5[0-47-9]
-            )
-          </leadingDigits>
-          <format>$1 $2 $3</format>
-        </numberFormat>
-        <numberFormat pattern="(2\d)(\d{4})(\d{4})">
-          <leadingDigits>
-            2(?:
-              [16]|
-              5[0-47-9]
-            )
-          </leadingDigits>
+        <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
+          <leadingDigits>[1-8]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
-          <leadingDigits>
-            [13-9]|
-            2[02-57-9]
-          </leadingDigits>
+          <leadingDigits>9</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat pattern="(\d{3})(\d{2})(\d{2,3})">
-          <leadingDigits>
-            [13-9]|
-            2[02-57-9]
-          </leadingDigits>
+          <leadingDigits>9</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat pattern="(\d{3})(\d{3})">
-          <leadingDigits>
-            [13-9]|
-            2[02-57-9]
-          </leadingDigits>
+          <leadingDigits>9</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
-          [14-8]\d{6,9}|
-          [23]\d{4,9}|
+          [1-8]\d{9}|
           9(?:
-            [1-4]\d{8}|
+            [0-4]\d{8}|
             9\d{2,8}
           )
         </nationalNumberPattern>
         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- We are following the more specific lengths specified in the communication in the ITU
-             doc of 26.VIII.2012, rather than the brief summary lengths (which actually contradict).
-             The prefixes have been verified by looking at the Persian telecommunications site.
-             22[189], 29[12] have become 21, as part of the shift to unify prefixes. 746 was also
-             found on the website at http://www.tct.ir/?siteid=1&pageid=410&siteid=1 but this seems
-             to be a typo. It seems Qom is moving to 025, but 0255 and 0256 have not yet been
-             migrated away from under this prefix - in the meantime, support for 253 has been added
-             since this has been found in numbers online. -->
+        <!-- In Summer 2014 Iran unified all fixed phone numbers in the following way:
+             Each province is assigned a two digit prefix (except for North Khorasan which has 3).
+             Within each province, all numbers are exactly eight digits.  The expression below is
+             organized by province.  For each province we accept all eight-digit combinations.
+
+             11 Mazandaran
+             13 Gilan
+             17 Golestan
+             21 Tehran
+             23 Semnan
+             24 Zanjan
+             25 Qom
+             26 Alborz
+             28 Qazvin
+             31 Isfahan
+             34 Kerman
+             35 Yazd
+             38 Chahar Mahaal and Bakhtiari
+             41 East Azerbaijan
+             44 West Azerbaijan
+             45 Ardabil
+             51 Razavi Khorasan
+             54 Sistan and Baluchestan
+             56 South Khorasan
+             57 North Khorasan (Extras)
+             58 North Khorasan
+             61 Khuzestan
+             64 North Khorasan (Extras)
+             66 Lorestan
+             71 Fars
+             74 Kohgiluyeh and Boyer-Ahmad
+             76 Hormozgan
+             77 Bushehr
+             81 Hamadan
+             83 Kermanshah
+             84 Ilam
+             86 Markazi
+             87 Kurdistan
+             -->
         <nationalNumberPattern>
-          1(?:
-            [13-589][12]|
-            [27][1-4]
-          )\d{7}|
-          2(?:
-            1\d{3,8}|
-            3[12]\d{7}|
-            4(?:
-              1\d{4,7}|
-              2\d{7}
-            )|
-            5(?:
-              1\d{3,7}|
-              [2356]\d{7}
-            )|
-            6\d{8}|
-            7[34]\d{7}|
-            [89][12]\d{7}
-          )|
-          3(?:
-            1(?:
-              1\d{4,7}|
-              2\d{7}
-            )|
-            2[1-4]\d{7}|
-            3(?:
-              [125]\d{7}|
-              4\d{6,7}
-            )|
-            4(?:
-              1\d{6,7}
-              [24-9]\d{7}
-            )|
-            5(?:
-              1\d{4,7}|
-              [23]\d{7}
-            )|
-            [6-9][12]\d{7}
-          )|
-          4(?:
-            [135-9][12]\d{7}|
-            2[1-467]\d{7}|
-            4(?:
-              1\d{4,7}|
-              [2-4]\d{7}
-            )
-          )|
-          5(?:
-            1(?:
-              1\d{4,7}|
-              2\d{7}
-            )|
-            2[89]\d{7}|
-            3[1-5]\d{7}|
-            4(?:
-              1\d{4,7}|
-              [2-8]\d{7}
-            )|
-            [5-7][12]\d{7}|
-            8[1245]\d{7}
-          )|
-          6(?:
-            1(?:
-              1\d{6,7}|
-              2\d{7}
-            )|
-            [347-9][12]\d{7}|
-            5(?:
-              1\d{7}|
-              2\d{6,7}
-            )|
-            6[1-6]\d{7}
-          )|
-          7(?:
-            [13589][12]|
-            2[1289]|
-            4[1-4]|
-            6[1-6]|
-            7[1-3]
-          )\d{7}|
-          8(?:
-            [145][12]|
-            3[124578]|
-            6[1256]|
-            7[1245]
-          )\d{7}
+          (?:
+            1[137]|
+            2[13-68]|
+            3[1458]|
+            4[145]|
+            5[146-8]|
+            6[146]|
+            7[1467]|
+            8[13467]
+          )\d{8}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
+        <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>2123456789</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>9[1-3]\d{8}</nationalNumberPattern>
+        <nationalNumberPattern>
+          9(?:
+            0[12]|
+            [1-3]\d
+          )\d{7}
+        </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9123456789</exampleNumber>
       </mobile>
         <nationalNumberPattern>9990\d{0,6}</nationalNumberPattern>
         <exampleNumber>9990123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1[025]|
-            25
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Iceland -->
-    <!-- http://www.pta.is/default.aspx?cat_id=85 -->
-    <!-- http://www.pfs.is/default.aspx?cat_id=14&module_id=210&element_id=4 -->
-    <territory id="IS" countryCode="354" internationalPrefix="00">
+    <territory id="IS" countryCode="354" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.pta.is/default.aspx?cat_id=85</sourceUrl>
+        <sourceUrl>http://www.pfs.is/default.aspx?cat_id=14&amp;module_id=210&amp;element_id=4</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>[4-9]</leadingDigits>
         <nationalNumberPattern>
           (?:
             4(?:
-              [14][0-245]|
+              1[0-24-6]|
               2[0-7]|
               [37][0-8]|
+              4[0-245]|
               5[0-3568]|
               6\d|
               8[0-36-8]
       <mobile>
         <!-- TETRA = TErrestrial Trunked RAdio is included under mobile. -->
         <nationalNumberPattern>
-          38[59]\d{6}|
+          38[589]\d{6}|
           (?:
             6(?:
-              1[0-8]|
-              3[0-27-9]|
-              4[0-27]|
-              5[0-29]|
+              1[1-8]|
+              3[089]|
+              4[0167]|
+              5[019]|
               [67][0-69]|
               9\d
             )|
             7(?:
               5[057]|
               7\d|
-              8[0-3]
+              8[0-36-8]
             )|
             8(?:
               2[0-5]|
+              3[0-4]|
               [469]\d|
               5[1-9]
             )
           )\d{4}
         </nationalNumberPattern>
-        <exampleNumber>6101234</exampleNumber>
+        <exampleNumber>6111234</exampleNumber>
       </mobile>
       <tollFree>
+        <!-- The UIFN numbers mentioned in the Excel document are not yet included since no real
+             numbers can be found online, and it is not clear what these are; the standard
+             definition would have them under the +800 country code instead of Iceland. -->
         <nationalNumberPattern>800\d{4}</nationalNumberPattern>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>8001234</exampleNumber>
         <exampleNumber>9011234</exampleNumber>
       </premiumRate>
       <voip>
-        <nationalNumberPattern>49[0-24-79]\d{4}</nationalNumberPattern>
+        <nationalNumberPattern>49\d{5}</nationalNumberPattern>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>4921234</exampleNumber>
       </voip>
       <voicemail>
         <nationalNumberPattern>
-          388\d{6}|
           (?:
             6(?:
               2[0-8]|
               49|
               8\d
             )|
-            8(?:
-              2[6-9]|
-              [38]\d|
-              50|
-              7[014-9]
-            )|
+            87[0189]|
             95[48]
           )\d{4}
         </nationalNumberPattern>
-        <exampleNumber>388123456</exampleNumber>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
+        <exampleNumber>6201234</exampleNumber>
       </voicemail>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Italy -->
-    <!-- http://en.wikipedia.org/wiki/%2B39 -->
-    <territory id="IT" countryCode="39" internationalPrefix="00" leadingZeroPossible="true">
+    <territory id="IT" countryCode="39" internationalPrefix="00" leadingZeroPossible="true"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B39</sourceUrl>
+      </references>
       <availableFormats>
         <!-- The leading zero for fixed numbers will be prepended before the matching of these
              regular expressions. -->
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5512345678</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>11[2358]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Jersey -->
     <!-- Inherits formatting rules from the UK. -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom -->
-    <!-- http://www.jcra.je/cms3/v2/public/cmsChild.asp?pageID=1024&childID=1036 -->
     <territory id="JE" countryCode="44" internationalPrefix="00"
                nationalPrefix="0" preferredExtnPrefix=" x" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_the_United_Kingdom</sourceUrl>
+        <sourceUrl>http://www.jcra.je/cms3/v2/public/cmsChild.asp?pageID=1024&amp;childID=1036</sourceUrl>
+      </references>
       <generalDesc>
         <nationalNumberPattern>[135789]\d{6,9}</nationalNumberPattern>
         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5512345678</exampleNumber>
       </uan>
-      <emergency>
-        <!-- http://en.wikipedia.org/wiki/Jersey#Emergency_services -->
-        <nationalNumberPattern>
-          112|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Jamaica -->
-    <!-- http://www.itu.int/oth/T020200006C/en -->
     <territory id="JM" countryCode="1" leadingDigits="876" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200006C/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Numbers have been found online for ranges 62x,63x, 656, 66[2-489]. -->
+        <!-- Numbers have been found online for ranges 62x,63x, 656, 66[2-589]. -->
         <nationalNumberPattern>
           876(?:
             5(?:
               [23]\d|
               40|
               5[06]|
-              6[2-489]|
+              6[2-589]|
               7[05]|
               8[04]|
               9[4-9]
       </fixedLine>
       <mobile>
         <!-- Adding 27, 28, 299, 31, 508, 527 and 566 as extra prefixes, as they have been found to
-             be valid by sending SMSs and looking at online number lookup sites.
+             be valid by sending SMSs and looking at online number lookup sites. Also added 50[3-79]
+             as we have found information online that the 50[3-9] range has been assigned to Digicel.
 
              Numbers have been found online for the following ranges 29x, 53x, 54x, 55x, 56x.
              Most have mobile numbers online so we have put them under mobile but is possible
             2[1789]\d|
             [348]\d{2}|
             5(?:
-              08|
+              0[3-9]|
               27|
               6[0-24-9]|
               [3-578]\d
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>11[09]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>119</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Jordan -->
-    <!-- http://www.trc.gov.jo/images/stories/pdf/NNP_ver200[1].pdf?lang=english -->
-    <!-- http://www.itu.int/oth/T020200006E/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B962 -->
     <territory id="JO" countryCode="962" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.trc.gov.jo/images/stories/pdf/NNP_ver200[1].pdf?lang=english</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T020200006E/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B962</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
           pattern="(\d)(\d{3})(\d{4})">
                 3[0-57-8]|
                 4[24-7]|
                 5[0-24-8]|
-                [6-9][02]
+                [6-8][02]|
+                9[0-2]
               )|
               7(?:
                 0[1-79]|
               1[1-35-7]|
               2[024-7]|
               3\d|
-              [457][02]|
+              4[0-2]|
+              [57][02]|
               60
             )|
             53(?:
-              [013][02]|
+              0[0-2]|
+              [13][02]|
               2[0-59]|
               49|
               5[0-35-9]|
           7(?:
             55|
             7[25-9]|
-            8[5-9]|
-            9[05-9]
+            8[05-9]|
+            9[015-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>88101234</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            91
-          )|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Japan -->
-    <!-- http://www.soumu.go.jp/main_sosiki/joho_tsusin/top/tel_number/number_shitei.html -->
-    <!-- http://www.numberingplans.com/?page=dialling&sub=areacodes&ac=JP -->
     <territory id="JP" countryCode="81" internationalPrefix="010" nationalPrefix="0"
-               nationalPrefixFormattingRule="$NP$FG" leadingZeroPossible="true" >
+               nationalPrefixFormattingRule="$NP$FG" leadingZeroPossible="true"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.soumu.go.jp/main_sosiki/joho_tsusin/top/tel_number/number_shitei.html</sourceUrl>
+        <sourceUrl>http://www.numberingplans.com/?page=dialling&amp;sub=areacodes&amp;ac=JP</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Toll-free, premium-rate and UAN numbers -->
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
           <leadingDigits>800</leadingDigits>
           <format>$1-$2-$3</format>
         </numberFormat>
-        <!-- National-only toll-free numbers (0077 and 0088) and VOIP numbers (0037) where the
-             leading "0" is considered the national prefix. -->
-        <numberFormat pattern="(\d{3})(\d{4})">
-          <leadingDigits>077</leadingDigits>
+        <!-- National-only toll-free numbers (0037, 0066, 0077 and 0088). -->
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{4})">
+          <leadingDigits>0077</leadingDigits>
           <format>$1-$2</format>
+          <intlFormat>NA</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(\d{3})(\d{2})(\d{3,4})">
-          <leadingDigits>077</leadingDigits>
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{2})(\d{3,4})">
+          <leadingDigits>0077</leadingDigits>
           <format>$1-$2-$3</format>
+          <intlFormat>NA</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(\d{3})(\d{2})(\d{4})">
-          <leadingDigits>088</leadingDigits>
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{2})(\d{4})">
+          <leadingDigits>0088</leadingDigits>
           <format>$1-$2-$3</format>
+          <intlFormat>NA</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{3})(\d{3,4})">
           <leadingDigits>
-            0(?:
-              37|
-              66
+            00(?:
+               37|
+               66
             )
           </leadingDigits>
           <format>$1-$2-$3</format>
+          <intlFormat>NA</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(\d{3})(\d{4})(\d{4,5})">
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{4})(\d{4,5})">
           <leadingDigits>
-            0(?:
-              37|
-              66
+            00(?:
+               37|
+               66
             )
           </leadingDigits>
           <format>$1-$2-$3</format>
+          <intlFormat>NA</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(\d{3})(\d{5})(\d{5,6})">
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{5})(\d{5,6})">
           <leadingDigits>
-            0(?:
-              37|
-              66
+            00(?:
+               37|
+               66
             )
           </leadingDigits>
           <format>$1-$2-$3</format>
+          <intlFormat>NA</intlFormat>
         </numberFormat>
-        <numberFormat pattern="(\d{3})(\d{6})(\d{6,7})">
+        <numberFormat nationalPrefixFormattingRule="$FG" pattern="(\d{4})(\d{6})(\d{6,7})">
           <leadingDigits>
-            0(?:
-              37|
-              66
+            00(?:
+               37|
+               66
             )
           </leadingDigits>
           <format>$1-$2-$3</format>
+          <intlFormat>NA</intlFormat>
         </numberFormat>
         <!-- Some leading digits are explicitly reserved for a particular purpose.
              We handle them first in this rule, and let the following rules ignore those exceptions.
       <generalDesc>
         <nationalNumberPattern>
           [1-9]\d{8,9}|
-          0(?:
-            [36]\d{7,14}|
-            7\d{5,7}|
-            8\d{7}
+          00(?:
+             [36]\d{7,14}|
+             7\d{5,7}|
+             8\d{7}
           )
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{7,16}</possibleNumberPattern>
+        <possibleNumberPattern>\d{8,17}</possibleNumberPattern>
       </generalDesc>
       <noInternationalDialling>
         <!-- Toll-free numbers with a leading "00" cannot be dialled internationally. -->
         <nationalNumberPattern>
-          0(?:
-            37\d{6,13}|
-            66\d{6,13}|
-            777(?:
-              [01]\d{2}|
-              5\d{3}|
-              8\d{4}
-            )|
-            882[1245]\d{4}
+          00(?:
+             37\d{6,13}|
+             66\d{6,13}|
+             777(?:
+               [01]\d{2}|
+               5\d{3}|
+               8\d{4}
+             )|
+             882[1245]\d{4}
           )
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{7,16}</possibleNumberPattern>
-        <exampleNumber>0777012</exampleNumber>
+        <exampleNumber>00777012</exampleNumber>
       </noInternationalDialling>
       <fixedLine>
         <nationalNumberPattern>
         <exampleNumber>312345678</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>
-          (?:
-            [79]0\d|
-            80[1-9]
-          )\d{7}
-        </nationalNumberPattern>
+        <nationalNumberPattern>[7-9]0[1-9]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>7012345678</exampleNumber>
       </mobile>
         <nationalNumberPattern>
           120\d{6}|
           800\d{7}|
-          0(?:
-            37\d{6,13}|
-            66\d{6,13}|
-            777(?:
-              [01]\d{2}|
-              5\d{3}|
-              8\d{4}
-            )|
-            882[1245]\d{4}
+          00(?:
+             37\d{6,13}|
+             66\d{6,13}|
+             777(?:
+               [01]\d{2}|
+               5\d{3}|
+               8\d{4}
+             )|
+             882[1245]\d{4}
           )
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{7,16}</possibleNumberPattern>
         <exampleNumber>120123456</exampleNumber>
       </tollFree>
       <premiumRate>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>570123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>11[09]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>110</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Kenya -->
-    <!-- http://www.cck.go.ke/licensing/numbering/plan.html -->
-    <!-- http://en.wikipedia.org/wiki/+254 -->
     <territory id="KE" countryCode="254" internationalPrefix="000"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.cck.go.ke/licensing/numbering/plan.html</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+254</sourceUrl>
+      </references>
       <availableFormats>
-        <numberFormat pattern="(\d{2})(\d{4,7})">
+        <numberFormat pattern="(\d{2})(\d{5,7})">
           <leadingDigits>[24-6]</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
           20\d{6,7}|
           [4-9]\d{6,9}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
+        <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- The prefix 066 is supposed to be used only for 9-digit numbers, but none of these can
-             be found online, and the plan says also it is migrating to 9 digit numbers. Both are
-             supported for now. -->
+        <!-- The prefixes 046, 050, 058, and 066 may appear online in less than 9 digits but
+             calling them has confirmed these are outdated. However a 7-digit 068 number was
+             dialed successfully so we consider these valid despite the plan. -->
         <nationalNumberPattern>
           20\d{6,7}|
           4(?:
-            [013]\d{7}|
-            [24-6]\d{5,7}
+            [0136]\d{7}|
+            [245]\d{5,7}
           )|
           5(?:
-            [0-36-8]\d{5,7}|
-            [459]\d{5}
+            [08]\d{7}|
+            [1-79]\d{5,7}
           )|
           6(?:
-            [08]\d{5}|
-            [14-79]\d{5,7}|
-            2\d{7}
+            [01457-9]\d{5,7}|
+            [26]\d{7}
           )
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{5,9}</possibleNumberPattern>
+        <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
         <exampleNumber>202012345</exampleNumber>
       </fixedLine>
       <mobile>
         <nationalNumberPattern>
           7(?:
-            0[0-8]|
-            [123]\d|
+            [0-36]\d|
             5[0-6]|
             7[0-5]|
-            8[5-9]
+            8[0-25-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
       </mobile>
       <tollFree>
         <!-- Longer numbers have been found than the plan suggests, so we support them here too. -->
+        <!-- The plan suggests 0844 and 0845 may belong here, but these are short numbers rather
+             than prefixes:
+             http://www.telkomkenya.8k.com/Products/v/2.html
+             http://www.kenya-advisor.com/phone-calls-kenya.html
+             http://www.telkom.co.ke/index.php?option=com_content&view=article&id=64&Itemid=98 -->
         <nationalNumberPattern>800[24-8]\d{5,6}</nationalNumberPattern>
         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
         <exampleNumber>800223456</exampleNumber>
       </tollFree>
       <premiumRate>
-        <nationalNumberPattern>900[02-578]\d{5}</nationalNumberPattern>
+        <nationalNumberPattern>900[02-9]\d{5}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>900223456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <!-- http://www.kenyapolice.go.ke/report_a_crime.asp -->
-        <nationalNumberPattern>
-          112|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Kyrgyzstan -->
-    <!-- http://www.itu.int/oth/T0202000074/en -->
     <territory id="KG" countryCode="996" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000074/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
           <leadingDigits>
-            31[25]|
-            [5-7]
+            [25-7]|
+            31[25]
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[35-8]\d{8,9}</nationalNumberPattern>
+        <nationalNumberPattern>[235-8]\d{8,9}</nationalNumberPattern>
         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Extra area codes found on Web Search: 3147, 3150, 3948. -->
+        <!-- Extra area codes found on Web Search: 3147. -->
         <nationalNumberPattern>
           (?:
             3(?:
               1(?:
-                2\d|
+                [256]\d|
                 3[1-9]|
-                47|
-                5[02]|
-                6[1-8]
+                47
               )|
               2(?:
                 22|
               4(?:
                 22|
                 5[6-9]|
-                6[0-4]
+                6\d
               )|
               5(?:
                 22|
                 3[4-7]|
                 59|
-                6[0-5]
+                6\d
               )|
               6(?:
                 22|
                 5[35-7]|
-                6[0-3]
+                6\d
               )|
               7(?:
                 22|
                 3[468]|
                 4[1-9]|
                 59|
-                6\d|
-                7[5-7]
+                [67]\d
               )|
               9(?:
                 22|
                 4[1-8]|
-                6[0-8]
+                6\d
               )
             )|
             6(?:
         <exampleNumber>312123456</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Added 70[1235789] since SMS messages have been successfully sent to numbers with this
-             prefix, and numbers have been found like this online.  -->
         <nationalNumberPattern>
-          5[124-7]\d{7}|
-          7(?:
-            0[0-357-9]|
-            7\d
+          (?:
+            20[0-35]|
+            5[124-7]\d|
+            7[07]\d
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
       </tollFree>
       <!-- No premiumRate information can be found. -->
       <!-- http://www.iru-nelti.org/index/info-app/id.216 -->
-      <emergency>
-        <nationalNumberPattern>10[123]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>101</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Cambodia -->
-    <!-- http://www.itu.int/oth/T0202000023/en -->
-    <!-- http://en.wikipedia.org/wiki/+855 -->
     <territory id="KH" countryCode="855" internationalPrefix="00[14-9]"
                nationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000023/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+855</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})" nationalPrefixFormattingRule="$NP$FG">
           <leadingDigits>
              started issuing fixed-line numbers like this. Apparently, mobile-company-issued
              fixed-line numbers are one digit longer than government-issued numbers. Moreover, the
              range beginning with 6 seems to include some numbers that are one digit longer as well.
-             Allowing 23[48]\d{6} and [456]3\d{7} based on information from Cambodia Yellow Pages.
-             Note that numbers with these prefixes may match more than one group. -->
+             Allowing 238\d{6} and 234[234]\d{4} based on information from Cambodia Yellow Pages.
+             Note that numbers beginning with 234 are split across two patterns. -->
         <nationalNumberPattern>
           (?:
             2[3-6]|
             3[2-6]|
             4[2-4]|
-            [567][2-5]
+            [5-7][2-5]
           )(?:
-            [2-47-9]|
+            [237-9]|
+            4[56]|
             5\d|
             6\d?
           )\d{5}|
-          (?:
-            23[48]|
-            [456]3\d|
-          )\d{6}
+          23(?:
+            4[234]|
+            8\d{2}
+          )\d{4}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
-        <exampleNumber>23456789</exampleNumber>
+        <exampleNumber>23756789</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 86 and 87 from numbers found online, along with 88 (the 88 numbers seem to be
-             one digit longer as well.) Adding 97 followed by 7 digits as such numbers have been
-             found online. Adding 14 as Mobitel have informed us they are using this prefix. Adding
-             60[1-9] based on information received from Beeline, and 857 and 61 from Cellcard.
-             Allowing 9-digit 12, 31, and 76 numbers based on information from Cambodia Yellow
-             Pages. -->
+        <!-- SMART uses prefixes 01[056], 070, 08[167] and 09[368].
+             Beeline uses 060.
+             Mobitel uses 01[1247].
+             Cellcard uses 0857 and 061.
+             Extra prefixes found online: 088, 097.
+             Allowing 9-digit 12, 31, 38 and 76 numbers based on information from Cambodia Yellow
+             Pages and online search. -->
         <nationalNumberPattern>
           (?:
-            (?:
-              1\d|
-              6[016-9]|
-              7[07-9]|
-            )[1-9]|
-            (?:
-              12|
-              31|
-              76
-            )[1-9]\d|
+            1(?:
+              [013-9]|
+              2\d?
+            )|
+            3[18]\d|
+            6[016-9]|
+            7(?:
+              [07-9]|
+              6\d
+            )|
             8(?:
-              0[89]|
-              [134679]\d|
-              5[2-9]|
-              8\d{2}
+              [013-79]|
+              8\d
             )|
             9(?:
-              [0-589][1-9]|
-              [67][1-9]\d?
+              6\d|
+              7\d?|
+              [0-589]
             )
-          )\d{5}
+          )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
         <exampleNumber>91234567</exampleNumber>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>1900123456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <!-- http://www.phnompenh.gov.kh/phnom-penh-city-emergency-numbers-24-hrs-169.html -->
-        <nationalNumberPattern>
-          11[789]|
-          666
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>117</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Kiribati -->
-    <!-- http://www.itu.int/oth/T0202000071/en -->
     <!-- We include the national prefix for parsing here just in case numbers can be dialled with a
-         leading 0 - the main ITU document says this is not the case and no numbers online have been
-         found formatted this way, but Kiribati's own document lists it as a national dialling
-         prefix. -->
+         leading 0 - no numbers online have been found formatted this way, but the ITU document
+         lists it as a national dialling prefix. -->
     <territory id="KI" countryCode="686" internationalPrefix="00"
                nationalPrefixForParsing="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000071/en</sourceUrl>
+      </references>
       <!-- Numbers should be formatted as a block." -->
       <generalDesc>
-        <nationalNumberPattern>[2-689]\d{4}</nationalNumberPattern>
-        <possibleNumberPattern>\d{5}</possibleNumberPattern>
+        <nationalNumberPattern>
+          [2458]\d{4}|
+          3\d{4,7}|
+          7\d{7}
+        </nationalNumberPattern>
+        <possibleNumberPattern>\d{5,8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
         <nationalNumberPattern>
           (?:
-            [234]\d|
+            [24]\d|
+            3[1-9]|
             50|
-            8[1-5]
+            8[0-5]
           )\d{3}
         </nationalNumberPattern>
+        <possibleNumberPattern>\d{5}</possibleNumberPattern>
         <exampleNumber>31234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Exclude 99[2349] from mobile since these are emergency numbers. -->
+        <!-- North Tarawa is listed as 720XXXXX-729XXXXX but considering that this deviates from the
+             pattern followed by every other place, we are assuming 731XXXXX-732XXXXX for now. -->
         <nationalNumberPattern>
-          6\d{4}|
-          9(?:
-            [0-8]\d|
-            9[015-8]
-          )\d{2}
+          7(?:
+            [24]\d|
+            3[1-9]|
+            8[0-5]
+          )\d{5}
         </nationalNumberPattern>
-        <exampleNumber>61234</exampleNumber>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
+        <exampleNumber>72012345</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- www.tskl.net.ki/directory.pdf -->
-        <nationalNumberPattern>99[2349]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
+      <premiumRate>
+        <!-- ITU refers to these as "Telemedia and audiotext". -->
+        <nationalNumberPattern>3001\d{4}</nationalNumberPattern>
+        <exampleNumber>30010000</exampleNumber>
+      </premiumRate>
     </territory>
 
     <!-- Comoros -->
-    <!-- http://www.itu.int/oth/T020200002D/en -->
     <territory id="KM" countryCode="269" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200002D/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{2})(\d{2})">
           <format>$1 $2 $3</format>
         </nationalNumberPattern>
         <exampleNumber>9001234</exampleNumber>
       </premiumRate>
-      <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1091.html -->
-      <emergency>
-        <nationalNumberPattern>1[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Saint Kitts and Nevis -->
-    <!-- http://www.itu.int/oth/T02020000B0/en -->
     <territory id="KN" countryCode="1" leadingDigits="869" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B0/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
             )|
             302|
             4(?:
-              6[5-9]|
+              6[015-9]|
               70
             )
           )\d{4}
           )\d{4}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
-        <exampleNumber>8695561234</exampleNumber>
+        <!-- Example number from the ITU document. -->
+        <exampleNumber>8697652917</exampleNumber>
       </mobile>
       <tollFree>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://www.stkittstourism.kn/explore-st-kitts-facts.php
-             http://barbados.usembassy.gov/emergency-st_kitts_nevis.html -->
-        <nationalNumberPattern>
-          333|
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
-    <!--  Korea, Dem. People's Rep. of -->
-    <!-- http://en.wikipedia.org/wiki/%2B850 -->
+    <!-- Korea, Dem. People's Rep. of -->
     <territory id="KP" countryCode="850" internationalPrefix="00|99"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B850</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{4})">
           <leadingDigits>1</leadingDigits>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>1921234567</exampleNumber>
       </mobile>
-      <!-- According to the following webpage, there is no emergency number in
-           North Korea: http://www.netglobers.com/asia/north-korea-emergency-numbers-in-north-korea.html -->
     </territory>
 
     <!-- Korea (Rep. of) -->
-    <!-- http://www.itu.int/oth/T0202000072/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B82 -->
-    <!-- http://www.kcc.go.kr/user.do?mode=view&page=P02030300&dc=K02030300&boardId=1074&boardSeq=2349 -->
-    <!-- http://www.kcc.go.kr/user.do?mode=view&page=P02030300&dc=K02030300&boardId=1074&boardSeq=2240 -->
-    <!-- http://www.telecentro.co.kr/sub/index.php?job=detail&ebcf_id=faq&page=1&mid=0503&eb_seq=36 -->
     <!-- Exceptions :
         internationalPrefix
             0031, 0033, 0071, 0073 - Special services of KT and DACOM, ignorable
             1[4-6]XX-YYYY - Country-wide common number services, display as it is without hyphens -->
     <territory id="KR" countryCode="82" internationalPrefix="00(?:[124-68]|[37]\d{2})"
                nationalPrefix="0" nationalPrefixForParsing="0(8[1-46-8]|85\d{2})?"
-               nationalPrefixFormattingRule="$NP$FG" carrierCodeFormattingRule="$NP$CC-$FG">
+               nationalPrefixFormattingRule="$NP$FG" carrierCodeFormattingRule="$NP$CC-$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000072/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B82</sourceUrl>
+        <sourceUrl>http://www.kcc.go.kr/user.do?mode=view&amp;page=P02030300&amp;dc=K02030300&amp;boardId=1074&amp;boardSeq=2349</sourceUrl>
+        <sourceUrl>http://www.kcc.go.kr/user.do?mode=view&amp;page=P02030300&amp;dc=K02030300&amp;boardId=1074&amp;boardSeq=2240</sourceUrl>
+        <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>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{4})(\d{4})">
           <leadingDigits>
           <leadingDigits>
             1(?:
               5[46-9]|
-              6[04678]
+              6[04678]|
+              8[0579]
             )
           </leadingDigits>
           <leadingDigits>
                 6[16]|
                 70|
                 88
+              )|
+              8(?:
+                00|
+                55|
+                77|
+                99
               )
             )
           </leadingDigits>
         <exampleNumber>7012345678</exampleNumber>
       </voip>
       <uan>
+        <!-- Prefix 18 added from numbers found online. -->
         <nationalNumberPattern>
           1(?:
             5(?:
               6[16]|
               70|
               88
+            )|
+            8(?:
+              00|
+              55|
+              77|
+              99
             )
           )\d{4}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>15441234</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>11[29]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Kuwait -->
-    <!-- http://www.itu.int/oth/T0202000073/en -->
-    <territory id="KW" countryCode="965" internationalPrefix="00">
+    <territory id="KW" countryCode="965" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000073/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Format is from ITU. -->
         <numberFormat pattern="(\d{4})(\d{3,4})">
         <exampleNumber>22345678</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- The mention of the mobile range 6933 0000 - 6969 9999 seems to be
-             a mistake in the ITU plan, and should be 6933 0000 - 6933 9999. -->
         <nationalNumberPattern>
           (?:
             5(?:
-              1[0-35]|
-              [05]\d
+              [05]\d|
+              1[0-6]
             )|
             6(?:
               0[034679]|
             9(?:
               0[09]|
               4[049]|
+              55|
               6[069]|
               [79]\d|
-              88
+              8[089]
             )
           )\d{5}
         </nationalNumberPattern>
         <exampleNumber>50012345</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Cayman Islands -->
-    <!-- http://www.itu.int/oth/T0202000027/en -->
     <territory id="KY" countryCode="1" leadingDigits="345" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000027/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[3589]\d{9}</nationalNumberPattern>
            from Switzerland with this prefix so do not list it as noInternationalDialling. -->
       <fixedLine>
         <!-- The Westtel numbers in the plan seem now to be live and assigned to fixed-line phones,
-             as per numbers found online and their website www.logic.ky. -->
+             as per numbers found online and their website http://www.logic.ky. -->
         <nationalNumberPattern>
           345(?:
             2(?:
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Kazakhstan -->
-    <!-- http://www.itu.int/oth/T020200006F/en -->
     <territory id="KZ" countryCode="7" preferredInternationalPrefix="8~10"
                internationalPrefix="810" nationalPrefix="8">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200006F/en</sourceUrl>
+      </references>
        <!-- Formatting rules obtained from Russia. -->
       <generalDesc>
         <!-- We make this as specific as possible to overlap as little as possible with Russia, so
         <exampleNumber>7123456789</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Added 776, apparently assigned to Beeline, and 747 for Tele2. -->
+        <!-- Added 708 for Altel, 776 for Beeline, 747 for Tele2. -->
         <nationalNumberPattern>
           7(?:
-            0[01257]|
+            0[012578]|
             47|
             6[02-4]|
             7[15-8]|
         <exampleNumber>8091234567</exampleNumber>
       </premiumRate>
       <voip>
-        <nationalNumberPattern>751\d{7}</nationalNumberPattern>
-        <exampleNumber>7511234567</exampleNumber>
-      </voip>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[123]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
+        <nationalNumberPattern>751\d{7}</nationalNumberPattern>
+        <exampleNumber>7511234567</exampleNumber>
+      </voip>
     </territory>
 
     <!-- Lao People's Dem. Rep. -->
-    <!-- http://www.itu.int/oth/T0202000075/en (Seems incomplete) -->
-    <!-- http://en.wikipedia.org/wiki/+856 -->
     <territory id="LA" countryCode="856" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <!-- Seems incomplete -->
+        <sourceUrl>http://www.itu.int/oth/T0202000075/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+856</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(20)(\d{2})(\d{3})(\d{3})">
           <leadingDigits>20</leadingDigits>
         <numberFormat pattern="([2-8]\d)(\d{3})(\d{3})">
           <leadingDigits>
             2[13]|
-            [3-8]
+            3[14]|
+            [4-8]
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
+        <numberFormat pattern="(30)(\d{2})(\d{2})(\d{3})">
+          <leadingDigits>30</leadingDigits>
+          <format>$1 $2 $3 $4</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>[2-8]\d{7,9}</nationalNumberPattern>
         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
+        <!-- The Lonely Planet says that newer WIN phones (fixed phones without a physical landline)
+             start with 030 (and are longer). There are plenty of examples online. -->
         <nationalNumberPattern>
           (?:
             2[13]|
-            [35-7][14]|
+            3(?:
+              0\d|
+              [14]
+            )|
+            [5-7][14]|
             41|
             8[1468]
           )\d{6}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
+        <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
         <exampleNumber>21212862</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 202[89], 205[89], 207[68] and 209[57] from numbers found online. -->
+        <!-- Adding 202[89], 205[89], 207[68] and 209[15-7] from numbers found online. -->
         <nationalNumberPattern>
           20(?:
             2[2389]|
             5[4-689]|
             7[6-8]|
-            9[57-9]
+            9[15-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>2023123456</exampleNumber>
       </mobile>
       <!-- No information on other types of phone numbers for Lao P.D.R. has been found. -->
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_946.html -->
-        <nationalNumberPattern>19[015]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>190</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Lebanon -->
-    <!-- http://www.itu.int/oth/T0202000077/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B961 -->
     <territory id="LB" countryCode="961" internationalPrefix="00" nationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000077/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B961</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
           <leadingDigits>
           <leadingDigits>
             [89][01]|
             7(?:
-              [01]|
+              [019]|
               6[013-9]|
-              8[89]|
-              91
+              8[89]
             )
           </leadingDigits>
           <format>$1 $2 $3</format>
         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
+        <!-- The ITU document from October 2012 seems to have accidentally dropped the 79 prefix for
+             fixed-line numbers, which had been in the version from July 2012. We consider these
+             valid since we successfully dialed such a number in July 2014. -->
         <nationalNumberPattern>
           (?:
             [14-6]\d{2}|
         <exampleNumber>1123456</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- We only validate the first three digits here, since the ranges are growing rapidly. -->
+        <!-- We only validate the first three digits here, since the ranges are growing rapidly.
+             The 79[02-9] prefixes were added from bug reports and numbers found online. -->
         <nationalNumberPattern>
           (?:
             3\d|
             7(?:
-              [01]\d|
+              [019]\d|
               6[013-9]|
-              8[89]|
-              91
+              8[89]
             )
           )\d{5}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>80123456</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            40|
-            75
-          )|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Saint Lucia -->
-    <!-- http://www.itu.int/oth/T02020000B1/en -->
     <territory id="LC" countryCode="1" leadingDigits="758" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B1/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Adding 430 and 572 since numbers have been found with these prefixes online. -->
+        <!-- Adding 430 since numbers have been found with these prefixes online. -->
         <nationalNumberPattern>
           758(?:
-            234|
             4(?:
               30|
               5[0-9]|
               6[2-9]|
               8[0-2]
             )|
-            572|
-            638|
-            758
+            57[0-2]|
+            638
           )\d{4}
         </nationalNumberPattern>
-        <exampleNumber>7582345678</exampleNumber>
+        <exampleNumber>7584305678</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 72[1256] as these prefixes are found widely on the internet and SMS messages
-             have been successfully delivered to these numbers. -->
         <nationalNumberPattern>
           758(?:
             28[4-7]|
             )|
             7(?:
               1[2-9]|
-              2[0-6]
+              2[0-8]
             )
           )\d{4}
         </nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://barbados.usembassy.gov/emergency-st_lucia.html
-             http://www.stlucia.org/planner/travel.asp
-             Note the second source only mentions 911, so we are not sure if 999 is indeed an
-             emergency number here. -->
-        <nationalNumberPattern>
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Liechtenstein -->
-    <!-- http://www.llv.li/amtsstellen/llv-ak-nummerierung.htm -->
-    <!-- http://www.telecom.li has some different patterns for tollfree and shared cost numbers -
-         look at "Mehrwertnummer". -->
     <!-- The national prefix of "0" is only used for 0800 and 0900 numbers. -->
     <territory id="LI" countryCode="423" internationalPrefix="00" nationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.llv.li/amtsstellen/llv-ak-nummerierung.htm</sourceUrl>
+      </references>
       <availableFormats>
+        <!-- Some different patterns for tollfree and shared cost numbers may be found by searching
+             for "Mehrwertnummer" at http://www.telecom.li. -->
         <numberFormat pattern="(\d{3})(\d{2})(\d{2})">
           <leadingDigits>
             [23]|
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>7011234</exampleNumber>
       </personalNumber>
-      <!-- Information for short codes and emergency numbers comes from:
-           http://www.llv.li/pdf-llv-ak-shortnumbers_20110331.pdf -->
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1[278]|
-            44
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Sri Lanka -->
-    <!-- http://en.wikipedia.org/wiki/%2B94 -->
-    <!-- http://www.itu.int/oth/T02020000C3/en -->
     <territory id="LK" countryCode="94" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B94</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T02020000C3/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{1})(\d{6})">
           <leadingDigits>[1-689]</leadingDigits>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>712345678</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>11[0189]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>119</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Liberia -->
-    <!-- http://www.itu.int/oth/T0202000079/en -->
     <territory id="LR" countryCode="231" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000079/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formatting from Ministry of Agriculture,
         http://www.moa.gov.lr/content.php?sub=Email&?related=Contacts -->
-        <numberFormat pattern="([279]\d)(\d{3})(\d{3})">
-          <leadingDigits>[279]</leadingDigits>
+        <numberFormat pattern="(2\d)(\d{3})(\d{3})">
+          <leadingDigits>2</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="(7\d{2})(\d{3})(\d{3})">
-          <leadingDigits>7</leadingDigits>
+        <numberFormat pattern="([79]\d{2})(\d{3})(\d{3})">
+          <leadingDigits>[79]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat pattern="([4-6])(\d{3})(\d{3})">
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
-          (?:
-            [29]\d|
-            [4-6]|
-            7\d{1,2}|
-            [38]\d{2}
-          )\d{6}
+          2\d{7}|
+          [37-9]\d{8}|
+          [45]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{7,9}</possibleNumberPattern>
       </generalDesc>
         <exampleNumber>21234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- According to information from Lonestar Communications Corporation, the prefix 6 is
-             being removed, but as of June 2012 is in parallel running with their new prefix 88.
-             According to Cellcom Liberia, they have issued 9 digit numbers starting with 77. -->
+        <!-- West Africa Telecom seems to be a mobile company from their website. Adding Atlantic
+             Wireless from the document, even though from online news reports it is not clear they
+             are still operating. -->
         <nationalNumberPattern>
           (?:
+            330\d|
             4[67]|
             5\d|
-            6[4-8]|
-            77?\d{2}|
-            88\d{2}
+            77\d{2}|
+            88\d{2}|
+            994\d
           )\d{5}
         </nationalNumberPattern>
-        <exampleNumber>4612345</exampleNumber>
+        <exampleNumber>770123456</exampleNumber>
       </mobile>
       <premiumRate>
-        <!-- Telemedia service is listed under premium rate. -->
-        <!-- Note that as of March 2013, the ITU document talks about the withdrawal of the range
-             (90) 0 XXX XXX. This is a 9 digit range and one we have never supported, but this could
-             be a mistake in the ITU document and refer to (90) 0XX XXX. However as this is unclear
-             at the moment, we decided to leave the (90) range unchanged for now. -->
-        <nationalNumberPattern>90\d{6}</nationalNumberPattern>
-        <possibleNumberPattern>\d{8}</possibleNumberPattern>
-        <exampleNumber>90123456</exampleNumber>
+        <!-- Telelinks and Interactive media service are listed under premium rate. -->
+        <nationalNumberPattern>90[03]\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <exampleNumber>900123456</exampleNumber>
       </premiumRate>
       <voip>
         <!-- The plan lists the following range as being assigned to TEMAS. On their homepage they
-             say they are involved in the VoIP sector. -->
-        <nationalNumberPattern>33200\d{4}</nationalNumberPattern>
+             say they are involved in the VoIP sector. Adding WASSCOM and Atlantic Realty &
+             Investment Corporation here as well; no numbers can be found online, nor company
+             information. -->
+        <nationalNumberPattern>
+          332(?:
+            0[02]|
+            5\d
+          )\d{4}
+        </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>332001234</exampleNumber>
       </voip>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_950.html -->
-        <nationalNumberPattern>
-          355|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Lesotho -->
-    <!-- http://www.itu.int/oth/T0202000078/en -->
     <territory id="LS" countryCode="266" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000078/en</sourceUrl>
+      </references>
       <availableFormats>
-        <!-- Formatting following yellow pages: www.yellowpages.co.ls -->
+        <!-- Formatting following yellow pages: http://www.yellowpages.co.ls -->
         <numberFormat pattern="(\d{4})(\d{4})">
           <format>$1 $2</format>
         </numberFormat>
         <nationalNumberPattern>800[256]\d{4}</nationalNumberPattern>
         <exampleNumber>80021234</exampleNumber>
       </tollFree>
-      <emergency>
-        <!-- http://www.nul.ls/students/students_Home/emergency_Nos/
-             http://www.voyage.gc.ca/countries_pays/report_rapport-eng.asp?id=160000 -->
-        <nationalNumberPattern>11[257]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Lithuania -->
-    <!-- http://www.itu.int/oth/T020200007C/en -->
     <!-- Note that Lithuania is switching to a national prefix of 0. We support
          both 0 and 8 when parsing until this switch is complete. -->
     <territory id="LT" countryCode="370" internationalPrefix="00"
                nationalPrefix="8" nationalPrefixForParsing="[08]"
-               nationalPrefixFormattingRule="($NP-$FG)">
-      <!-- National Prefix formatting rule from www.yellowpages.lt -->
+               nationalPrefixFormattingRule="($NP-$FG)"
+               nationalPrefixOptionalWhenFormatting="true" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200007C/en</sourceUrl>
+      </references>
+      <!-- National Prefix formatting rule from http://www.yellowpages.lt -->
       <availableFormats>
         <!-- Two-digit area codes -->
         <numberFormat pattern="([34]\d)(\d{6})">
         <nationalNumberPattern>70[67]\d{5}</nationalNumberPattern>
         <exampleNumber>70712345</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          0(?:
-            11?|
-            22?|
-            33?
-          )|
-          1(?:
-            0[123]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Luxembourg -->
-    <!-- http://www.ilr.public.lu/communications_electroniques/numerotation/index.html
-         -->
     <territory id="LU" countryCode="352" internationalPrefix="00"
                nationalPrefixForParsing="(15(?:0[06]|1[12]|35|4[04]|55|6[26]|77|88|99)\d)"
-               carrierCodeFormattingRule="$CC $FG">
+               carrierCodeFormattingRule="$CC $FG" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.ilr.public.lu/communications_electroniques/numerotation/index.html</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Patterns overlap because of variable number length. -->
         <numberFormat pattern="(\d{2})(\d{3})">
         <possibleNumberPattern>\d{4,11}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Note that numbers starting with 2[367] can be a maximum of 10 digits - all others a
-             maximum of 11. -->
+        <!-- Even though 20 is listed in the fixed-line plan, other documentation clarify that it is
+             for VOIP. Furthermore, even though the plan says that numbers beginning with 2[346-8]
+             must be exactly 8 digits, from information found online it seems that they can actually
+             be 6 (but not 7) digits long. -->
         <nationalNumberPattern>
           (?:
             2(?:
-              2\d{1,2}|
-              3[2-9]|
-              [67]\d|
-              4[1-8]\d?|
-              5[1-5]\d?|
-              9[0-24-9]\d?
+              [259]\d{2,9}|
+              [346-8]\d{4}(?:\d{2})?
             )|
-            3(?:
-              [059][05-9]|
-              [13]\d|
-              [26][015-9]|
-              4[0-26-9]|
-              7[0-389]|
-              8[08]
-            )\d?|
-            4\d{2,3}|
-            5(?:
-              [01458]\d|
-              [27][0-69]|
-              3[0-3]|
-              [69][0-7]
-            )\d?|
-            7(?:
-              1[019]|
-              2[05-9]|
-              3[05]|
-              [45][07-9]|
-              [679][089]|
-              8[06-9]
-            )\d?|
-            8(?:
-              0[2-9]|
-              1[0-36-9]|
-              3[3-9]|
-              [469]9|
-              [58][7-9]|
-              7[89]
-            )\d?|
-            9(?:
-              0[89]|
-              2[0-49]|
-              37|
-              49|
-              5[0-27-9]|
-              7[7-9]|
-              9[0-478]
-            )\d?
-          )\d{1,7}
+            (?:
+              [3457]\d{2}|
+              8(?:
+                0[2-9]|
+                [13-9]\d
+              )|
+              9(?:
+                0[89]|
+                [2-579]\d
+              )
+            )\d{1,8}
+          )
         </nationalNumberPattern>
         <exampleNumber>27123456</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>6[269][18]\d{6}</nationalNumberPattern>
+        <nationalNumberPattern>6[2679][18]\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>628123456</exampleNumber>
       </mobile>
         <exampleNumber>70123456</exampleNumber>
       </personalNumber>
       <voip>
-        <nationalNumberPattern>20\d{2,8}</nationalNumberPattern>
+        <!-- The document says the normal length will be 8 digits, but many numbers found online
+             deviate from that. The prefixes from the following document have been added:
+             http://www.ilr.public.lu/communications_electroniques/numerotation/plan_nat_num/numeros_geographiques_geo.pdf
+             201 has also been added since a diallable number was found online, and it says in
+             http://www.ilr.public.lu/communications_electroniques/decisions/2004/0479.pdf that no
+             numbers will be issued that begin with 200, numbers beginning with 201 will be issued
+             one at a time, and 202-209 in blocks. -->
+        <nationalNumberPattern>
+          20(?:
+            1\d{5}|
+            [2-689]\d{1,7}
+          )
+        </nationalNumberPattern>
         <possibleNumberPattern>\d{4,10}</possibleNumberPattern>
-        <exampleNumber>2012345</exampleNumber>
+        <exampleNumber>20201234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>11[23]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Latvia -->
-    <!-- http://www.itu.int/oth/T0202000076/en -->
-    <!-- http://en.wikipedia.org/wiki/+371 -->
-    <territory id="LV" countryCode="371" internationalPrefix="00">
+    <territory id="LV" countryCode="371" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000076/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+371</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([2689]\d)(\d{3})(\d{3})">
           <format>$1 $2 $3</format>
         <nationalNumberPattern>81\d{6}</nationalNumberPattern>
         <exampleNumber>81123456</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          0[123]|
-          112
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Libya (Soc. People’s Libyan Arab Jamahiriya) -->
          operator (Hatef Libya). A new mobile operator Aljeel Aljadeed for Technology will start
          using 096 (they are allowing customers to register numbers currently), so their code has
          also been added. -->
-    <!-- http://hlc.ly/price.php -->
     <territory id="LY" countryCode="218" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://hlc.ly/price.php</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([25679]\d)(\d{7})">
           <format>$1-$2</format>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>912345678</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- This information may or may not apply to the new government. -->
-        <!-- Most of the gov.ly domain is down (checked on 2011-11-07). -->
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_951.html -->
-        <!-- http://www.lookoutlibya.com/Look_Out_Libya_%7C_Health_and_Safety_03.html -->
-        <nationalNumberPattern>19[013]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>193</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Morocco -->
     <!-- Shares formatting and some metadata with Western Sahara. -->
-    <!-- http://www.itu.int/oth/T0202000090/en -->
-    <!-- http://en.wikipedia.org/wiki/+212 -->
     <territory id="MA" countryCode="212" internationalPrefix="00" nationalPrefix="0"
-               nationalPrefixFormattingRule="$NP$FG" mainCountryForCode="true">
+               nationalPrefixFormattingRule="$NP$FG" mainCountryForCode="true"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000090/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+212</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([56]\d{2})(\d{6})">
           <leadingDigits>
       </fixedLine>
       <!-- Also duplicated in Western Sahara, please ensure you update both. -->
       <mobile>
-        <!-- Prefixes 60[1-578], 62[01457-9], 63[04-8] and 68[01] are from numbers found online,
-             bug-reports, and information provided directly by the carriers. -->
+        <!-- http://www.anrt.ma/sites/default/files/Blocs_de_numeros_par_operateur.pdf
+             Prefixes 69[0136] added based on numbers found online. -->
         <nationalNumberPattern>
           6(?:
             0[0-8]|
-            [124-7]\d|
-            3[013-8]|
-            8[01]|
-            99
+            [12-79]\d|
+            8[01]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>650123456</exampleNumber>
         <nationalNumberPattern>89\d{7}</nationalNumberPattern>
         <exampleNumber>891234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            [59]|
-            77
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Monaco -->
-    <!-- http://www.itu.int/oth/T020200008D/en -->
     <!-- We support Kosovo mobile numbers (044, 045) with a Monaco country-code here, as we do not
          support Kosovo at the moment. Kosovo seems to use a variety of country codes currently. It
          also seems that the national prefix is only used for mobile numbers, not fixed-line. -->
     <territory id="MC" countryCode="377" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200008D/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Following formatting found online rather than in the ITU document example. -->
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})" nationalPrefixFormattingRule="$FG">
-          <leadingDigits>[89]</leadingDigits>
+          <leadingDigits>9</leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
           <leadingDigits>6</leadingDigits>
           <format>$1 $2 $3 $4 $5</format>
         </numberFormat>
+        <numberFormat pattern="(\d{3})(\d{3})(\d{2})" nationalPrefixFormattingRule="$FG">
+          <leadingDigits>8</leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>[4689]\d{7,8}</nationalNumberPattern>
       </noInternationalDialling>
       <fixedLine>
         <!-- Restricted to this as no numbers with the prefix of 91, 95 or 96 have been found. -->
-        <nationalNumberPattern>9[2-47-9]\d{6}</nationalNumberPattern>
+        <nationalNumberPattern>
+          870\d{5}|
+          9[2-47-9]\d{6}
+        </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>99123456</exampleNumber>
       </fixedLine>
         <!-- 4X mobile numbers are actually used by Kosovo. -->
         <nationalNumberPattern>
           6\d{8}|
-          4\d{7}
+          4(?:
+            4\d|
+            5[2-9]
+          )\d{5}
         </nationalNumberPattern>
         <exampleNumber>612345678</exampleNumber>
       </mobile>
       <tollFree>
-        <nationalNumberPattern>
-          (?:
-            8\d|
-            90
-          )\d{6}
-        </nationalNumberPattern>
+        <nationalNumberPattern>90\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>90123456</exampleNumber>
       </tollFree>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            [578]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Moldova, Rep. of -->
-    <!-- http://www.itu.int/oth/T020200008C/en -->
-    <!-- http://en.anrceti.md -->
     <territory id="MD" countryCode="373" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG" >
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200008C/en</sourceUrl>
+        <!-- Announcements -->
+        <sourceUrl>http://anrceti.md/fileupload/58</sourceUrl>
+        <!-- Mobile ranges -->
+        <sourceUrl>http://en.anrceti.md/resurse_numerotare_tel_mobila</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
           <leadingDigits>
         <!-- Includes prefixes for Interdnestrcom, http://www.idknet.com/. -->
         <nationalNumberPattern>
           (?:
-            562|
+            562\d|
             6(?:
-              50|
-              7[1-6]|
-              [089]\d
+              [089]\d{2}|
+              1[01]\d|
+              21\d|
+              50\d|
+              7(?:
+                [1-6]\d|
+                7[0-4]
+              )
             )|
             7(?:
-              67|
-              7[47-9]|
+              6[07]|
+              7[457-9]|
               [89]\d
-            )
-          )\d{5}
+            )\d
+          )\d{4}
         </nationalNumberPattern>
         <exampleNumber>65012345</exampleNumber>
       </mobile>
         <nationalNumberPattern>3[08]\d{6}</nationalNumberPattern>
         <exampleNumber>30123456</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          90[123]
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Montenegro -->
-    <!-- http://www.itu.int/oth/T02020000DA/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Montenegro -->
-    <!-- http://www.ekip.me/numeracija/dodijeljena.php -->
     <territory id="ME" countryCode="382" internationalPrefix="00" nationalPrefix="0"
                nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000DA/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Montenegro</sourceUrl>
+        <sourceUrl>http://www.ekip.me/numeracija/dodijeljena.php</sourceUrl>
+      </references>
       <availableFormats>
          <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
           <leadingDigits>[2-57-9]|6[3789]</leadingDigits>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>77273012</exampleNumber>
       </uan>
-      <emergency>
+    </territory>
+
+    <!-- Saint-Martin, French Antilles -->
+    <territory id="MF" countryCode="590" internationalPrefix="00" nationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000058/en</sourceUrl>
+        <!-- Linked from http://www.arcep.fr/index.php?id=interactivenumeros -->
+        <sourceUrl>http://www.arcep.fr/fileadmin/reprise/dossiers/numero/ZABPQ-ZNE.xls</sourceUrl>
+      </references>
+      <!-- Formatting rules borrowed from Guadeloupe. -->
+      <generalDesc>
+        <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+      </generalDesc>
+      <fixedLine>
         <nationalNumberPattern>
-          1(?:
-            12|
-            2[234]
-          )
+          590(?:
+            [02][79]|
+            13|
+            5[0-268]|
+            [78]7
+          )\d{4}
+        </nationalNumberPattern>
+        <exampleNumber>590271234</exampleNumber>
+      </fixedLine>
+      <mobile>
+        <!-- Any ranges assigned from
+             http://www.arcep.fr/index.php?id=interactivenumeros have been listed as belonging to
+             Guadeloupe, St Martin and St Barthélemy, since we can't reliably distinguish between
+             them. -->
+        <nationalNumberPattern>
+          690(?:
+            0[0-7]|
+            [1-9]\d
+          )\d{4}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
+        <exampleNumber>690301234</exampleNumber>
+      </mobile>
     </territory>
 
     <!-- Madagascar -->
-    <!-- http://www.itu.int/oth/T020200007F/en -->
     <territory id="MG" countryCode="261" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200007F/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([23]\d)(\d{2})(\d{3})(\d{2})">
           <format>$1 $2 $3 $4</format>
       <mobile>
         <!-- The numbering plan suggests the third digit, Z, should be 24-9, but this is not borne
              out by reality. -->
-        <nationalNumberPattern>
-          3(?:
-            [02-4]\d|
-            90
-          )\d{6}
-        </nationalNumberPattern>
+        <nationalNumberPattern>3[2-49]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
-        <exampleNumber>301234567</exampleNumber>
+        <exampleNumber>321234567</exampleNumber>
       </mobile>
       <!-- Putting VSAT numbers here. -->
       <voip>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>221234567</exampleNumber>
       </voip>
-      <emergency>
-        <!-- http://www.commerce.gov.mg/index.php/infos-services -->
-        <nationalNumberPattern>11?[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>117</exampleNumber>
-      </emergency>
-    </territory>
-
-    <!-- Saint-Martin, French Antilles -->
-    <!-- http://www.itu.int/oth/T0202000058/en -->
-    <!-- http://www.arcep.fr/index.php?id=interactivenumeros - ZABPQ-ZNE.xls -->
-    <territory id="MF" countryCode="590" internationalPrefix="00" nationalPrefix="0">
-      <!-- Formatting rules borrowed from Guadeloupe. -->
-      <generalDesc>
-        <nationalNumberPattern>[56]\d{8}</nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
-      </generalDesc>
-      <fixedLine>
-        <nationalNumberPattern>
-          590(?:
-            [02][79]|
-            13|
-            5[0-268]|
-            [78]7
-          )\d{4}
-        </nationalNumberPattern>
-        <exampleNumber>590271234</exampleNumber>
-      </fixedLine>
-      <mobile>
-        <!-- Any ranges assigned from
-             http://www.arcep.fr/index.php?id=interactivenumeros have been listed as belonging to
-             Guadeloupe, St Martin and St Barthélemy, since we can't reliably distinguish between
-             them. -->
-        <nationalNumberPattern>
-          690(?:
-            0[0-7]|
-            [1-9]\d
-          )\d{4}
-        </nationalNumberPattern>
-        <exampleNumber>690301234</exampleNumber>
-      </mobile>
-      <!-- http://www.leshotelsdesaintmartin.com/fr/saint-martin-antilles/informations-saint-martin/infos-pratiques-sxm.html -->
-      <emergency>
-        <nationalNumberPattern>1[578]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>18</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Marshall Islands -->
-    <!-- http://www.itu.int/oth/T0202000085/en -->
     <territory id="MH" countryCode="692" internationalPrefix="011" nationalPrefix="1">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000085/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1-$2</format>
         <nationalNumberPattern>635\d{4}</nationalNumberPattern>
         <exampleNumber>6351234</exampleNumber>
       </voip>
-      <!-- Only fixed-line numbers (625 4111 and 625 8666) can be found instead of short Emergency
-           numbers. -->
     </territory>
 
     <!-- Macedonia, Former Yugoslav Rep. of -->
-    <!-- http://www.itu.int/oth/T02020000CE/en -->
     <territory id="MK" countryCode="389" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000CE/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formats follow wikipedia. -->
         <numberFormat pattern="(2)(\d{3})(\d{4})">
       <mobile>
         <nationalNumberPattern>
           7(?:
-            [0-25-8]\d|
-            33
-          )\d{5}</nationalNumberPattern>
+            [0-25-8]\d{2}|
+            32\d|
+            421
+          )\d{4}
+        </nationalNumberPattern>
         <exampleNumber>72345678</exampleNumber>
       </mobile>
       <tollFree>
         </nationalNumberPattern>
         <exampleNumber>80123456</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            9[234]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Mali -->
-    <!-- http://www.itu.int/oth/T0202000083/en -->
-    <!-- http://crt-mali.org/pdf/plan_num -->
     <territory id="ML" countryCode="223" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000083/en</sourceUrl>
+        <sourceUrl>http://crt-mali.org/pdf/plan_num</sourceUrl>
+      </references>
       <availableFormats>
-        <numberFormat pattern="([246-8]\d)(\d{2})(\d{2})(\d{2})">
+        <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
+          <leadingDigits>[246-9]</leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
+        <!-- Formatting some short numbers as a block. -->
+        <numberFormat pattern="(\d{4})">
+          <leadingDigits>
+            67|
+            74
+          </leadingDigits>
+          <intlFormat>NA</intlFormat>
+          <format>$1</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[246-8]\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>[246-9]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- 21 25 seems a common pattern based on online searches. -->
+        <!-- Patterns from ITU with extra ranges 20 25, 20 7[13-9] and 217 provided by Sotelma and
+             confirmed by searches online. -->
         <nationalNumberPattern>
           (?:
             2(?:
               0(?:
                 2[0-589]|
-                7[027-9]
+                7\d
               )|
               1(?:
                 2[5-7]|
-                [3-689]\d
+                [3-689]\d|
+                7[2-4689]
               )
             )|
             44[239]\d
       <mobile>
         <!-- Orange Mali have updated their numbering plan, though this is not reflected in the ITU
              document (which is very stale). All mobile numbers starting with 7 are now Orange.
-             Includes 6x from Malitel IR21. -->
-        <nationalNumberPattern>[67]\d{7}</nationalNumberPattern>
+             Includes 6x from Malitel IR21. Numbers beginning with 9 have been found online and
+             reported by open-source users, although the exact possible second digits are uncertain.
+             -->
+        <nationalNumberPattern>
+          [67]\d{7}|
+          9[0-25-9]\d{6}
+        </nationalNumberPattern>
         <exampleNumber>65012345</exampleNumber>
       </mobile>
       <tollFree>
         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
         <exampleNumber>80012345</exampleNumber>
       </tollFree>
-      <emergency>
-        <nationalNumberPattern>1[578]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
    </territory>
 
     <!-- Myanmar -->
-    <!-- http://www.itu.int/oth/T0202000092/en -->
     <territory id="MM" countryCode="95" internationalPrefix="00" nationalPrefix="0"
                nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000092/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{3})(\d{3,4})">
           <leadingDigits>
           <leadingDigits>[4-8]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="(9)(\d{3})(\d{4,5})">
+        <numberFormat pattern="(9)(\d{3})(\d{4,6})">
           <leadingDigits>
             9(?:
-              [235-9]|
+              2[0-4]|
+              [35-9]|
               4[13789]
             )
           </leadingDigits>
           <leadingDigits>94[0245]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
+        <!-- Following majority of numbers found online. -->
+        <numberFormat pattern="(9)(\d{3})(\d{3})(\d{3})">
+          <leadingDigits>925</leadingDigits>
+          <format>$1 $2 $3 $4</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
           [14578]\d{5,7}|
           [26]\d{5,8}|
           9(?:
-            [258]|
+            2\d{0,2}|
+            [58]|
             3\d|
             4\d{1,2}|
-            [679]\d?
+            6\d?|
+            [79]\d{0,2}
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
         <exampleNumber>1234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 99[089] (8 digits) from numbers found online, and 961 with 9 digits. -->
+        <!-- Added 99[089] (8 digits), 961 (9 digits), and 979 & 997 (10 digits) from bug
+             reports/numbers found online. -->
         <nationalNumberPattern>
           17[01]\d{4}|
           9(?:
-            2[0-4]|
+            2(?:
+              [0-4]|
+              5\d{2}
+            )|
             3[136]\d|
             4(?:
               0[0-4]\d|
             )|
             5[0-6]|
             61?\d|
-            73\d|
+            7(?:
+              3\d|
+              9\d{2}
+            )|
             8\d|
             9(?:
               1\d|
+              7\d{2}|
               [089]
             )
           )\d{5}
         <exampleNumber>13331234</exampleNumber>
       </voip>
       <!-- No information on other types of phone numbers for Myanmar has been found. -->
-      <emergency>
-        <nationalNumberPattern>199</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>199</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Mongolia -->
-    <!-- http://www.itu.int/oth/T020200008E/en -->
     <territory id="MN" countryCode="976" internationalPrefix="001"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200008E/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([12]\d)(\d{2})(\d{4})">
           <leadingDigits>[12]1</leadingDigits>
       <mobile>
         <nationalNumberPattern>
           (?:
-            8[89]|
+            8[689]|
             9[013-9]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>75123456</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>10[0-3]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>102</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Macao, China -->
-    <!-- http://www.itu.int/oth/T020200007E/en -->
     <territory id="MO" countryCode="853" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200007E/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([268]\d{3})(\d{4})">
           <format>$1 $2</format>
         <exampleNumber>66123456</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
-    <!--  Northern Mariana Islands -->
-    <!-- http://www.itu.int/oth/T02020000EE/en -->
-    <!-- www.cnmiphonebook.com/ -->
+    <!-- Northern Mariana Islands -->
     <territory id="MP" countryCode="1" leadingDigits="670" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000EE/en</sourceUrl>
+        <sourceUrl>http://www.cnmiphonebook.com/</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://www.dps.gov.mp/ -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Martinique (French Dept. of) -->
-    <!-- http://www.itu.int/oth/T0202000086/en -->
-    <!-- http://www.arcep.fr/index.php?id=2137&bloc=0596&CMD=RESULTS_NUMEROTATION -->
     <territory id="MQ" countryCode="596" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000086/en</sourceUrl>
+        <sourceUrl>http://www.arcep.fr/index.php?id=2137&amp;bloc=0596&amp;CMD=RESULTS_NUMEROTATION</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
       <!-- The 876 prefix is mentioned in the plan, but the plan is from 2006 and in France VOIP
            numbers were changed from 087 to the 09 prefix in 2009. It is likely this occurred here
            too. -->
-      <!-- http://www.martinique.franceantilles.fr/pratique/urgences/ -->
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            [578]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Mauritania -->
-    <!-- http://www.itu.int/oth/T0202000087/en -->
-    <!-- http://www.are.mr/com-1-4-1.html -->
     <territory id="MR" countryCode="222" internationalPrefix="00" >
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000087/en</sourceUrl>
+        <sourceUrl>http://are.mr/pdfs/pnn2010.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([2-48]\d)(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
         </nationalNumberPattern>
         <exampleNumber>35123456</exampleNumber>
       </fixedLine>
+      <!-- Added "49\d" in response to https://code.google.com/p/libphonenumber/issues/detail?id=529
+           which might be overly permissive, but we don't have an official documentation for this
+           and only a small number of numbers were found online. At least 492 and 495 are valid.
+           -->
       <mobile>
         <nationalNumberPattern>
           (?:
               7[1-3]
             )|
             4(?:
-              4\d|
+              [49]\d|
               6[0457-9]|
-              7[4-9]
+              7[4-9]|
+              8[01346-8]
             )
           )\d{5}
         </nationalNumberPattern>
         <nationalNumberPattern>800\d{5}</nationalNumberPattern>
         <exampleNumber>80012345</exampleNumber>
       </tollFree>
-      <!-- http://www.lemoci.com/Mauritanie/14-Donnees-generales.htm -->
-      <emergency>
-        <nationalNumberPattern>1[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Montserrat -->
-    <!-- http://www.itu.int/oth/T020200008F/en -->
     <territory id="MS" countryCode="1" leadingDigits="664" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200008F/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-      <emergency>
-        <nationalNumberPattern>
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Malta -->
-    <!-- www.itu.int/oth/T0202000084/en -->
-    <!-- www.mca.org.mt (Numbering link in the LHS menu - has more up-to-date allocations) -->
-    <territory id="MT" countryCode="356" internationalPrefix="00">
+    <territory id="MT" countryCode="356" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000084/en</sourceUrl>
+        <!-- Numbering link in the LHS menu - has more up-to-date allocations -->
+        <sourceUrl>http://www.mca.org.mt</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <format>$1 $2</format>
           2(?:
             0(?:
               1[0-6]|
+              3[1-4]|
               [69]\d
             )|
             [1-357]\d{2}
         <exampleNumber>21001234</exampleNumber>
       </fixedLine>
       <mobile>
+        <!-- 7210 and 92XX come from the allocations listed on http://www.mca.org.mt, but they are
+             not listed in the latest ITU document. -->
         <nationalNumberPattern>
           (?:
             7(?:
         <nationalNumberPattern>501\d{5}</nationalNumberPattern>
         <exampleNumber>50112345</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Mauritius -->
-    <!-- http://www.icta.mu/telecommunications/numbering.htm -->
-    <territory id="MU" countryCode="230" internationalPrefix="0(?:[2-7]0|33)"
+    <!-- Preferred international prefix is expected to standardize on just '00' -->
+    <territory id="MU" countryCode="230" internationalPrefix="0(?:0|[2-7]0|33)"
                preferredInternationalPrefix="020">
+      <references>
+        <sourceUrl>http://www.icta.mu/telecommunications/numbering.htm</sourceUrl>
+      </references>
       <availableFormats>
-        <numberFormat pattern="([2-9]\d{2})(\d{4})">
+        <numberFormat pattern="([2-46-9]\d{2})(\d{4})">
+          <leadingDigits>[2-46-9]</leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+        <numberFormat pattern="(5\d{3})(\d{4})">
+          <leadingDigits>5</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[2-9]\d{6}</nationalNumberPattern>
-        <possibleNumberPattern>\d{7}</possibleNumberPattern>
+        <nationalNumberPattern>[2-9]\d{6,7}</nationalNumberPattern>
+        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Wireless local loop numbers are considered to be fixed, since there is almost no
-             roaming capability. 26X prefixes were added after numbers containing them marked as
-             "landline" were found online. These are also mentioned on
-             http://www.wtng.info/wtng-230-mu.html. -->
+        <!-- See also: http://www.wtng.info/wtng-230-mu.html for additional detail. -->
         <nationalNumberPattern>
           (?:
             2(?:
-              [034789]\d|
+              [03478]\d|
               1[0-7]|
               6[1-69]
             )|
             4(?:
-              [013-8]\d|
+              [013568]\d|
               2[4-7]
             )|
-            [56]\d{2}|
+            5(?:
+              44\d|
+              471
+            )|
+            6\d{2}|
             8(?:
               14|
               3[129]
         <exampleNumber>2012345</exampleNumber>
       </fixedLine>
       <mobile>
-        <!--Adding 92 as SMS messages have been successfully sent to this prefix. 820 has also been
-            added based on a report from Orange. -->
         <nationalNumberPattern>
-          (?:
-            25\d|
+          5(?:
+            2[59]\d|
             4(?:
-              2[12389]|
+              2[1-389]|
+              4\d|
+              7[1-9]|
               9\d
             )|
             7\d{2}|
             8(?:
-              20|
+              [256]\d|
               7[15-8]
             )|
-            9[1-8]\d
+            9[0-8]\d
           )\d{4}
         </nationalNumberPattern>
-        <exampleNumber>2512345</exampleNumber>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
+        <exampleNumber>52512345</exampleNumber>
       </mobile>
-      <pager>
-        <nationalNumberPattern>
-          2(?:
-            1[89]|
-            2\d
-          )\d{4}
-        </nationalNumberPattern>
-        <exampleNumber>2181234</exampleNumber>
-      </pager>
       <tollFree>
         <nationalNumberPattern>80[012]\d{4}</nationalNumberPattern>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>8001234</exampleNumber>
       </tollFree>
       <premiumRate>
         <nationalNumberPattern>30\d{5}</nationalNumberPattern>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>3012345</exampleNumber>
       </premiumRate>
       <voip>
             9\d
           )\d{4}
         </nationalNumberPattern>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>3201234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          11[45]|
-          99\d
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Maldives -->
-    <!-- http://www.itu.int/oth/T0202000082/en -->
-    <!-- www.dhiraagu.com.mv -->
     <territory id="MV" countryCode="960" internationalPrefix="0(?:0|19)"
                preferredInternationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000082/en</sourceUrl>
+        <sourceUrl>http://www.dhiraagu.com.mv</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9001234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            02|
-            19
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>102</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Malawi -->
-    <!-- http://www.itu.int/oth/T0202000080/en -->
     <!-- The plan doesn't state that a national prefix exists, but numbers found on the internet are
          consistent in having one. -->
     <territory id="MW" countryCode="265" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000080/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{3})(\d{3})">
           <leadingDigits>1</leadingDigits>
       </generalDesc>
       <fixedLine>
         <!-- 14 is no longer mentioned in the plan as a prefix, but plenty of online numbers have
-             been found so this is being retained for now.  It is possible however that these may be
+             been found so this is being retained for now. It is possible however that these may be
              old-format mobile numbers. -->
         <nationalNumberPattern>
           (?:
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>991234567</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.malawiembassy.org/visit/contact.html -->
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_959.html -->
-        <nationalNumberPattern>
-          199|
-          99[789]
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>997</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Mexico -->
-    <!-- http://www.itu.int/oth/T020200008A/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B52 -->
-    <!-- http://en.wikipedia.org/wiki/Premium-rate_telephone_number#Mexico -->
-    <!-- http://en.wikipedia.org/wiki/Toll-free_telephone_number -->
     <territory id="MX" countryCode="52" internationalPrefix="0[09]"
                nationalPrefix="01"
                nationalPrefixForParsing="0[12]|04[45](\d{10})"
                nationalPrefixTransformRule="1$1"
                nationalPrefixFormattingRule="$NP $FG"
-               nationalPrefixOptionalWhenFormatting="true">
+               nationalPrefixOptionalWhenFormatting="true"
+               leadingZeroPossible="true" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200008A/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B52</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Premium-rate_telephone_number#Mexico</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Toll-free_telephone_number</sourceUrl>
+      </references>
       <!-- When a number starts with 01 or 02, we remove the prefixes; when a number starts with 044
            or 045 followed by 10 digits, we replace the prefixes with 1. This way all the mobile
            numbers, regardless of whether they are written in international format (leading 1) or
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9001234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          06[568]|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>066</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Malaysia -->
-    <!-- http://en.wikipedia.org/wiki/%2B60 -->
-    <!-- http://www.skmm.gov.my -->
     <territory id="MY" countryCode="60" internationalPrefix="00"
-               nationalPrefix="0">
+               nationalPrefix="0" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B60</sourceUrl>
+        <sourceUrl>http://www.skmm.gov.my</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="$NP$FG"
           pattern="([4-79])(\d{3})(\d{4})">
       <mobile>
         <!-- Although the plan lists the prefix 159 as broadband services (data only), apparently it
              is possible to send SMSs (and receive them) from numbers in this block, so we are
-             listing them as mobile. -->
+             listing them as mobile. 115 was added based on numbers found online. -->
         <nationalNumberPattern>
           1(?:
-            1[1-3]\d{2}|
+            1[1-35]\d{2}|
             [02-4679][2-9]\d|
             59\d{2}|
             8(?:
         <exampleNumber>123456789</exampleNumber>
       </mobile>
       <tollFree>
-        <nationalNumberPattern>1[38]00\d{6}</nationalNumberPattern>
+        <!-- http://www.skmm.gov.my/skmmgovmy/media/General/pdf/Special_Service_Number.pdf -->
+        <nationalNumberPattern>1[378]00\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>1300123456</exampleNumber>
       </tollFree>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>1600123456</exampleNumber>
       </premiumRate>
-      <personalNumber>
-        <nationalNumberPattern>1700\d{6}</nationalNumberPattern>
-        <possibleNumberPattern>\d{10}</possibleNumberPattern>
-        <exampleNumber>1700123456</exampleNumber>
-      </personalNumber>
       <voip>
         <nationalNumberPattern>154\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>1541234567</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Mozambique -->
-    <!-- http://www.itu.int/oth/T0202000091/en -->
     <territory id="MZ" countryCode="258" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000091/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([28]\d)(\d{3})(\d{3,4})">
           <leadingDigits>
             2|
-            8[246]
+            8[2-7]
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <exampleNumber>21123456</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>8[246]\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>8[23467]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>821234567</exampleNumber>
       </mobile>
       <!-- The plan suggests 801 and 802 numbers are shared-cost numbers, and numbers beginning with
            a 9 are premium rate, but no online examples can be found of any of these so they are
            omitted for the time-being. -->
-      <emergency>
-        <!-- 11X is national, 19X is for Maputo. -->
-        <!-- http://www.lonelyplanet.com/shop_pickandmix/previews/mozambique-maputo-preview.pdf -->
-        <!-- http://ccmusa.online.co.mz/index.php?option=com_content&task=view&id=20&Itemid=30 -->
-        <nationalNumberPattern>
-          1(?:
-            1[79]|
-            9[78]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>119</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Namibia -->
-    <!-- http://www.itu.int/oth/T0202000093/en -->
     <territory id="NA" countryCode="264" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000093/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(8\d)(\d{3})(\d{4})">
           <leadingDigits>8[1235]</leadingDigits>
                 7\d?
               )|
               3(?:
-                2\d|
-                3[378]
+                [01378]|
+                2\d
               )|
               4[01]|
               69|
             )|
             2(?:
               17|
-              25|
               5(?:
                 [0-36-8]|
                 4\d?
       <voip>
         <!-- Including virtual telephone and VOIP services. -->
         <nationalNumberPattern>
-          8(
+          8(?:
             3\d{2}|
             86
           )\d{5}
         </nationalNumberPattern>
         <exampleNumber>88612345</exampleNumber>
       </voip>
-      <emergency>
-        <!-- ITU doc reserves 9XX for emergency numbers. No examples found. -->
-        <!-- http://www.namibia-1on1.com/information/a-emergencynos.html -->
-        <nationalNumberPattern>10111</nationalNumberPattern>
-        <possibleNumberPattern>\d{5}</possibleNumberPattern>
-        <exampleNumber>10111</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- New Caledonia (Territoire français d'outre-mer) -->
-    <!-- http://www.itu.int/oth/T0202000098/en -->
     <territory id="NC" countryCode="687" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000098/en</sourceUrl>
+        <sourceUrl>http://www.opt.nc</sourceUrl>
+      </references>
       <availableFormats>
-        <!-- From www.1012.nc, the local yellow pages. -->
+        <!-- From http://www.1012.nc, the local yellow pages. -->
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
+          <!-- We exclude short-codes here so they are formatted as a block -->
+          <leadingDigits>
+            [2-46-9]|
+            5[0-4]
+          </leadingDigits>
           <format>$1.$2.$3</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[2-47-9]\d{5}</nationalNumberPattern>
+        <nationalNumberPattern>[2-57-9]\d{5}</nationalNumberPattern>
         <possibleNumberPattern>\d{6}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
       <mobile>
         <nationalNumberPattern>
           (?:
+            5[0-4]|
             [79]\d|
             8[0-79]
           )\d{4}
         <exampleNumber>751234</exampleNumber>
       </mobile>
       <!-- Listed as "voice services", from what we've seen they seem to cost extra. -->
+      <!-- Note that OPT lists 3631 as a free short number for caller ID services, but the ITU
+           document says that all 36 numbers are 6 digits. See ShortNumberMetadata.xml for more. -->
       <premiumRate>
         <nationalNumberPattern>36\d{4}</nationalNumberPattern>
         <exampleNumber>366711</exampleNumber>
       </premiumRate>
-      <!-- http://www.routard.com/guide/nouvelle_caledonie/2343/vie_pratique.htm -->
-      <emergency>
-        <nationalNumberPattern>1[5-8]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Niger -->
-    <!-- http://www.itu.int/oth/T020200009B/en -->
     <territory id="NE" countryCode="227" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200009B/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <leadingDigits>
         <exampleNumber>20201234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Added 90, 91, 92, 97, 98 & 99 from online data. Airtel have confirmed that they use the
-             89 and 97 prefixes, and Orange use 92. -->
+        <!-- Added 90, 91, 92, 95, 97, 98 & 99 from online data. Airtel have confirmed that they use the
+             89 and 97 prefixes, and Orange use 92. MOOV started using 95 in Jan 2014. -->
         <nationalNumberPattern>
           (?:
             89|
-            9[0-46-9]
+            9\d
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>93123456</exampleNumber>
         <nationalNumberPattern>09\d{6}</nationalNumberPattern>
         <exampleNumber>09123456</exampleNumber>
       </premiumRate>
-      <!-- No emergency numbers information can be found. -->
     </territory>
 
     <!-- Norfolk Island -->
-    <!-- http://www.itu.int/oth/T020200009D/en -->
     <!-- Including numbers for Australian Antarctic stations. -->
     <territory id="NF" countryCode="672" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200009D/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{4})">
            <leadingDigits>1</leadingDigits>
         <exampleNumber>106609</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>38\d{4}</nationalNumberPattern>
+        <!-- Numbers found online with prefix 35. -->
+        <nationalNumberPattern>3[58]\d{4}</nationalNumberPattern>
         <exampleNumber>381234</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.discovernorfolkisland.com/norfolk/ -->
-        <nationalNumberPattern>
-          9(?:
-            11|
-            55|
-            77
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Nigeria -->
-    <!-- http://www.itu.int/oth/T020200009C/en -->
     <territory id="NG" countryCode="234" internationalPrefix="009"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200009C/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([129])(\d{3})(\d{3,4})">
           <leadingDigits>[129]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="([3-8]\d)(\d{3})(\d{2,3})">
+        <numberFormat pattern="(\d{2})(\d{3})(\d{2,3})">
           <leadingDigits>
             [3-6]|
             7(?:
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="([78]\d{2})(\d{3})(\d{3,4})">
+        <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
           <leadingDigits>
             70|
-            8[01]
+            8[01]|
+            90[2359]
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
-          [1-69]\d{5,8}|
+          [1-6]\d{5,8}|
+          9\d{5,9}|
           [78]\d{5,13}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{5,14}</possibleNumberPattern>
       <fixedLine>
         <nationalNumberPattern>
           [12]\d{6,7}|
-          9\d{7}|
+          9(?:
+            0[3-9]|
+            [1-9]\d
+          )\d{5}|
           (?:
             3\d|
             4[023568]|
              from Etisalat, 814 MTN and 811 from Glo. Furthermore, the fixed-line prefixes owned by
              Starcomms have apparently, according to the company, been used for mobile numbers too,
              despite the ITU plan, so we list them here as well. 701 has been added for Airtel/Zain.
-             -->
+             903 has been added for MTN, 905 has been added for Globacom (Glo), and 909 has been
+             added for Etisalat. -->
         <nationalNumberPattern>
           (?:
             1(?:
             8(?:
               0[2-9]|
               1\d
-            )\d
+            )\d|
+            90[2359]\d
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
         <possibleNumberPattern>\d{10,14}</possibleNumberPattern>
         <exampleNumber>7001234567</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>199</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>199</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Nicaragua -->
-    <!-- http://www.itu.int/oth/T020200009A/en -->
     <territory id="NI" countryCode="505" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200009A/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <format>$1 $2</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[128]\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>[12578]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
         <exampleNumber>21234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>8\d{7}</nationalNumberPattern>
+        <!-- 55[0-7], 57, 58 and 7[5-8] were added from bug reports/numbers found online. -->
+        <nationalNumberPattern>
+          5(?:
+            5[0-7]\d{5}|
+            [78]\d{6}
+          )|
+          7[5-8]\d{6}|
+          8\d{7}
+        </nationalNumberPattern>
         <exampleNumber>81234567</exampleNumber>
       </mobile>
       <tollFree>
         <nationalNumberPattern>1800\d{4}</nationalNumberPattern>
         <exampleNumber>18001234</exampleNumber>
       </tollFree>
-      <emergency>
-        <nationalNumberPattern>118</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>118</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Netherlands -->
-    <!-- http://en.wikipedia.org/wiki/%2B31 -->
-    <!-- http://www.opta.nl/en/numbers/search-for-numbers -->
     <territory id="NL" countryCode="31" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B31</sourceUrl>
+        <sourceUrl>http://www.opta.nl/en/numbers/search-for-numbers</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([1-578]\d)(\d{3})(\d{4})">
           <leadingDigits>
       <premiumRate>
         <nationalNumberPattern>90[069]\d{4,7}</nationalNumberPattern>
         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
-        <exampleNumber>9001234</exampleNumber>
+        <exampleNumber>9061234</exampleNumber>
       </premiumRate>
       <voip>
         <nationalNumberPattern>85\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{5,6}</possibleNumberPattern>
         <exampleNumber>14020</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Norway -->
     <!-- Metadata (excluding fixed-line) shared with Svalbard. -->
-    <!-- http://www.npt.no/npt/numsys/E.164.pdf -->
     <territory id="NO" countryCode="47" internationalPrefix="00" leadingZeroPossible="true"
-               mainCountryForCode="true">
+               mainCountryForCode="true" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.npt.no/npt/numsys/E.164.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([489]\d{2})(\d{2})(\d{3})">
           <leadingDigits>[489]</leadingDigits>
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
-        <exampleNumber>41234567</exampleNumber>
+        <exampleNumber>40612345</exampleNumber>
       </mobile>
       <tollFree>
         <nationalNumberPattern>80[01]\d{5}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>81212345</exampleNumber>
       </voicemail>
-      <emergency>
-        <nationalNumberPattern>11[023]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Nepal -->
-    <!-- http://www.itu.int/oth/T0202000095/en -->
-    <!-- http://www.ntc.net.np/mobile/mob_postpaid_number_scheme.php -->
     <territory id="NP" countryCode="977" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000095/en</sourceUrl>
+        <sourceUrl>http://www.ntc.net.np/mobile/mob_postpaid_number_scheme.php</sourceUrl>
+        <sourceUrl>http://www.nta.gov.np/en/2012-06-01-11-45-17/2012-06-04-04-26-59/numbering-plan</sourceUrl>
+      </references>
       <availableFormats>
-        <!-- Formatting patterns taken from pages like www.nepalgov.gov.np -->
+        <!-- Formatting patterns taken from pages like http://www.nepalgov.gov.np -->
         <numberFormat pattern="(1)(\d{7})">
           <leadingDigits>1[2-6]</leadingDigits>
           <format>$1-$2</format>
         <numberFormat pattern="(9\d{2})(\d{7})">
           <leadingDigits>
             9(?:
-              7[45]|
+              6[013]|
+              7[245]|
               8
             )
             </leadingDigits>
         <nationalNumberPattern>
           [1-8]\d{7}|
           9(?:
-            [1-69]\d{6}|
+            [1-69]\d{6,8}|
             7[2-6]\d{5,7}|
             8\d{8}
           )
         </nationalNumberPattern>
         <possibleNumberPattern>\d{6,10}</possibleNumberPattern>
       </generalDesc>
+      <!-- We don't support Rural Telecommunication Service at the moment since
+           we are not sure what type it is. -->
       <fixedLine>
-        <!-- Added (1) 2XXXXXX and (88) from numbers found online. -->
         <nationalNumberPattern>
           (?:
-            1[0124-6]|
-            2[13-79]|
-            3[135-8]|
-            4[146-9]|
-            5[135-7]|
-            6[13-9]|
-            7[15-9]|
-            8[1-46-9]|
-            9[1-79]
-          )\d{6}
+            1[0-6]\d|
+            2[13-79][2-6]|
+            3[135-8][2-6]|
+            4[146-9][2-6]|
+            5[135-7][2-6]|
+            6[13-9][2-6]|
+            7[15-9][2-6]|
+            8[1-46-9][2-6]|
+            9[1-79][2-6]
+          )\d{5}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{6,8}</possibleNumberPattern>
         <exampleNumber>14567890</exampleNumber>
       </fixedLine>
-      <!-- There is no definitive source of information for mobile numbers in Nepal. The infomation
-           here is collected by searching the Internet. -->
       <mobile>
         <nationalNumberPattern>
           9(?:
-            7[45]|
-            8[0145]
+            6[013]|
+            7[245]|
+            8[01456]
           )\d{7}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9841234567</exampleNumber>
       </mobile>
       <!-- No information on other types of phone numbers for Nepal has been found. -->
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[0-3]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Nauru -->
-    <!-- http://www.itu.int/oth/T0202000094/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Nauru -->
     <territory id="NR" countryCode="674" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000094/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Nauru</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         <nationalNumberPattern>55[5-9]\d{4}</nationalNumberPattern>
         <exampleNumber>5551234</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>11[0-2]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>110</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Niue -->
-    <!-- http://www.itu.int/oth/T02020000EC/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Niue -->
     <territory id="NU" countryCode="683" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000EC/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Niue</sourceUrl>
+      </references>
       <!-- Numbers are always formatted as a block. -->
       <generalDesc>
         <nationalNumberPattern>[1-5]\d{3}</nationalNumberPattern>
         <nationalNumberPattern>[125]\d{3}</nationalNumberPattern>
         <exampleNumber>1234</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- New Zealand -->
-    <!-- http://www.itu.int/oth/T0202000099/en -->
     <!-- Includes Ross Dependency, Antarctica -->
     <!-- Does not currently support 083 "Enhanced voice services", New Zealand direct service
          numbers and 050 "Nation-Wide Service". -->
     <territory id="NZ" countryCode="64" internationalPrefix="0(?:0|161)"
                preferredInternationalPrefix="00" nationalPrefix="0"
-               nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefixFormattingRule="$NP$FG" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000099/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Pattern for fixed-line formats. -->
         <numberFormat pattern="([34679])(\d{3})(\d{4})">
           <format>$1 $2 $3</format>
         </numberFormat>
         <!-- Paging numbers and some mobile numbers (Telecom/Vodafone/TelstraClear). -->
-        <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})">
+        <numberFormat pattern="(\d{2})(\d{3})(\d{3,5})">
           <leadingDigits>
             2(?:
               1[1-9]|
         </numberFormat>
         <!-- 2Degrees numbers are formatted with 022 separated, since this seems to be more common
              than writing the first group as 022X based on Google web searches, and is used by
-             2Degrees themselves. See formatting on www.2degreesmobile.co.nz for an example of the
-             latter. We follow the same pattern for 020 (Orcon) and 028 (mixed) numbers. -->
+             2Degrees themselves. See formatting on http://www.2degreesmobile.co.nz for an example
+             of the latter. We follow the same pattern for 020 (Orcon) and 028 (mixed) numbers. -->
         <numberFormat pattern="(2\d)(\d{3,4})(\d{4})">
           <leadingDigits>2[028]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3,4})">
-          <!-- 0274, 0210 and toll-free/premium-rate prefixes 0508/0800/0900.  -->
+          <!-- 0274, 0210 and toll-free/premium-rate prefixes 0508/0800/0900. -->
           <leadingDigits>
             2(?:
               10|
         <exampleNumber>32345678</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Includes mobile radio service numbers (e.g. TeamTalk). -->
+        <!-- Includes mobile radio service numbers (e.g. TeamTalk). The lengths of numbers with
+             prefix 21 are different from what's specified in the ITU doc, because of numbers found
+             online. -->
         <nationalNumberPattern>
           2(?:
             [028]\d{7,8}|
             1(?:
-              0\d{5,7}|
-              [12]\d{5,6}|
-              [3-9]\d{5}
+              [03]\d{5,7}|
+              [12457]\d{5,6}|
+              [689]\d{5}
             )|
             [79]\d{7}
           )
         <possibleNumberPattern>\d{9,11}</possibleNumberPattern>
         <exampleNumber>900123456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>111</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>111</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Oman -->
-    <!-- http://www.itu.int/oth/T020200009F/en -->
-    <territory id="OM" countryCode="968" internationalPrefix="00" >
+    <territory id="OM" countryCode="968" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200009F/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(2\d)(\d{6})">
           <leadingDigits>2</leadingDigits>
         <exampleNumber>92123456</exampleNumber>
       </mobile>
       <tollFree>
-        <!-- Link to document about toll-free numbers on www.tra.gov.om, which suggests they should
-             be 8007 followed by 4 digits. However, the only examples I can find, including the
-             customer help line for the main telephony company there (omantel), is 8007 followed by
-             5 digits, so am allowing both for now to be on the safe side. 500 numbers seem to offer
-             international toll-free dialing numbers - +968 500 1300 for international help desk for
-             omantel, for example. -->
+        <!-- Link to document about toll-free numbers on http://www.tra.gov.om, which suggests they
+             should be 8007 followed by 4 digits. However, the only examples I can find, including
+             the customer help line for the main telephony company there (omantel), is 8007 followed
+             by 5 digits, so am allowing both for now to be on the safe side. 500 numbers seem to
+             offer international toll-free dialing numbers - +968 500 1300 for international help
+             desk for omantel, for example. -->
         <nationalNumberPattern>
           8007\d{4,5}|
           500\d{4}
         <exampleNumber>80071234</exampleNumber>
       </tollFree>
       <!-- No premiumRate information can be found. -->
-      <emergency>
-        <nationalNumberPattern>9999</nationalNumberPattern>
-        <possibleNumberPattern>\d{4}</possibleNumberPattern>
-        <exampleNumber>9999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Panama -->
-    <!-- http://www.asep.gob.pa/telecom/pnn/default.asp - last read Jan 17th 2013. -->
-    <!-- http://en.wikipedia.org/wiki/%2B507 - although it omits the fact that mobile phones are 8
-         digits long. -->
-    <territory id="PA" countryCode="507" internationalPrefix="00">
+    <territory id="PA" countryCode="507" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <!-- Last read July 9, 2014. -->
+        <sourceUrl>http://www.asep.gob.pa/telecom/pnn/default.asp</sourceUrl>
+        <!-- Omits the fact that mobile phones are 8 digits long. -->
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B507</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>[1-57-9]</leadingDigits>
               65|
               7[016-8]|
               8[58]|
-              9[134]
+              9[1349]
             )|
             2(?:
               [0235679]\d|
               8[028]
             )|
             3(?:
-              0[0-7]|
+              [09]\d|
               1[14-7]|
               2[0-3]|
               3[03]|
               4[0457]|
               5[56]|
               6[068]|
-              7[078]|
-              80|
-              9\d
+              7[06-8]|
+              8[089]
             )|
             4(?:
-              3[013-59]|
+              3[013-69]|
               4\d|
               7[0-689]
             )|
             7(?:
               0[09]|
               2[0-267]|
-              [349]0|
-              5[6-9]|
+              3[06]|
+              [49]0|
+              5[06-9]|
               7[0-24-7]|
               8[89]
             )|
               8[02]
             )|
             9(?:
-              0[78]|
-              1[0178]|
-              2[0378]|
-              3[379]|
+              0[6-8]|
+              1[016-8]|
+              2[036-8]|
+              3[3679]|
               40|
               5[0489]|
               6[06-9]|
             )
           )\d{4}|
           6(?:
-            [04-9]\d|
+            [024-9]\d|
             1[0-5]|
-            2[0-7]|
-            3[5-9]
+            3[0-24-9]
           )\d{5}
         </nationalNumberPattern>
         <exampleNumber>60012345</exampleNumber>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>8601234</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Peru -->
-    <!-- http://www.itu.int/oth/T02020000A6/en -->
-    <!-- http://en.wikipedia.org/wiki/+51 -->
-    <!-- http://www.assistbook.com/South%20America/Peru/widecodes -->
     <territory id="PE" countryCode="51" internationalPrefix="19(?:1[124]|77|90)00"
                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
-               preferredExtnPrefix=" Anexo ">
+               preferredExtnPrefix=" Anexo " mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000A6/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+51</sourceUrl>
+        <sourceUrl>http://www.assistbook.com/South%20America/Peru/widecodes</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(1)(\d{7})">
           <leadingDigits>1</leadingDigits>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>80212345</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            05|
-            1[67]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>105</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- French Polynesia (Tahiti) (Territoire français d'outre-mer) -->
-    <!-- http://www.itu.int/oth/T020200004D/en -->
     <territory id="PF" countryCode="689" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200004D/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
-          <leadingDigits>89</leadingDigits>
+          <leadingDigits>
+            4[09]|
+            8[79]
+          </leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
+          <leadingDigits>44</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
-          [2-79]\d{5}|
-          8\d{5,7}
+          4\d{5,7}|
+          8\d{7}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{6}(?:\d{2})?</possibleNumberPattern>
       </generalDesc>
         <exampleNumber>441234</exampleNumber>
       </noInternationalDialling>
       <fixedLine>
-        <!-- Includes "voice-server" prefixes and pay-phone. The 41 range has been made more
-             specific to exclude Mobile MSRN. -->
+        <!-- Includes payphone prefixes. -->
+        <nationalNumberPattern>
+          4(?:
+            [09][45689]\d|
+            4
+          )\d{4}
+        </nationalNumberPattern>
+        <exampleNumber>40412345</exampleNumber>
+      </fixedLine>
+      <mobile>
+        <nationalNumberPattern>8[79]\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{8}</possibleNumberPattern>
+        <exampleNumber>87123456</exampleNumber>
+      </mobile>
+    </territory>
+
+    <!-- Papua New Guinea -->
+    <territory id="PG" countryCode="675" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000A4/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B675</sourceUrl>
+      </references>
+      <availableFormats>
+        <numberFormat pattern="(\d{3})(\d{4})">
+          <leadingDigits>
+            [13-689]|
+            27
+          </leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+        <numberFormat pattern="(\d{4})(\d{4})">
+          <leadingDigits>
+            20|
+            7
+          </leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+      </availableFormats>
+      <generalDesc>
+        <nationalNumberPattern>[1-9]\d{6,7}</nationalNumberPattern>
+        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
+      </generalDesc>
+      <fixedLine>
         <nationalNumberPattern>
           (?:
-            4(?:
-              [02-9]\d|
-              1[02-9]
+            3[0-2]\d|
+            4[25]\d|
+            5[34]\d|
+            64[1-9]|
+            77(?:
+              [0-24]\d|
+              30
             )|
-            [5689]\d{2}
-          )\d{3}
+            85[02-46-9]|
+            9[78]\d
+          )\d{4}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{6}</possibleNumberPattern>
-        <exampleNumber>401234</exampleNumber>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
+        <exampleNumber>3123456</exampleNumber>
       </fixedLine>
       <mobile>
+        <!-- Mobile number patterns from the numbering plan are included here, as well as 68X from
+             Wikipedia.
+             As per ITU doc, prefix 20150 will expire at the end of 2015. -->
         <nationalNumberPattern>
           (?:
-            [27]\d{2}|
-            3[0-79]\d|
-            411|
-            89\d{3}
+            20150|
+            68\d{2}|
+            7(?:
+              [0-369]\d|
+              75
+            )\d{2}
           )\d{3}
         </nationalNumberPattern>
-        <exampleNumber>212345</exampleNumber>
+        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
+        <exampleNumber>6812345</exampleNumber>
       </mobile>
-      <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-      <emergency>
-        <nationalNumberPattern>1[578]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
+      <tollFree>
+        <nationalNumberPattern>180\d{4}</nationalNumberPattern>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
+        <exampleNumber>1801234</exampleNumber>
+      </tollFree>
+      <voip>
+        <!-- VSAT prefixes are here. -->
+        <nationalNumberPattern>275\d{4}</nationalNumberPattern>
+        <possibleNumberPattern>\d{7}</possibleNumberPattern>
+        <exampleNumber>2751234</exampleNumber>
+      </voip>
     </territory>
 
-    <!-- Papua New Guinea -->
-    <!-- http://www.itu.int/oth/T02020000A4/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B675 -->
-    <territory id="PG" countryCode="675" internationalPrefix="00">
+    <!-- Philippines -->
+    <territory id="PH" countryCode="63" internationalPrefix="00" nationalPrefix="0">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B63</sourceUrl>
+      </references>
       <availableFormats>
-        <numberFormat pattern="(\d{3})(\d{4})">
-          <leadingDigits>[1-689]</leadingDigits>
+        <!-- Area code separated from number. Area codes found here:
+        http://en.wikipedia.org/wiki/Telecommunications_in_the_Philippines#Area_Codes -->
+        <numberFormat nationalPrefixFormattingRule="($NP$FG)"
+          pattern="(2)(\d{3})(\d{4})">
+          <leadingDigits>2</leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
+        <numberFormat nationalPrefixFormattingRule="($NP$FG)"
+          pattern="(2)(\d{5})">
+          <leadingDigits>2</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
-        <numberFormat pattern="(7\d{2})(\d{2})(\d{3})">
-          <leadingDigits>7</leadingDigits>
+        <numberFormat nationalPrefixFormattingRule="($NP$FG)"
+          pattern="(\d{4})(\d{4,6})">
+          <leadingDigits>
+            3(?:
+              23|
+              39|
+              46
+            )|
+            4(?:
+              2[3-6]|
+              [35]9|
+              4[26]|
+              76
+            )|
+            5(?:
+              22|
+              44
+            )|
+            642|
+            8(?:
+              62|
+              8[245]
+            )
+          </leadingDigits>
+          <leadingDigits>
+            3(?:
+              230|
+              397|
+              461
+            )|
+            4(?:
+              2(?:
+                35|
+                [46]4|
+                51
+              )|
+              396|
+              4(?:
+                22|
+                63
+              )|
+              59[347]|
+              76[15]
+            )|
+            5(?:
+              221|
+              446
+            )|
+            642[23]|
+            8(?:
+              622|
+              8(?:
+                [24]2|
+                5[13]
+              )
+            )
+          </leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+        <numberFormat nationalPrefixFormattingRule="($NP$FG)"
+          pattern="(\d{5})(\d{4})">
+          <leadingDigits>
+            346|
+            4(?:
+              27|
+              9[35]
+            )|
+            883
+          </leadingDigits>
+          <leadingDigits>
+            3469|
+            4(?:
+              279|
+              9(?:
+                30|
+                56
+              )
+            )|
+            8834
+          </leadingDigits>
+          <format>$1 $2</format>
+        </numberFormat>
+        <!-- This rule is a fallback for the more specific area codes. -->
+        <numberFormat nationalPrefixFormattingRule="($NP$FG)"
+          pattern="([3-8]\d)(\d{3})(\d{4})">
+          <leadingDigits>[3-8]</leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
+        <numberFormat nationalPrefixFormattingRule="$NP$FG"
+          pattern="(\d{3})(\d{3})(\d{4})">
+          <leadingDigits>
+            81|
+            9
+          </leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
+        <!-- Formatting from http://www.uniontelecard.com/calling-guides/philippines/guide1.aspx -->
+        <numberFormat pattern="(1800)(\d{3})(\d{4})">
+          <leadingDigits>1</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
+        <numberFormat pattern="(1800)(\d{1,2})(\d{3})(\d{4})">
+          <leadingDigits>1</leadingDigits>
+          <format>$1 $2 $3 $4</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[1-9]\d{6,7}</nationalNumberPattern>
-        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
+        <nationalNumberPattern>
+          2\d{5,7}|
+          [3-9]\d{7,9}|
+          1800\d{7,9}
+        </nationalNumberPattern>
+        <possibleNumberPattern>\d{5,13}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Fixed line patterns are from the numbering plan, with additions for 4XX since many
-             numbers in the yellow pages seem to be outside the 47X range prescribed by the plan.
-             The same applies to extra 64X numbers. -->
+        <!-- Evidence on number length is hard to come by. We have found diallable numbers in Manila
+             that have only 5 digits after the area code; plus it seems the 8822 area code is
+             followed by 6 digits, and 8842 by only 4. -->
         <nationalNumberPattern>
+          2\d{5}(?:\d{2})?|
           (?:
-            3\d{2}|
-            4[257]\d|
-            5[34]\d|
-            6(?:
-              29|
-              4[1-9]
-            )|
-            85[02-46-9]|
-            9[78]\d
-          )\d{4}
+            3[2-68]|
+            4[2-9]|
+            5[2-6]|
+            6[2-58]|
+            7[24578]|
+            8[2-8]
+          )\d{7}|
+          88(?:
+            22\d{6}|
+            42\d{4}
+          )
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{7}</possibleNumberPattern>
-        <exampleNumber>3123456</exampleNumber>
+        <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
+        <exampleNumber>21234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Mobile number patterns from the numbering plan are included here, as well as 68X from
-             Wikipedia and 730 from online numbers. The prefix 70X is added since open-source users
-             have reported it as now being in use, although no real numbers can be found as of yet.
-             -->
         <nationalNumberPattern>
           (?:
-            68|
-            7[0-36]\d
-          )\d{5}
+            81[37]|
+            9(?:
+              0[5-9]|
+              1[024-9]|
+              2[0-35-9]|
+              3[02-9]|
+              4[236-9]|
+              7[34-79]|
+              89|
+              9[4-9]
+            )
+          )\d{7}
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
-        <exampleNumber>6812345</exampleNumber>
+        <possibleNumberPattern>\d{10}</possibleNumberPattern>
+        <exampleNumber>9051234567</exampleNumber>
       </mobile>
+      <!-- Information on toll-free numbers collected from searching the internet -->
       <tollFree>
-        <nationalNumberPattern>180\d{4}</nationalNumberPattern>
-        <possibleNumberPattern>\d{7}</possibleNumberPattern>
-        <exampleNumber>1801234</exampleNumber>
+        <nationalNumberPattern>1800\d{7,9}</nationalNumberPattern>
+        <possibleNumberPattern>\d{11,13}</possibleNumberPattern>
+        <exampleNumber>180012345678</exampleNumber>
       </tollFree>
-      <voip>
-        <!-- VSAT prefixes are here. -->
-        <nationalNumberPattern>275\d{4}</nationalNumberPattern>
-        <possibleNumberPattern>\d{7}</possibleNumberPattern>
-        <exampleNumber>2751234</exampleNumber>
-      </voip>
-      <emergency>
-        <!-- http://www.pngbd.com/emergency.php has been used, excluding fixed-line phone-numbers.
-             -->
-        <nationalNumberPattern>000</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>000</exampleNumber>
-      </emergency>
+      <!-- No information can be found about other types of numbers (such as premium rate) in the
+           Philippines. -->
     </territory>
 
-    <!-- Philippines -->
-    <!-- http://en.wikipedia.org/wiki/%2B63 -->
-  <territory id="PH" countryCode="63" internationalPrefix="00" nationalPrefix="0">
-    <availableFormats>
-      <!--Area code separated from number. Area codes found here:
-      http://en.wikipedia.org/wiki/Telecommunications_in_the_Philippines#Area_Codes -->
-      <numberFormat nationalPrefixFormattingRule="($NP$FG)"
-        pattern="(2)(\d{3})(\d{4})">
-        <leadingDigits>2</leadingDigits>
-        <format>$1 $2 $3</format>
-      </numberFormat>
-      <numberFormat nationalPrefixFormattingRule="($NP$FG)"
-        pattern="(2)(\d{5})">
-        <leadingDigits>2</leadingDigits>
-        <format>$1 $2</format>
-      </numberFormat>
-      <numberFormat nationalPrefixFormattingRule="($NP$FG)"
-        pattern="(\d{4})(\d{4,6})">
-        <leadingDigits>
-          3(?:
-            23|
-            39|
-            46
-          )|
-          4(?:
-            2[3-6]|
-            [35]9|
-            4[26]|
-            76
-          )|
-          5(?:
-            22|
-            44
-          )|
-          642|
-          8(?:
-            62|
-            8[245]
-          )
-        </leadingDigits>
-        <leadingDigits>
-          3(?:
-            230|
-            397|
-            461
-          )|
-          4(?:
-            2(?:
-              35|
-              [46]4|
-              51
-            )|
-            396|
-            4(?:
-              22|
-              63
-            )|
-            59[347]|
-            76[15]
-          )|
-          5(?:
-            221|
-            446
-          )|
-          642[23]|
-          8(?:
-            622|
-            8(?:
-              [24]2|
-              5[13]
-            )
-          )
-        </leadingDigits>
-        <format>$1 $2</format>
-      </numberFormat>
-      <numberFormat nationalPrefixFormattingRule="($NP$FG)"
-        pattern="(\d{5})(\d{4})">
-        <leadingDigits>
-          346|
-          4(?:
-            27|
-            9[35]
-          )|
-          883
-        </leadingDigits>
-        <leadingDigits>
-          3469|
-          4(?:
-            279|
-            9(?:
-              30|
-              56
-            )
-          )|
-          8834
-        </leadingDigits>
-        <format>$1 $2</format>
-      </numberFormat>
-      <!-- This rule is a fallback for the more specific area codes. -->
-      <numberFormat nationalPrefixFormattingRule="($NP$FG)"
-        pattern="([3-8]\d)(\d{3})(\d{4})">
-        <leadingDigits>[3-8]</leadingDigits>
-        <format>$1 $2 $3</format>
-      </numberFormat>
-      <numberFormat nationalPrefixFormattingRule="$NP$FG"
-        pattern="(\d{3})(\d{3})(\d{4})">
-        <leadingDigits>
-          81|
-          9
-        </leadingDigits>
-        <format>$1 $2 $3</format>
-      </numberFormat>
-      <!-- Formatting from http://www.uniontelecard.com/calling-guides/philippines/guide1.aspx -->
-      <numberFormat pattern="(1800)(\d{3})(\d{4})">
-        <leadingDigits>1</leadingDigits>
-        <format>$1 $2 $3</format>
-      </numberFormat>
-      <numberFormat pattern="(1800)(\d{1,2})(\d{3})(\d{4})">
-        <leadingDigits>1</leadingDigits>
-        <format>$1 $2 $3 $4</format>
-      </numberFormat>
-    </availableFormats>
-    <generalDesc>
-      <nationalNumberPattern>
-        2\d{5,7}|
-        [3-9]\d{7,9}|
-        1800\d{7,9}
-      </nationalNumberPattern>
-      <possibleNumberPattern>\d{5,13}</possibleNumberPattern>
-    </generalDesc>
-    <fixedLine>
-      <!-- Evidence on number length is hard to come by. We have found diallable numbers in Manila
-           that have only 5 digits after the area code; plus it seems the 8822 area code is followed
-           by 6 digits, and 8842 by only 4. -->
-      <nationalNumberPattern>
-        2\d{5}(?:\d{2})?|
-        (?:
-          3[2-68]|
-          4[2-9]|
-          5[2-6]|
-          6[2-58]|
-          7[24578]|
-          8[2-8]
-        )\d{7}|
-        88(?:
-          22\d{6}|
-          42\d{4}
-        )
-      </nationalNumberPattern>
-      <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
-      <exampleNumber>21234567</exampleNumber>
-    </fixedLine>
-    <mobile>
-      <nationalNumberPattern>
-        (?:
-          81[37]|
-          9(?:
-            0[5-9]|
-            1[025-9]|
-            2[0-35-9]|
-            3[02-9]|
-            4[236-9]|
-            7[3479]|
-            89|
-            9[46-9]
-          )
-        )\d{7}
-      </nationalNumberPattern>
-      <possibleNumberPattern>\d{10}</possibleNumberPattern>
-      <exampleNumber>9051234567</exampleNumber>
-    </mobile>
-    <!-- Information on toll-free numbers collected from searching the internet -->
-    <tollFree>
-      <nationalNumberPattern>1800\d{7,9}</nationalNumberPattern>
-      <possibleNumberPattern>\d{11,13}</possibleNumberPattern>
-      <exampleNumber>180012345678</exampleNumber>
-    </tollFree>
-    <!-- No information can be found about other types of numbers (such as premium rate) in the
-         Philippines. -->
-    <emergency>
-      <nationalNumberPattern>
-        11[27]|
-        911
-      </nationalNumberPattern>
-      <possibleNumberPattern>\d{3}</possibleNumberPattern>
-      <exampleNumber>117</exampleNumber>
-    </emergency>
-  </territory>
-
-  <!-- Pakistan -->
-  <!-- http://www.itu.int/oth/T02020000A1/en -->
-  <!-- http://en.wikipedia.org/wiki/%2B92 -->
+    <!-- Pakistan -->
     <territory id="PK" countryCode="92" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
+               nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000A1/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B92</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Universal Access Numbers (UAN) number format patterns first, so that these numbers are
              formatted nicely by the AYTF. -->
       </fixedLine>
       <mobile>
         <!-- Adding 311, 325 and 320 as SMSs have been successfully sent to these numbers and numbers
-             can be found online with these prefixes. -->
+             can be found online with these prefixes. Added 310 based on information from Zong, and
+             316 based on information found online. -->
         <nationalNumberPattern>
           3(?:
             0\d|
-            1[1-5]|
+            1[0-6]|
             2[0-5]|
-            3[1-6]|
-            4[1-7]|
+            [34][0-7]|
             55|
             64
           )\d{7}
       <uan>
         <!-- Data on what a UAN is is hard to come by. http://www.ptcl.com.pk has information under
              http://www.ptcl.com.pk/contentb.php?NID=143#uan - which defines their format - but not
-             what type of number they are.  We exclude Azad Jammu, Kashmir and Northern Areas here
+             what type of number they are. We exclude Azad Jammu, Kashmir and Northern Areas here
              since no online example UANs can be found, and they have an "access code" at the start,
              making it difficult to guess what a UAN in these areas would look like. -->
         <nationalNumberPattern>
         <possibleNumberPattern>\d{11,12}</possibleNumberPattern>
         <exampleNumber>21111825888</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1(?:
-              22?|
-              5
-            )|
-            [56]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,4}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Poland -->
-    <!-- http://en.wikipedia.org/wiki/%2B48 -->
-    <!-- http://www.itu.int/oth/T02020000A8/en -->
-    <!--
-    http://www.uke.gov.pl/uke/index.jsp?place=Lead24&news_cat_id=277&news_id=3791&layout=9&page=text
-    (in Polish) -->
-    <territory id="PL" countryCode="48" internationalPrefix="00">
+    <territory id="PL" countryCode="48" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B48</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T02020000A8/en</sourceUrl>
+        <!-- Source is in Polish. -->
+        <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>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
           <leadingDigits>
           </leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
-        <numberFormat pattern="(\d{2})(\d{4,6})">
-          <!-- Pattern for shorter fixed-line numbers. -->
-          <leadingDigits>
-            [124]|
-            3[2-4]|
-            5[24-689]|
-            6[1-3578]|
-            7[14-7]|
-            8[1-7]
-          </leadingDigits>
-          <format>$1 $2</format>
+        <numberFormat pattern="(\d{2})(\d{1})(\d{4})">
+          <leadingDigits>[12]2</leadingDigits>
+          <format>$1 $2 $3</format>
         </numberFormat>
         <!-- We are formatting 70 numbers as per mobile numbers, based on information from some
              Poles that this is more usual. -->
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
           <leadingDigits>
             39|
-            5[013]|
+            5[0137]|
             6[0469]|
             7[02389]|
             8[08]
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>
-          [1-58]\d{6,8}|
-          9\d{8}|
-          [67]\d{5,8}
+          [12]\d{6,8}|
+          [3-57-9]\d{8}|
+          6\d{5,8}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- Grouped by prefix-length. -->
+        <!-- The plan says all geographical numbers are 9 digits; but in at least Warsaw (22) and
+             Krakow (12) we have found internationally diallable numbers that are 7 digits instead,
+             so we support those too. -->
         <nationalNumberPattern>
           (?:
             1[2-8]|
             4[1-468]|
             5[24-689]|
             6[1-3578]|
-            7[14-6]|
-            8[1-7]
-          )\d{5,7}|
-          77\d{4,7}|
-          (?:
-            89|
+            7[14-7]|
+            8[1-79]|
             9[145]
-          )\d{7}
+          )\d{7}|
+          [12]2\d{5}
         </nationalNumberPattern>
         <exampleNumber>123456789</exampleNumber>
       </fixedLine>
       <mobile>
         <nationalNumberPattern>
           (?:
-            5[013]|
+            5[0137]|
             6[069]|
             7[2389]|
             88
         <exampleNumber>512345678</exampleNumber>
       </mobile>
       <pager>
-        <nationalNumberPattern>642\d{3,6}</nationalNumberPattern>
-        <exampleNumber>642123456</exampleNumber>
+        <nationalNumberPattern>64\d{4,7}</nationalNumberPattern>
+        <exampleNumber>641234567</exampleNumber>
       </pager>
       <tollFree>
         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>391234567</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          99[789]
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Saint Pierre and Miquelon (Collectivité territoriale de la République française) -->
-    <!-- http://www.itu.int/oth/T02020000B2/en -->
     <territory id="PM" countryCode="508" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B2/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([45]\d)(\d{2})(\d{2})">
           <format>$1 $2 $3</format>
         <nationalNumberPattern>55\d{4} </nationalNumberPattern>
         <exampleNumber>551234</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>1[578]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Pitcairn Island -->
          satellite phones. -->
 
     <!-- Puerto Rico -->
-    <!-- http://www.itu.int/oth/T02020000AA/en -->
     <territory id="PR" countryCode="1" leadingDigits="787|939" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000AA/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://www.frommers.com/destinations/puertorico/0094020157.html
-             http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Palestinian Authority -->
-    <!-- http://en.wikipedia.org/wiki/%2B970 -->
-    <!-- http://www.wtng.info/wtng-970-ps.html -->
-    <!-- http://www.paltel.ps -->
     <!-- Palestinian phone numbers can be reached through the Israeli country code (972) in addition
          to the Palestinian country code (970) and so Palestinian landlines and mobile lines are a
          subset of the Israeli formats. -->
     <territory id="PS" countryCode="970" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B970</sourceUrl>
+        <sourceUrl>http://www.wtng.info/wtng-970-ps.html</sourceUrl>
+        <sourceUrl>http://www.paltel.ps</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([2489])(2\d{2})(\d{4})">
           <leadingDigits>[2489]</leadingDigits>
     </territory>
 
     <!-- Portugal -->
-    <!-- http://www.anacom.pt/render.jsp?categoryId=279098 -->
-    <territory id="PT" countryCode="351" internationalPrefix="00">
+    <territory id="PT" countryCode="351" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.anacom.pt/render.jsp?categoryId=279098</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Note: the wikipedia page suggests that mobile numbers may also be formatted with only
              two digits in the first group; however, this doesn't seem to be majority usage based on
         </nationalNumberPattern>
         <exampleNumber>707123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Palau -->
-    <!-- http://www.itu.int/oth/T02020000A2/en -->
     <territory id="PW" countryCode="680" internationalPrefix="01[12]">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000A2/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         </nationalNumberPattern>
         <exampleNumber>6201234</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Paraguay -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Paraguay -->
-    <!-- http://www.itu.int/oth/T02020000A5/en -->
-    <!-- http://www.copaco.com.py/portal/index.php/component/content/article/8-empresa/74-codigos-de-area.html -->
-    <territory id="PY" countryCode="595" internationalPrefix="00" nationalPrefix="0">
+    <territory id="PY" countryCode="595" internationalPrefix="00" nationalPrefix="0"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Paraguay</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T02020000A5/en</sourceUrl>
+        <sourceUrl>http://www.copaco.com.py/portal/index.php/component/content/article/8-empresa/74-codigos-de-area.html</sourceUrl>
+      </references>
       <availableFormats>
         <!-- CONATEL plan. -->
         <numberFormat pattern="(\d{2})(\d{5,7})" nationalPrefixFormattingRule="($FG)">
         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
         <exampleNumber>201234567</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          128|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Qatar -->
-    <!-- http://www.itu.int/oth/T02020000AB/en -->
-    <!-- http://wtng.info/wtng-qq.html -->
-    <territory id="QA" countryCode="974" internationalPrefix="00">
+    <territory id="QA" countryCode="974" internationalPrefix="00" mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000AB/en</sourceUrl>
+        <sourceUrl>http://wtng.info/wtng-qq.html</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([28]\d{2})(\d{4})">
           <leadingDigits>[28]</leadingDigits>
         <exampleNumber>8001234</exampleNumber>
       </tollFree>
       <!-- No premiumRate information can be found. -->
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Réunion (French Departments and Territories in the Indian Ocean) -->
     <!-- Note this shares the same country code as La Mayotte and the formatting patterns here are
          used by both of them. -->
-    <!-- http://www.itu.int/oth/T020200004B/en -->
     <territory id="RE" countryCode="262" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
                leadingDigits="262|6[49]|8" mainCountryForCode="true" >
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200004B/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([268]\d{2})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
         </nationalNumberPattern>
         <exampleNumber>810123456</exampleNumber>
       </sharedCost>
-      <!-- http://www.reunion.fr/en/navigation-principale/getting-there/practical-information.html -->
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            [578]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Romania -->
-    <!-- http://www.itu.int/oth/T02020000AC/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Romania -->
     <!-- Extension prefix found online, confirmed by a Romanian. -->
     <territory id="RO" countryCode="40" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
-               preferredExtnPrefix=" int ">
+               preferredExtnPrefix=" int " mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000AC/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Romania</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([237]\d)(\d{3})(\d{4})">
           <leadingDigits>[23]1</leadingDigits>
       </fixedLine>
       <mobile>
         <!-- http://www.enigma-system.net/business/customized-phone-number.html confirms that the
-             numbers are restricted to those starting with 07000. -->
+             numbers are restricted to those starting with 07000. Mobile prefix 0799 added based on
+             open-source report and confirmation by existence of such numbers online. -->
         <nationalNumberPattern>
           7(?:
-            000\d{5}|
-            [1-8]\d{7}
-          )
+            000|
+            [1-8]\d{2}|
+            99\d
+          )\d{5}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>712345678</exampleNumber>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>372123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Serbia -->
-    <!-- http://www.itu.int/oth/T02020000B9/en -->
-    <!-- http://registar.ratel.rs/en/reg202 -->
     <territory id="RS" countryCode="381" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B9/en</sourceUrl>
+        <sourceUrl>http://registar.ratel.rs/en/reg202</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([23]\d{2})(\d{4,9})">
           <leadingDigits>
         <possibleNumberPattern>\d{6,12}</possibleNumberPattern>
         <exampleNumber>700123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          9[234]
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Russian Federation -->
-    <!-- http://www.itu.int/oth/T02020000AD/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B7 -->
     <territory id="RU" countryCode="7" mainCountryForCode="true" preferredInternationalPrefix="8~10"
                internationalPrefix="810" nationalPrefix="8"
                nationalPrefixFormattingRule="$NP ($FG)"
                nationalPrefixOptionalWhenFormatting="true" >
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000AD/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B7</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formatting from wikipedia, confirmed on Goverment websites such as
              http://www.minjust.ru/ru/structure/contact/. Contains formatting instructions for
         <nationalNumberPattern>80[39]\d{7}</nationalNumberPattern>
         <exampleNumber>8091234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          0[123]|
-          112
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Rwanda -->
     <!-- According to ITU, there is no national prefix. However, this is still used. As of June 3rd
          2011, this was confirmed by a Rwandan local. It is also shown in this format on pages such
-         as www.tigo.co.rw "Choose Your Number" service. -->
-    <!-- http://www.rura.gov.rw/docs/RWANDA_NATIONAL_NUMBERING_PLAN.pdf -->
-    <!-- http://en.wikipedia.org/wiki/+250 -->
+         as http://www.tigo.co.rw "Choose Your Number" service. -->
     <territory id="RW" countryCode="250" internationalPrefix="00"
                nationalPrefix="0" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.rura.gov.rw/docs/RWANDA_NATIONAL_NUMBERING_PLAN.pdf</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+250</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="$FG"
           pattern="(2\d{2})(\d{3})(\d{3})">
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>900123456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Saudi Arabia -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Saudi_Arabia -->
-    <!-- http://www.itu.int/oth/T02020000B7/en -->
     <territory id="SA" countryCode="966" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Saudi_Arabia</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T02020000B7/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([1-467])(\d{3})(\d{4})">
           <leadingDigits>[1-467]</leadingDigits>
         <!-- It seems that the trunk prefix is not used for these numbers, based on wikipedia and on
              the fact that no numbers of this form found online have a trunk prefix added. -->
         <numberFormat pattern="(92\d{2})(\d{5})" nationalPrefixFormattingRule="$FG">
-          <leadingDigits>9</leadingDigits>
+          <leadingDigits>92</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
         <numberFormat pattern="(800)(\d{3})(\d{4})" nationalPrefixFormattingRule="$FG">
       </generalDesc>
       <fixedLine>
         <!-- Saudi Arabia is in the process of adding a leading 1 to their fixed-line numbers. This
-             is happening in May for area code 1 (parallel running ends July 13th, 2013) and then in
-             August for the other fixed-line numbers. -->
+             happened in May for area code 1 (parallel running ended July 13th, 2013) and then in
+             August for the other fixed-line numbers (parallel running ends October 18th, 2013). -->
         <nationalNumberPattern>
-          (?:
-            11?\d|
+          11\d{7}|
+          1?(?:
             2[24-8]|
             3[35-8]|
             4[3-68]|
              until we find evidence that this is an error, leaving them at 10 for now. -->
         <nationalNumberPattern>
           (?:
-            5[013-689]|
-            811
-          )\d{7}
+            5(?:
+              [013-689]\d|
+              7[0-26-8]
+            )|
+            811\d
+          )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9,10}</possibleNumberPattern>
         <exampleNumber>512345678</exampleNumber>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>920012345</exampleNumber>
       </sharedCost>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          9(?:
-            11|
-            9[7-9]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Solomon Islands -->
-    <!-- http://www.itu.int/oth/T02020000BF/en -->
     <territory id="SB" countryCode="677" internationalPrefix="0[01]">
-      <!-- A single group is used to format 5-digit numbers. -->
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000BF/en</sourceUrl>
+      </references>
+      <!-- A single group is used to format 5-digit numbers. This formatting pattern follows
+           the guidelines in the ITU document. -->
       <availableFormats>
-        <numberFormat pattern="(\d{3})(\d{4})">
+        <numberFormat pattern="(\d{2})(\d{5})">
           <leadingDigits>[7-9]</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
           7(?:
             [46-8]\d|
             5[025-9]|
-            90
+            9[0-4]
           )\d{4}|
           8[4-8]\d{5}|
           9(?:
+            1[2-9]|
+            2[013-9]|
+            3[0-2]|
             [46]\d|
             5[0-46-9]|
             7[0-689]|
         <possibleNumberPattern>\d{5}</possibleNumberPattern>
         <exampleNumber>51123</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Seychelles -->
-    <!-- http://www.itu.int/oth/T02020000BA/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Seychelles -->
     <territory id="SC" countryCode="248" internationalPrefix="0[0-2]"
                preferredInternationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000BA/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Seychelles</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})">
           <leadingDigits>[89]</leadingDigits>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>6412345</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Sudan -->
-    <!-- http://www.itu.int/oth/T02020000C4/en -->
     <territory id="SD" countryCode="249" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000C4/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{4})">
           <format>$1 $2 $3</format>
         <nationalNumberPattern>9[012569]\d{7}</nationalNumberPattern>
         <exampleNumber>911231234</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Sweden -->
-    <!-- http://www.pts.se/upload/Ovrigt/Tele/Nummerfragor/Sv_nrplan_telefoni_enl_TU-T_rek_E.164.pdf -->
     <territory id="SE" countryCode="46" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.pts.se/upload/Ovrigt/Tele/Nummerfragor/Sv_nrplan_telefoni_enl_TU-T_rek_E.164.pdf</sourceUrl>
+        <sourceUrl>http://www.pts.se/upload/Ovrigt/Tele/Nummerfragor/Nrplansammanst%C3%A4llning-2013-07-05.pdf</sourceUrl>
+      </references>
       <availableFormats>
       <!-- Formatting patterns are from the numbering plan and from the Swedish yellow pages
            http://gulasidorna.eniro.se -->
           <format>$1-$2 $3 $4</format>
           <intlFormat>$1 $2 $3 $4</intlFormat>
         </numberFormat>
+        <numberFormat pattern="(77)(\d{2})(\d{2})">
+          <leadingDigits>7</leadingDigits>
+          <format>$1-$2$3</format>
+          <intlFormat>$1 $2 $3</intlFormat>
+        </numberFormat>
         <numberFormat pattern="(20)(\d{2,3})(\d{2})">
           <leadingDigits>20</leadingDigits>
           <format>$1-$2 $3</format>
           <format>$1-$2 $3 $4</format>
           <intlFormat>$1 $2 $3 $4</intlFormat>
         </numberFormat>
+        <numberFormat pattern="(9[034]\d)(\d{4})">
+          <leadingDigits>9[034]</leadingDigits>
+          <format>$1-$2</format>
+          <intlFormat>$1 $2</intlFormat>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[1-9]\d{6,9}</nationalNumberPattern>
+        <nationalNumberPattern>[1-9]\d{5,9}</nationalNumberPattern>
         <possibleNumberPattern>\d{5,10}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
             )\d{5,6}
           )|
           4(?:
-            [0246]\d{5,7}|
+            0[1-9]\d{4,6}|
+            [246]\d{5,7}|
             (?:
-              1[0-8]|
+              1[013-8]|
               3[0135]|
               5[14-79]|
               7[0-246-9]|
             9[01]
           )\d{5,6}|
           6(?:
-            [03]\d{5,7}|
+            0[1-9]\d{4,6}|
+            3\d{5,7}|
             (?:
               1[1-3]|
               2[0-4]|
               9[0-356]
             )\d{5,6}
           )|
-          8\d{6,8}|
+          8[1-9]\d{5,7}|
           9(?:
-            0\d{5,7}|
+            0[1-9]\d{4,6}|
             (?:
               1[0-68]|
               2\d|
-              3[02-59]|
-              [45][0-4]|
+              3[02-5]|
+              4[0-3]|
+              5[0-4]|
               [68][01]|
               7[0135-8]
             )\d{5,6}
         <exampleNumber>701234567</exampleNumber>
       </mobile>
       <pager>
-        <nationalNumberPattern>74\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>74[02-9]\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
-        <exampleNumber>741234567</exampleNumber>
+        <exampleNumber>740123456</exampleNumber>
       </pager>
       <tollFree>
-        <nationalNumberPattern>20\d{4,7}</nationalNumberPattern>
+        <nationalNumberPattern>
+          20(?:
+            0(?:
+              0\d{2}|
+              [1-9](?:
+                0\d{1,4}|
+                [1-9]\d{4}
+              )
+            )|
+            1(?:
+              0\d{4}|
+              [1-9]\d{4,5}
+            )|
+            [2-9]\d{5}
+          )
+        </nationalNumberPattern>
         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
-        <exampleNumber>201234567</exampleNumber>
+        <exampleNumber>20123456</exampleNumber>
       </tollFree>
       <premiumRate>
         <nationalNumberPattern>
             00|
             39|
             44
-          )\d{7}
+          )(?:
+            1(?:
+              [0-26]\d{5}|
+              [3-57-9]\d{2}
+            )|
+            2(?:
+              [0-2]\d{5}|
+              [3-9]\d{2}
+            )|
+            3(?:
+              [0139]\d{5}|
+              [24-8]\d{2}
+            )|
+            4(?:
+              [045]\d{5}|
+              [1-36-9]\d{2}
+            )|
+            5(?:
+              5\d{5}|
+              [0-46-9]\d{2}
+            )|
+            6(?:
+              [679]\d{5}|
+              [0-58]\d{2}
+            )|
+            7(?:
+              [078]\d{5}|
+              [1-69]\d{2}
+            )|
+            8(?:
+              [578]\d{5}|
+              [0-469]\d{2}
+            )
+          )
         </nationalNumberPattern>
-        <possibleNumberPattern>\d{10}</possibleNumberPattern>
+        <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
         <exampleNumber>9001234567</exampleNumber>
       </premiumRate>
       <sharedCost>
-        <nationalNumberPattern>77\d{7}</nationalNumberPattern>
-        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <nationalNumberPattern>
+          77(?:
+            0(?:
+              0\d{2}|
+              [1-9](?:
+                0\d|
+                [1-9]\d{4}
+              )
+            )|
+            [1-6][1-9]\d{5}
+          )
+        </nationalNumberPattern>
+        <possibleNumberPattern>\d{6}(?:\d{3})?</possibleNumberPattern>
         <exampleNumber>771234567</exampleNumber>
       </sharedCost>
       <personalNumber>
-        <nationalNumberPattern>75\d{7}</nationalNumberPattern>
+        <nationalNumberPattern>75[1-8]\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>751234567</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          90000
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3,5}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Singapore -->
-    <!-- http://www.ida.gov.sg/Policies-and-Regulations/Industry-and-Licensees/Numbering/National-Numbering-Plan-and-Allocation-Process.aspx -->
-    <territory id="SG" countryCode="65" internationalPrefix="0[0-3]\d">
+    <territory id="SG" countryCode="65" internationalPrefix="0[0-3]\d"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.ida.gov.sg/Policies-and-Regulations/Industry-and-Licensees/Numbering/National-Numbering-Plan-and-Allocation-Process.aspx</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([3689]\d{3})(\d{4})">
           <leadingDigits>
         <possibleNumberPattern>\d{11}</possibleNumberPattern>
         <exampleNumber>70001234567</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>99[359]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Saint Helena -->
-    <!-- http://www.itu.int/oth/T02020000AF/en -->
     <territory id="SH" countryCode="290" internationalPrefix="00" mainCountryForCode="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000AF/en</sourceUrl>
+      </references>
       <!-- Numbers are formatted as a block. -->
       <generalDesc>
         <nationalNumberPattern>[2-79]\d{3,4}</nationalNumberPattern>
         </nationalNumberPattern>
         <exampleNumber>5012</exampleNumber>
       </premiumRate>
-      <emergency>
-        <!-- http://www.sthelenatourism.com/pages/fast_facts.html#Emergencies -->
-        <nationalNumberPattern>
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Slovenia -->
-    <!-- http://www.itu.int/oth/T02020000BE/en -->
     <territory id="SI" countryCode="386" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000BE/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="($NP$FG)"
           pattern="(\d)(\d{3})(\d{2})(\d{2})">
         <numberFormat pattern="([3-7]\d)(\d{3})(\d{3})">
           <leadingDigits>
             [37][01]|
-            4[019]|
+            4[0139]|
             51|
             6
           </leadingDigits>
         <exampleNumber>11234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- We include 049 here - it is VoIP in the plan, but SMS messages have been successfully
-             delivered - and it is run by Mobitel. There are also mobile numbers found on the
-             internet with this prefix - it is apparently used in Kosovo. Also
-             added 068, which is used by the mobile operator bob.si -->
+        <!-- We include 043 and 049 here - it is VoIP in the plan, but is actually used to provide
+             mobile coverage to Kosovo. Also added 068, which is used by the mobile operator bob.si
+         -->
         <nationalNumberPattern>
           (?:
             [37][01]|
-            4[019]|
+            4[0139]|
             51|
             6[48]
           )\d{6}
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>59012345</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>11[23]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Svalbard -->
     <!-- Metadata shared with Norway. -->
-    <!-- http://www.npt.no/pt_internet/numsys/E.164.pdf -->
     <territory id="SJ" countryCode="47" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.npt.no/pt_internet/numsys/E.164.pdf</sourceUrl>
+      </references>
       <generalDesc>
         <nationalNumberPattern>
           0\d{4}|
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>81212345</exampleNumber>
       </voicemail>
-      <!-- Same as Norway, according to http://kho.unis.no/nordlysstasjon_useful.htm -->
-      <emergency>
-        <nationalNumberPattern>11[023]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Slovakia -->
-    <!-- http://www.itu.int/oth/T02020000BD/en -->
     <territory id="SK" countryCode="421" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000BD/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(2)(\d{3})(\d{3})(\d{2})">
           <leadingDigits>2</leadingDigits>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>961234567</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            5[058]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Sierra Leone -->
-    <!-- http://www.itu.int/oth/T02020000BB/en -->
     <territory id="SL" countryCode="232" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="($NP$FG)">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000BB/en</sourceUrl>
+      </references>
       <availableFormats>
-        <!-- Following formatting of online yellow pages www.leonedirect.com -->
+        <!-- Following formatting of online yellow pages http://www.leonedirect.com -->
         <numberFormat pattern="(\d{2})(\d{6})">
           <format>$1 $2</format>
         </numberFormat>
         </nationalNumberPattern>
         <exampleNumber>25123456</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>
-          (?:
-            01|
-            99
-          )9
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- San Marino -->
-    <!-- http://www.itu.int/oth/T02020000B5/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B39 (Information about Italy) -->
-    <!-- http://en.wikipedia.org/wiki/%2B378-->
     <!-- San Marino fixed-line numbers have an area code of "0549". However, this seems to be
          optional when dialling from outside the country; the phone number can be reached both with
          and without this area code. The nationalPrefixForParsing and nationalPrefixTransformRule
     <territory id="SM" countryCode="378" internationalPrefix="00"
                nationalPrefixForParsing="(?:0549)?([89]\d{5})" nationalPrefixTransformRule="0549$1"
                leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B5/en</sourceUrl>
+        <!-- Information about Italy. -->
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B39</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B378</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <leadingDigits>[5-7]</leadingDigits>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>58001110</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>11[358]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>113</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Senegal -->
-    <!-- http://www.itu.int/oth/T02020000B8/en -->
     <territory id="SN" countryCode="221" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B8/en</sourceUrl>
+        <sourceUrl>http://www.artpsenegal.net</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Using yellow pages and online telecom company formatting, rather than that implied in
              the national numbering plan. -->
         <numberFormat pattern="(\d{2})(\d{3})(\d{2})(\d{2})">
+          <leadingDigits>[379]</leadingDigits>
+          <format>$1 $2 $3 $4</format>
+        </numberFormat>
+        <numberFormat pattern="(\d{3})(\d{2})(\d{2})(\d{2})">
+          <leadingDigits>8</leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[37]\d{8}</nationalNumberPattern>
+        <nationalNumberPattern>[3789]\d{8}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
         <nationalNumberPattern>
           3(?:
             0(?:
-              1[01]|
+              1[0-2]|
               80
             )|
+            282|
             3(?:
               8[1-9]|
-              9[2-9]
-            )
+              9[3-9]
+            )|
+            611|
+            90[1-5]
           )\d{5}
         </nationalNumberPattern>
         <exampleNumber>301012345</exampleNumber>
       <mobile>
         <nationalNumberPattern>
           7(?:
-            0(?:
-              [01279]0|
-              3[03]|
-              4[05]|
-              5[06]|
-              6[03-5]|
-              8[029]
-            )|
-            6(?:
-              1[23]|
-              2[89]|
-              3[3489]|
-              4[6-9]|
-              5\d|
-              6[3-9]|
-              7[45]|
-              8[3-8]
-            )|
-            7\d{2}|
-            8(?:
-              01|
-              1[01]
-            )
-          )\d{5}
+            [067]\d|
+            21|
+            8[0-26]|
+            90
+          )\d{6}
         </nationalNumberPattern>
-        <exampleNumber>701012345</exampleNumber>
+        <exampleNumber>701234567</exampleNumber>
       </mobile>
+      <tollFree>
+        <nationalNumberPattern>800\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <exampleNumber>800123456</exampleNumber>
+      </tollFree>
+      <premiumRate>
+        <!-- Revenu Partagé in the plan. -->
+        <nationalNumberPattern>88[4689]\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <exampleNumber>884123456</exampleNumber>
+      </premiumRate>
+      <sharedCost>
+        <nationalNumberPattern>81[02468]\d{6}</nationalNumberPattern>
+        <possibleNumberPattern>\d{9}</possibleNumberPattern>
+        <exampleNumber>810123456</exampleNumber>
+      </sharedCost>
       <voip>
-        <nationalNumberPattern>33301\d{4}</nationalNumberPattern>
-        <exampleNumber>333011234</exampleNumber>
+        <!-- Also covers satellite telephony ranges. -->
+        <nationalNumberPattern>
+          3392\d{5}|
+          93330\d{4}
+        </nationalNumberPattern>
+        <exampleNumber>933301234</exampleNumber>
       </voip>
-      <!-- No emergency numbers information can be found. -->
     </territory>
 
     <!-- Somalia -->
-    <!-- http://www.itu.int/oth/T02020000C0/en -->
-    <!-- http://en.wikipedia.org/wiki/+252 -->
     <!-- This document seems to cover only a small set of prefixes in Somalia. Somalia has limited
          information available, and the numerous telecom carriers were previously working under an
          unregulated environment. The extra prefixes were added from the contact phone numbers of
          prefix of "0" is required when dialling from different regions (e.g. Puntland, Somaliland)
          for some operators, so that is included here although we do not use it when formatting. -->
     <territory id="SO" countryCode="252" internationalPrefix="00" nationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000C0/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+252</sourceUrl>
+      </references>
       <availableFormats>
-        <!-- These follow formats online, such as www.hortel.net/contact_us.html -->
+        <!-- These follow formats online, such as http://www.hortel.net/contact_us.html -->
         <numberFormat pattern="(\d)(\d{6})">
           <leadingDigits>
             2[0-79]|
           <leadingDigits>
             15|
             28|
-            6[178]|
-            9
+            6[1378]
           </leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
           <leadingDigits>69</leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
+        <numberFormat pattern="(90\d)(\d{3})(\d{3})">
+          <leadingDigits>90</leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
         <nationalNumberPattern>[1-79]\d{6,8}</nationalNumberPattern>
              here since that is apparently used for mobile. -->
         <nationalNumberPattern>
           (?:
-            [134]\d|
+            1\d|
             2[0-79]|
-            5[57-9]
+            3[0-46-8]|
+            4[0-7]|
+            59
           )\d{5}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
-        <!-- Example numbers are test numbers from the document. -->
-        <exampleNumber>5522010</exampleNumber>
+        <exampleNumber>4012345</exampleNumber>
       </fixedLine>
       <mobile>
         <!-- 24 is used by the carrier Telesom. 28 is used by Nationlink. 6[89] are apparently used
              by Nationlink Somalia, 67 by Nationlink Puntland, and 61 by Hormuud. 7X is used by
-             Somtel. 6 followed by only 7 digits is used by Telecom. We have received information
-             from Golis Telecom that 90 numbers are extended by 1 digit by becoming 907.
-             Note that the ITU update of Apr. 2013 suggests there is a longer 707 XXX XXX range
-             for mobile, but the document is not self consistent, so this is probably a typo. -->
+             Somtel. 6 followed by only 7 digits is used by Telecom. Note that in June 2014 many
+             ranges were suspended by the government. 90\d{6} was listed as one of the ranges to be
+             suspended, but open-source contributors confirm that 907\d{6} is still in use, even if
+             the shorter 90 ranges are no longer. -->
         <nationalNumberPattern>
           (?:
             15\d|
               4\d|
               8
             )|
-            6[17-9]?\d{2}|
-            7\d{2}|
-            9(?:
-              07|
-              [19]
-            )\d
+            6[137-9]?\d{2}|
+            7[1-9]\d|
+            907\d
           )\d{5}
         </nationalNumberPattern>
-        <exampleNumber>907792024</exampleNumber>
+        <exampleNumber>71123456</exampleNumber>
       </mobile>
-      <!-- According to the following webpage, there is no emergency number in Somalia:
-           http://www.netglobers.com/africa/somalia-emergency-numbers-in-somalia.html -->
     </territory>
 
     <!-- Suriname -->
-    <!-- http://www.itu.int/oth/T02020000C5/en -->
     <territory id="SR" countryCode="597" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000C5/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Following conventions used in the Suriname Yellow Pages. -->
         <numberFormat pattern="(\d{3})(\d{3})">
           <format>$1-$2-$3</format>
         </numberFormat>
         <numberFormat pattern="(\d{3})(\d{4})">
-          <leadingDigits>[6-8]</leadingDigits>
+          <leadingDigits>
+            59|
+            [6-8]
+          </leadingDigits>
           <format>$1-$2</format>
         </numberFormat>
       </availableFormats>
         <exampleNumber>211234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 74 from numbers found online. -->
         <nationalNumberPattern>
           (?:
-            7[1-57]|
+            7[124-7]|
             8[1-9]
           )\d{5}
         </nationalNumberPattern>
         <exampleNumber>7412345</exampleNumber>
       </mobile>
       <voip>
-        <nationalNumberPattern>56\d{4}</nationalNumberPattern>
-        <possibleNumberPattern>\d{6}</possibleNumberPattern>
+        <nationalNumberPattern>
+          5(?:
+            6\d{4}|
+            90[0-4]\d{3}
+          )
+        </nationalNumberPattern>
+        <possibleNumberPattern>\d{6,7}</possibleNumberPattern>
         <exampleNumber>561234</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>115</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>115</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- South Sudan -->
-    <!-- http://www.itu.int/oth/T02020000F9/en -->
-    <!-- http://en.wikipedia.org/wiki/+211 -->
     <territory id="SS" countryCode="211" internationalPrefix="00" nationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000F9/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+211</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})" nationalPrefixFormattingRule="$NP$FG">
           <format>$1 $2 $3</format>
     </territory>
 
     <!-- Sao Tome and Principe -->
-    <!-- http://www.itu.int/oth/T02020000B6/en -->
     <territory id="ST" countryCode="239" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B6/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1 $2</format>
         <nationalNumberPattern>9[89]\d{5}</nationalNumberPattern>
         <exampleNumber>9812345</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://www.netglobers.com/africa/s%C3%A3o-tome-and-principe-emergency-numbers-in-s%C3%A3o-tome-and-principe.html
-             -->
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1010.html -->
-        <!-- http://www.tipredaktion.net/consumer/lufthansa_en/tip-ST-1.html -->
-        <!-- Emergency numbers longer than 3 digits covered by fixed-line. -->
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- El Salvador -->
-    <!-- http://www.itu.int/oth/T020200003F/en -->
-    <!-- http://www.siget.gob.sv/BusquedaPublica.aspx?pagina=3&tipo=27&titulo=t8&sector=2&ordenar=&dir=DESC
-         -->
     <territory id="SV" countryCode="503" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200003F/en</sourceUrl>
+        <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>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <leadingDigits>[267]</leadingDigits>
         <possibleNumberPattern>\d{7}(?:\d{4})?</possibleNumberPattern>
         <exampleNumber>9001234</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Sint Maarten -->
-    <!-- http://www.nanpa.com/pdf/PL_429.pdf -->
-    <!-- http://www.itu.int/oth/T02020000F7/en -->
     <territory id="SX" countryCode="1" leadingDigits="721" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.nanpa.com/pdf/PL_429.pdf</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T02020000F7/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002123456</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://experiencestmartin.com/islandfacts/telephones.html -->
-        <nationalNumberPattern>919</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>919</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Syrian Arab Republic -->
-    <!-- http://www.itu.int/oth/T02020000C9/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B963 -->
     <territory id="SY" countryCode="963" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
                nationalPrefixOptionalWhenFormatting="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000C9/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B963</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{3,4})">
           <leadingDigits>[1-5]</leadingDigits>
         <possibleNumberPattern>\d{6,9}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
+      <!-- Numbers with the 21 prefix are made optionally 1-digit longer based on numbers found on
+           the Internet. -->
         <nationalNumberPattern>
           (?:
             1(?:
               4\d|
               [2356]
             )|
-            2[1-35]|
+            2(?:
+              1\d?|
+              [235]
+            )|
             3(?:
               [13]\d|
               4
         <exampleNumber>944567890</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <emergency>
-        <nationalNumberPattern>11[023]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Swaziland -->
-    <!-- http://www.itu.int/oth/T02020000C6/en -->
     <territory id="SZ" countryCode="268" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000C6/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <leadingDigits>[027]</leadingDigits>
         <nationalNumberPattern>0800\d{4}</nationalNumberPattern>
         <exampleNumber>08001234</exampleNumber>
       </tollFree>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1031.html -->
-        <!-- http://swaziland.usembassy.gov/information_for_travelers.html -->
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Tristan da Cunha -->
-    <!-- http://www.itu.int/oth/T02020000AF/en -->
     <territory id="TA" countryCode="290" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000AF/en</sourceUrl>
+      </references>
       <!-- Numbers are formatted as a block. Shares a country code with Saint Helena. -->
       <generalDesc>
         <nationalNumberPattern>8\d{3}</nationalNumberPattern>
     </territory>
 
     <!-- Turks and Caicos Islands -->
-    <!-- http://www.itu.int/oth/T02020000D8/en -->
     <territory id="TC" countryCode="1" leadingDigits="649" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D8/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5689]\d{9}</nationalNumberPattern>
               3[1-389]|
               4[1-7]
             )|
-            4[34][12]
+            4[34][1-3]
           )\d{4}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>6497101234</exampleNumber>
       </voip>
-      <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-      <!-- http://s2.turksandcaicosyp.com/Turks-Caicos/Government/2/book -->
-      <emergency>
-        <nationalNumberPattern>
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Chad -->
-    <!-- http://www.itu.int/oth/T0202000029/en -->
     <!-- The international prefix includes 16 as the international manual exchange. -->
     <territory id="TD" countryCode="235" preferredInternationalPrefix="00"
                internationalPrefix="00|16">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000029/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat
           pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
         </nationalNumberPattern>
         <exampleNumber>63012345</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>1[78]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>17</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- French Southern Territories -->
          temporary inhabitants. -->
 
     <!-- Togo -->
-    <!-- http://www.itu.int/oth/T02020000D1/en -->
     <territory id="TG" countryCode="228" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D1/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
         <exampleNumber>22212345</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>9[0-289]\d{6}</nationalNumberPattern>
+        <!-- Prefix 93 is from an open-source bug report -->
+        <nationalNumberPattern>9[0-389]\d{6}</nationalNumberPattern>
         <exampleNumber>90112345</exampleNumber>
       </mobile>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1041.html -->
-        <!-- http://www.netglobers.com/africa/togo-emergency-numbers-in-togo.html -->
-        <!-- http://www.mapsofworld.com/togo/information/emergency-numbers.html -->
-        <nationalNumberPattern>
-          1(?:
-            01|
-            1[78]|
-            7[17]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>117</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Thailand -->
-    <!-- http://www.itu.int/oth/T02020000CD/en -->
-    <!-- http://www.barascientific.com/bscnews/variety/emergency/Tel-4Digi.pdf -->
     <territory id="TH" countryCode="66" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000CD/en</sourceUrl>
+        <sourceUrl>http://www.barascientific.com/bscnews/variety/emergency/Tel-4Digi.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formatting patterns from wikipedia and the document itself -
              http://en.wikipedia.org/wiki/%2B66 -->
           <leadingDigits>2</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <numberFormat pattern="([3-9]\d)(\d{3})(\d{3,4})">
-          <leadingDigits>[3-9]</leadingDigits>
+        <numberFormat pattern="([13-9]\d)(\d{3})(\d{3,4})">
+          <leadingDigits>
+            14|
+            [3-9]
+          </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat nationalPrefixFormattingRule="$FG"
       <generalDesc>
         <nationalNumberPattern>
           [2-9]\d{7,8}|
-          1\d{3}(?:\d{6})?
+          1\d{3}(?:\d{5,6})?
         </nationalNumberPattern>
         <possibleNumberPattern>\d{4}|\d{8,10}</possibleNumberPattern>
       </generalDesc>
         <exampleNumber>1100</exampleNumber>
       </noInternationalDialling>
       <fixedLine>
+        <!-- Numbers online have been found that start with 20, despite the ITU doc not covering
+             these. -->
         <nationalNumberPattern>
           (?:
-            2[1-9]|
+            2\d|
             3[2-9]|
             4[2-5]|
             5[2-6]|
         <exampleNumber>21234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>[89]\d{8}</nationalNumberPattern>
+        <!-- Numbers found online starting with 62. 14 and 63 are from an open-source bug report,
+             we couldn't find evidence of these specifically being in use but this article
+             http://www.prachachat.net/news_detail.php?newsid=1395732787&grpid=03&catid=06&subcatid=0600
+             talks about prefix 6 and 1 being cleared for mobile use. -->
+        <nationalNumberPattern>
+          (?:
+            14|
+            6[1-3]|
+            [89]\d
+          )\d{7}
+        </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>812345678</exampleNumber>
       </mobile>
       </premiumRate>
       <voip>
         <!-- The ITU document says that the 89 prefix is also VOIP but there are lots of numbers
-             online to suggest they are actually used as mobile numbers -->
-        <nationalNumberPattern>60\d{7}</nationalNumberPattern>
+             online to suggest they are actually used as mobile numbers. -->
+        <nationalNumberPattern>6[08]\d{7}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>601234567</exampleNumber>
       </voip>
         <possibleNumberPattern>\d{4}</possibleNumberPattern>
         <exampleNumber>1100</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            669|
-            9[19]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3,4}</possibleNumberPattern>
-        <exampleNumber>191</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Tajikistan -->
-    <!-- http://www.itu.int/oth/T02020000CA/en -->
     <territory id="TJ" countryCode="992" preferredInternationalPrefix="8~10"
                internationalPrefix="810" nationalPrefix="8"
                nationalPrefixFormattingRule="($NP) $FG"
                nationalPrefixOptionalWhenFormatting="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000CA/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([349]\d{2})(\d{2})(\d{4})">
           <leadingDigits>
       </fixedLine>
       <mobile>
         <!-- Adding 90 prefix as SMS messages could be successfully delivered to these mobile
-             numbers, and 501 for TCell. -->
+             numbers, and 50[12] for TCell from bug reports. -->
         <nationalNumberPattern>
           (?:
-            50[15]|
+            50[125]|
             9[0-35-9]\d
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>917123456</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[1-3]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Tokelau -->
-    <!-- http://www.itu.int/oth/T02020000D2/en -->
     <territory id="TK" countryCode="690" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D2/en</sourceUrl>
+      </references>
       <generalDesc>
         <nationalNumberPattern>[2-9]\d{3}</nationalNumberPattern>
         <possibleNumberPattern>\d{4}</possibleNumberPattern>
         <nationalNumberPattern>[5-9]\d{3}</nationalNumberPattern>
         <exampleNumber>5190</exampleNumber>
       </mobile>
-      <!-- No evidence that any emergency numbers exist for this tiny island has been found. -->
     </territory>
 
     <!-- Timor-Leste (East Timor) -->
-    <!-- http://www.itu.int/oth/T02020000D0/en -->
     <territory id="TL" countryCode="670" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D0/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>[2-489]</leadingDigits>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>7012345</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>11[25]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Turkmenistan -->
-    <!-- http://www.itu.int/oth/T02020000D7/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Turkmenistan -->
     <territory id="TM" countryCode="993" preferredInternationalPrefix="8~10"
                internationalPrefix="810" nationalPrefix="8"
                nationalPrefixFormattingRule="($NP $FG)">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D7/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Turkmenistan</sourceUrl>
+      </references>
       <availableFormats>
         <!-- There doesn't seem to be a standardized format. The format below is based on the
              Turkmenistan embassy at
         <!-- According to feedback from users, the carrier Altyn Asyr is the only one currently
              operating, with the numbers 6[3-5]\d{6}. MTS used to operate the ranges 6[6-8] but this
              has been suspended. It is unclear whether it will resume. We support both ranges in the
-             meantime. -->
-        <nationalNumberPattern>6[3-8]\d{6}</nationalNumberPattern>
+             meantime. The range 62 seems also now to be in use, according to numbers found online.
+             -->
+        <nationalNumberPattern>6[2-8]\d{6}</nationalNumberPattern>
         <exampleNumber>66123456</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <emergency>
-        <!-- http://www.netglobers.com/asia/turkmenistan-emergency-numbers-in-turkmenistan.html
-             http://www.voyage.gc.ca/countries_pays/report_rapport-eng.asp?id=301000 -->
-        <nationalNumberPattern>0[1-3]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>03</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Tunisia -->
-    <!-- http://www.itu.int/oth/T02020000D5/en -->
     <territory id="TN" countryCode="216" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D5/en</sourceUrl>
+        <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>
+        <sourceUrl>http://www.tunisietelecom.tn/tt/internet/fr/pme/fixe/numeros_acceuil</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})(\d{3})">
           <format>$1 $2 $3</format>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
-        <!-- We support the whole 81 prefix here instead of just 81200 as
-             indicated in the ITU doc, as more real phone numbers have been
-             found online. -->
+        <!-- 3[012] numbers are no longer listed in the ITU doc, but we support them based on
+             online searches. -->
         <nationalNumberPattern>
-          (?:
-            3[012]|
-            7\d|
-            81
-          )\d{6}
+          3[012]\d{6}|
+          7\d{7}|
+          81200\d{3}
         </nationalNumberPattern>
         <exampleNumber>71234567</exampleNumber>
       </fixedLine>
       <mobile>
+        <!-- Numbers starting with 5 are no longer listed in the ITU doc, but we support them based
+             on online searches and Wikipedia. -->
         <nationalNumberPattern>
           (?:
             [259]\d|
-            4[0-2]
+            4[0-24]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>20123456</exampleNumber>
       </mobile>
-      <!-- These are listed as 'value added services' - pending further information, we add them
-           here for now. -->
+      <tollFree>
+        <!-- ITU lists 80 xx xx xx, but the document published by Tunisie Telecom has more specific
+             information which is followed here. -->
+        <nationalNumberPattern>8010\d{4}</nationalNumberPattern>
+        <exampleNumber>80101234</exampleNumber>
+      </tollFree>
       <premiumRate>
-        <nationalNumberPattern>8[028]\d{6}</nationalNumberPattern>
-        <exampleNumber>80123456</exampleNumber>
+        <nationalNumberPattern>88\d{6}</nationalNumberPattern>
+        <exampleNumber>88123456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>19[078]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>197</exampleNumber>
-      </emergency>
+      <sharedCost>
+        <!-- 8110xxxx numbers are listed as being "discounted non-geographical numbers" and are put
+             here for now. In the future we might consider them as UAN.
+             ITU lists 82 xx xx xx, but the document published by Tunisie Telecom has more specific
+             information which is followed here. -->
+        <nationalNumberPattern>8[12]10\d{4}</nationalNumberPattern>
+        <exampleNumber>81101234</exampleNumber>
+      </sharedCost>
     </territory>
 
     <!-- Tonga -->
-    <!-- http://www.itu.int/oth/T02020000D3/en -->
-    <!-- http://www.wtng.info/wtng-676-to.html -->
     <territory id="TO" countryCode="676" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D3/en</sourceUrl>
+        <sourceUrl>http://www.wtng.info/wtng-676-to.html</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{3})">
           <leadingDigits>
         <numberFormat pattern="(\d{3})(\d{4})">
           <leadingDigits>
             7[5-9]|
-            8[7-9]
+            8[47-9]
           </leadingDigits>
           <format>$1 $2</format>
         </numberFormat>
       </fixedLine>
       <mobile>
         <!-- TCC mobile numbers were given a prefix of "77" in 2009, although this is not mentioned
-             in their ITU document. Numbers with a prefix of "75" have also been found. -->
+             in their ITU document. Numbers with a prefix of "75" and "84" have also been found. -->
         <nationalNumberPattern>
           (?:
             7[578]|
-            8[7-9]
+            8[47-9]
           )\d{5}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>0800222</exampleNumber>
       </tollFree>
-      <emergency>
-        <!-- http://www.tongaholiday.com/?page_id=2034 -->
-        <nationalNumberPattern>
-          9(?:
-            11|
-            22|
-            33|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Turkey -->
-    <!-- http://en.wikipedia.org/wiki/%2B90 -->
-    <!-- http://www.itu.int/oth/T02020000D6/en -->
-    <territory id="TR" countryCode="90" internationalPrefix="00" nationalPrefix="0">
+    <territory id="TR" countryCode="90" internationalPrefix="00" nationalPrefix="0"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B90</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T02020000D6/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat nationalPrefixFormattingRule="($NP$FG)" pattern="(\d{3})(\d{3})(\d{4})"
           nationalPrefixOptionalWhenFormatting="true">
         <possibleNumberPattern>\d{7,10}</possibleNumberPattern>
         <exampleNumber>4441444</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            1[02]|
-            55
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Trinidad and Tobago -->
-    <!-- http://www.itu.int/oth/T02020000D4/en -->
     <territory id="TT" countryCode="1" leadingDigits="868" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D4/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[589]\d{9}</nationalNumberPattern>
         <nationalNumberPattern>
           868(?:
             2(?:
-              01|
+              [03]1|
               2[1-5]
             )|
             6(?:
-              07|
-              1[4-6]|
+              0[79]|
+              1[02-9]|
               2[1-9]|
-              [3-6]\d|
-              7[0-79]|
-              9[0-8]
+              [3-69]\d|
+              7[0-79]
             )|
-            82[12]
+            82[124]
           )\d{4}
         </nationalNumberPattern>
         <exampleNumber>8682211234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 48X & 70X from the IR21 published by TSTT. -->
         <nationalNumberPattern>
           868(?:
             2(?:
-              8[59]|
-              9\d
+              [89]\d
             )|
             3(?:
               0[1-9]|
               8\d
             )|
             7(?:
+              0[1-9]|
               1[02-9]|
-              [02-9]\d
+              [2-9]\d
             )
           )\d{4}
         </nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>99[09]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Tuvalu -->
-    <!-- http://www.itu.int/oth/T02020000D9/en -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Tuvalu -->
     <territory id="TV" countryCode="688" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000D9/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Tuvalu</sourceUrl>
+      </references>
       <!-- Numbers are formatted as a block. -->
       <generalDesc>
         <nationalNumberPattern>[29]\d{4,5}</nationalNumberPattern>
         <possibleNumberPattern>\d{6}</possibleNumberPattern>
         <exampleNumber>901234</exampleNumber>
       </mobile>
-      <emergency>
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Taiwan, China -->
-    <!-- http://www.itu.int/oth/T02020000EB/en -->
     <!-- Extension symbols found on the internet so far have been #, X and Ext - so # has been
          chosen as the preferred extension prefix. -->
     <territory id="TW" countryCode="886" internationalPrefix="0(?:0[25679]|19)"
-               nationalPrefix="0" preferredExtnPrefix="#" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" preferredExtnPrefix="#" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000EB/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([2-8])(\d{3,4})(\d{4})">
           <leadingDigits>
-            [2-7]|
-            8[1-9]
+            [2-6]|
+            [78][1-9]
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
           </leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
+        <numberFormat pattern="(70)(\d{4})(\d{4})">
+          <leadingDigits>70</leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
-        <nationalNumberPattern>[2-9]\d{7,8}</nationalNumberPattern>
-        <possibleNumberPattern>\d{8,9}</possibleNumberPattern>
+        <nationalNumberPattern>
+          [2-689]\d{7,8}|
+          7\d{7,9}
+        </nationalNumberPattern>
+        <possibleNumberPattern>\d{8,10}</possibleNumberPattern>
       </generalDesc>
       <fixedLine>
         <nationalNumberPattern>[2-8]\d{7,8}</nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>900123456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>11[029]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>110</exampleNumber>
-      </emergency>
+      <!-- http://www.chief.com.tw/telecom_eng/front/bin/ptlist.phtml?Category=107 -->
+      <voip>
+        <nationalNumberPattern>70\d{8}</nationalNumberPattern>
+        <possibleNumberPattern>\d{10}</possibleNumberPattern>
+        <exampleNumber>7012345678</exampleNumber>
+      </voip>
     </territory>
 
     <!-- Tanzania -->
-    <!-- http://www.itu.int/oth/T02020000CB/en -->
     <territory id="TZ" countryCode="255" internationalPrefix="00[056]"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000CB/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([24]\d)(\d{3})(\d{4})">
           <leadingDigits>[24]</leadingDigits>
           <leadingDigits>[67]</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
-        <!-- Formatting for special numbers from www.tcra.go.tz -->
+        <!-- Formatting for special numbers from http://www.tcra.go.tz -->
         <numberFormat pattern="([89]\d{2})(\d{2})(\d{4})">
           <leadingDigits>[89]</leadingDigits>
           <format>$1 $2 $3</format>
       <mobile>
         <nationalNumberPattern>
           (?:
-            6[158]|
+            6[1578]|
             7[1-9]
           )\d{7}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>412345678</exampleNumber>
       </voip>
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1038.html
-             http://in2eastafrica.net/emergency-numbers-in-tanzania -->
-        <nationalNumberPattern>
-          11[12]|
-          999
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>111</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Ukraine -->
-    <!-- http://www.itu.int/oth/T02020000DB/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B380 -->
     <territory id="UA" countryCode="380" preferredInternationalPrefix="0~0"
                internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000DB/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B380</sourceUrl>
+      </references>
       <availableFormats>
         <!-- City codes separated out. No definitive list has been found of what constitutes the
              area code - http://www.ua.all-biz.info/guide/phonecodes is useful but not error-free.
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>891234567</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            0[123]|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Uganda -->
-    <!-- http://www.itu.int/oth/T02020000F1/en -->
-    <!-- http://www.ucc.co.ug/licensing/ugandaNumberingPlan.pdf -->
     <territory id="UG" countryCode="256" internationalPrefix="00[057]"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000F1/en</sourceUrl>
+        <sourceUrl>http://www.ucc.co.ug/licensing/ugandaNumberingPlan.pdf</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{6})">
           <leadingDigits>
             )|
             3[23]\d|
             5[0-4]\d|
-            60\d|
+            6[03]\d|
             8[0-2]\d
           )\d{4}|
           [34]\d{8}
       <mobile>
         <!-- Added 79[5-9] and 707 from online numbers found with this prefix. -->
         <!-- Ranges with prefixes 7[46] are "not yet operational" as of Jun. 2013. -->
+        <!-- Ranges with prefixes 2030 or 723 are "not yet operational" as of Oct. 2014. -->
         <nationalNumberPattern>
+          2030\d{5}|
           7(?:
             0[0-7]|
             [15789]\d|
-            [23]0|
+            2[03]|
+            30|
             [46][0-4]
           )\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>901123456</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>999</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- United States -->
-    <!-- http://www.nanpa.com/reports/reports_npa.html -->
-    <!-- http://en.wikipedia.org/wiki/North_American_Numbering_Plan -->
     <!-- Note the national prefix of US is the same as its country code, and when formatting phone
          numbers in the national format, it is not included. Therefore, we omit it here to make
          formatting consistent with the rest of the world. The same applies to all the
          when formatting, but is set here so that users who are calling formatByPattern can specify
          NationalPrefixFormattingRule if they want to. -->
     <territory id="US" countryCode="1" internationalPrefix="011" mainCountryForCode="true"
-               nationalPrefix="1" nationalPrefixOptionalWhenFormatting="true">
+               nationalPrefix="1" nationalPrefixOptionalWhenFormatting="true"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.nanpa.com/reports/reports_npa.html</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/North_American_Numbering_Plan</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
           <format>$1-$2</format>
               4[08]|
               5[1-46]|
               6[0279]|
-              7[06]|
+              7[026]|
               8[13]
             )|
             3(?:
               1[02-9]|
               2[0135]|
               3[014679]|
-              47|
+              4[67]|
               5[12]|
-              6[01]|
-              8[056]
+              6[014]|
+              8[56]
             )|
             4(?:
               0[124-9]|
             7(?:
               0[1-46-8]|
               1[02-9]|
-              2[047]|
-              3[124]|
+              2[0457]|
+              3[1247]|
               4[07]|
               5[47]|
               6[02359]|
               0[1346-9]|
               1[02-9]|
               2[0589]|
-              3[1678]|
+              3[01678]|
               4[0179]|
-              5[1246]|
+              5[12469]|
               7[0-3589]|
               8[0459]
             )
               4[08]|
               5[1-46]|
               6[0279]|
-              7[06]|
+              7[026]|
               8[13]
             )|
             3(?:
               1[02-9]|
               2[0135]|
               3[014679]|
-              47|
+              4[67]|
               5[12]|
-              6[01]|
-              8[056]
+              6[014]|
+              8[56]
             )|
             4(?:
               0[124-9]|
             7(?:
               0[1-46-8]|
               1[02-9]|
-              2[047]|
-              3[124]|
+              2[0457]|
+              3[1247]|
               4[07]|
               5[47]|
               6[02359]|
               0[1346-9]|
               1[02-9]|
               2[0589]|
-              3[1678]|
+              3[01678]|
               4[0179]|
-              5[1246]|
+              5[12469]|
               7[0-3589]|
               8[0459]
             )
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <nationalNumberPattern>
-          112|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Uruguay -->
-    <!-- http://www.itu.int/oth/T02020000E0/en -->
-    <!-- http://www.ursec.gub.uy -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Uruguay -->
     <!-- International long-distance providers can be dialled by dialling 01 followed by a carrier
          code JK, where J = [3-9] and K is any digit. -->
     <territory id="UY" countryCode="598" internationalPrefix="0(?:1[3-9]\d|0)"
                preferredInternationalPrefix="00" nationalPrefix="0" preferredExtnPrefix=" int. ">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E0/en</sourceUrl>
+        <sourceUrl>http://www.ursec.gub.uy</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Uruguay</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Following paginasamarillas.com.uy formatting. -->
         <numberFormat pattern="(\d{4})(\d{4})">
         <exampleNumber>21231234</exampleNumber>
       </fixedLine>
       <mobile>
-        <nationalNumberPattern>9[13-9]\d{6}</nationalNumberPattern>
+        <nationalNumberPattern>9[1-9]\d{6}</nationalNumberPattern>
         <possibleNumberPattern>\d{8}</possibleNumberPattern>
         <exampleNumber>94231234</exampleNumber>
       </mobile>
         <possibleNumberPattern>\d{7}</possibleNumberPattern>
         <exampleNumber>9001234</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>
-          128|
-          911
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
      </territory>
 
     <!-- Uzbekistan -->
-    <!-- http://www.ttts.uz/eng/telephone_codes/codes_uzb_eng -->
-    <!-- http://www.itu.int/oth/T02020000E1/en -->
     <territory id="UZ" countryCode="998" preferredInternationalPrefix="8~10"
                internationalPrefix="810" nationalPrefix="8"
                nationalPrefixFormattingRule="$NP $FG">
+      <references>
+        <sourceUrl>http://www.ttts.uz/eng/telephone_codes/codes_uzb_eng</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T02020000E1/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([679]\d)(\d{3})(\d{2})(\d{2})">
           <format>$1 $2 $3 $4</format>
                 7[079]
               )
             )|
-            9(
+            9(?:
               2(?:
                 1[1267]|
                 5\d|
         <exampleNumber>912345678</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <emergency>
-        <!-- http://travel.state.gov/travel/cis_pa_tw/cis/cis_1057.html
-             http://www.expat.uz/index.php?/Emergency-Numbers.html
-             http://www.mts.uz/en/citycodes/how_to_call_sos
-             Note that the third source, for a local mobile company, comments that a '*' needs to
-             be dialled before the 2-digit emergency numbers on their cell-phone. This is not
-             explicitly handled here, but instead is handled by normalising input in the code. -->
-        <nationalNumberPattern>
-          0(?:
-            0[123]|
-            [123]|
-            50
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>01</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Vatican City -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_Vatican_City -->
     <!-- Note that numbers here are also accessible via Italy (+39 and prefix of 06 698) but can
          also be dialled with the Vatican City country code. -->
     <territory id="VA" countryCode="379" internationalPrefix="00" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_Vatican_City</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(06)(\d{4})(\d{4})">
           <format>$1 $2 $3</format>
       <mobile>
         <!-- We have no information on mobile numbers from the Vatican. It is probable that they use
              Italian mobile contracts. -->
-        <nationalNumberPattern>N/A</nationalNumberPattern>
-        <possibleNumberPattern>N/A</possibleNumberPattern>
+        <nationalNumberPattern>NA</nationalNumberPattern>
+        <possibleNumberPattern>NA</possibleNumberPattern>
       </mobile>
       <!-- No information exists about other types of numbers. -->
-      <emergency>
-        <nationalNumberPattern>11[2358]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>113</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Saint Vincent and the Grenadines -->
-    <!-- http://www.itu.int/oth/T02020000B3/en -->
     <territory id="VC" countryCode="1" leadingDigits="784" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B3/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[5789]\d{9}</nationalNumberPattern>
         <possibleNumberPattern>\d{7}(?:\d{3})?</possibleNumberPattern>
       </generalDesc>
+      <!-- For 570, 571 and 572 prefixes, we believe the ITU doc incorrectly listed them to be under
+           area code 758, which should be 784. -->
       <fixedLine>
         <nationalNumberPattern>
           784(?:
             4(?:
               38|
               5[0-36-8]|
-              8\d|
-              9[01]
+              8[0-8]
+            )|
+            5(?:
+              55|
+              7[0-2]|
+              93
             )|
-            555|
             638|
             784
           )\d{4}
         <exampleNumber>7842661234</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding 784 433 and 784 534 since online numbers can be found with these prefixes, and
-             the latter seems, according to some online sources, to be assigned to Digicell. -->
         <nationalNumberPattern>
           784(?:
             4(?:
               3[0-4]|
               5[45]|
-              9[2-5]
+              89|
+              9[0-5]
             )|
             5(?:
               2[6-9]|
-              3[0-4]|
-              93
+              3[0-4]
             )
           )\d{4}
         </nationalNumberPattern>
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://barbados.usembassy.gov/emergency-svg.html
-             http://travel.state.gov/travel/cis_pa_tw/cis/cis_1028.html?action=/travel/cis_pa_tw/cis/cis_1100.html -->
-        <nationalNumberPattern>
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Venezuela -->
-    <!-- http://www.itu.int/oth/T02020000E3/en -->
-    <!-- http://en.wikipedia.org/wiki/+58 -->
-    <!-- 1XX specifies a particular carrier to route a call to. -->
+    <!-- 1XX specifies a particular carrier to route a call to, but none of these have been
+         implemented. -->
     <territory id="VE" countryCode="58" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixForParsing="(1\d{2})|0"
-               nationalPrefixFormattingRule="$NP$FG"
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
                carrierCodeFormattingRule="$CC $FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E3/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/+58</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{7})">
           <format>$1-$2</format>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>9001234567</exampleNumber>
       </premiumRate>
-      <emergency>
-        <nationalNumberPattern>171</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>171</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Virgin Islands, British -->
-    <!-- http://www.itu.int/oth/T020200001E/en -->
     <territory id="VG" countryCode="1" leadingDigits="284" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T020200001E/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[2589]\d{9}</nationalNumberPattern>
       </generalDesc>
       <fixedLine>
         <!-- No data on central office codes can be found on the nanpa.com website. The codes 422
-             and 774 have been added from numbers found in the white pages.  -->
+             and 774 have been added from numbers found in the white pages. -->
         <nationalNumberPattern>
           284(?:
             (?:
       </fixedLine>
       <mobile>
         <!-- No data on central office codes can be found on the nanpa.com website. The codes
-             34[0-367], 446 and 54[57] have been added from numbers found in the white pages.  -->
+             34[0-367], 446 and 54[57] have been added from numbers found in the white pages. -->
         <nationalNumberPattern>
           284(?:
             (?:
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://barbados.usembassy.gov/emergency-bvi.html
-             http://www.britishvirginislands.com/ntk_emergency.htm -->
-        <nationalNumberPattern>
-          9(?:
-            11|
-            99
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Virgin Islands, United States -->
-    <!-- http://www.itu.int/oth/T02020000DF/en -->
     <territory id="VI" countryCode="1" leadingDigits="340" nationalPrefix="1"
                internationalPrefix="011">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000DF/en</sourceUrl>
+      </references>
       <generalDesc>
         <!-- NANPA country - uses US formatting rules -->
         <nationalNumberPattern>[3589]\d{9}</nationalNumberPattern>
       <fixedLine>
         <!-- The ITU document seems a bit out-of-date so extra prefixes based on numbers in the
              yellow pages have been added, and the list of exchanges found on
-             http://www.areacodedownload.com/340/index.html -->
+             http://www.allareacodes.com/340 -->
         <nationalNumberPattern>
           340(?:
             2(?:
               01|
-              2[067]|
-              36|
+              2[0678]|
               44|
               77
             )|
               44
             )|
             4(?:
-              4[38]|
+              22|
               7[34]
             )|
             5(?:
             6(?:
               26|
               4[23]|
+              77|
               9[023]
             )|
             7(?:
-              [17]\d|
-              27
+              1[2-589]|
+              27|
+              7\d
             )|
             884|
             998
           340(?:
             2(?:
               01|
-              2[067]|
-              36|
+              2[0678]|
               44|
               77
             )|
               44
             )|
             4(?:
-              4[38]|
+              22|
               7[34]
             )|
             5(?:
             6(?:
               26|
               4[23]|
+              77|
               9[023]
             )|
             7(?:
-              [17]\d|
-              27
+              1[2-589]|
+              27|
+              7\d
             )|
             884|
             998
         <nationalNumberPattern>
           8(?:
             00|
+            44|
             55|
             66|
             77|
         <exampleNumber>9002345678</exampleNumber>
       </premiumRate>
       <personalNumber>
-        <!-- http://www.nanpa.com/pdf/PL_416.pdf -->
+        <!-- http://www.nanpa.com/pdf/PL_466.pdf -->
         <nationalNumberPattern>
           5(?:
             00|
             33|
-            44
+            44|
+            66|
+            77
           )[2-9]\d{6}
         </nationalNumberPattern>
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>5002345678</exampleNumber>
       </personalNumber>
-      <emergency>
-        <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-        <nationalNumberPattern>911</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>911</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Viet Nam (Vietnam) -->
-    <!-- http://www.itu.int/oth/T02020000E4/en -->
-    <!-- http://en.wikipedia.org/wiki/%2B84 -->
     <territory id="VN" countryCode="84" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
                nationalPrefixOptionalWhenFormatting="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E4/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/%2B84</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([17]99)(\d{4})">
           <leadingDigits>[17]99</leadingDigits>
         <possibleNumberPattern>\d{7,8}</possibleNumberPattern>
         <exampleNumber>1992000</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>11[345]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>113</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Vanuatu -->
-    <!-- http://www.itu.int/oth/T02020000E2/en -->
     <territory id="VU" countryCode="678" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E2/en</sourceUrl>
+      </references>
       <!-- Should be formatted in one block, apart from the mobile numbers. -->
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{4})">
       <fixedLine>
         <nationalNumberPattern>
           (?:
-            2[2-9]\d|
+            2[02-9]\d|
             3(?:
               [5-7]\d|
               8[0-8]
         <possibleNumberPattern>\d{5,7}</possibleNumberPattern>
         <exampleNumber>30123</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>112</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>112</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Wallis and Futuna (Territoire français d'outre-mer) -->
-    <!-- http://www.itu.int/oth/T02020000E6/en -->
     <territory id="WF" countryCode="681" internationalPrefix="00">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E6/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{2})(\d{2})">
           <format>$1 $2 $3</format>
         </nationalNumberPattern>
         <exampleNumber>501234</exampleNumber>
       </mobile>
-      <!-- http://lannuaire.service-public.fr/navigation/wallis-et-futuna-wallis-futuna-alofi.html
-           -->
-      <emergency>
-        <nationalNumberPattern>1[578]</nationalNumberPattern>
-        <possibleNumberPattern>\d{2}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Samoa -->
-    <!-- http://www.itu.int/oth/T02020000B4/en -->
     <territory id="WS" countryCode="685" internationalPrefix="0">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000B4/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Should be formatted in one block, apart from the specific series below. -->
         <numberFormat pattern="(8\d{2})(\d{3,4})">
         <exampleNumber>800123</exampleNumber>
       </tollFree>
       <!-- Current research suggests other types of numbers are not used in Samoa. -->
-      <emergency>
-        <!-- http://www.blueskysamoa.ws/?page_id=509 -->
-        <nationalNumberPattern>99[4-6]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>994</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Yemen -->
-    <!-- http://www.itu.int/oth/T02020000E7/en -->
     <territory id="YE" countryCode="967" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E7/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([1-7])(\d{3})(\d{3,4})">
           <leadingDigits>
         <exampleNumber>712345678</exampleNumber>
       </mobile>
       <!-- No tollFree or premiumRate information can be found. -->
-      <emergency>
-        <!-- http://www.yemenypages.com/en/emergency_numbers.aspx -->
-        <!-- http://studentsabroad.state.gov/content/pdfs/911_ABROAD.pdf -->
-        <!-- http://www.netglobers.com/asia/yemen-emergency-numbers-in-yemen.html -->
-        <nationalNumberPattern>19[1459]</nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>191</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Mayotte -->
-    <!-- Some information at http://en.wikipedia.org/wiki/Telephone_numbers_in_France - most from
-         collection of internet data. http://www.comores-online.com/mwezinet/internet/262.htm
-         verifies the fixed-line prefixes, but the mobile prefixes listed here seem out of date.
-         -->
     <territory id="YT" countryCode="262" internationalPrefix="00" nationalPrefix="0"
                nationalPrefixFormattingRule="$NP$FG" leadingDigits="269|63">
+      <references>
+        <!-- Some information at the following source, but most from collection of internet data.
+             -->
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_France</sourceUrl>
+        <!-- Verifies the fixed-line prefixes, but the mobile prefixes listed here seem out of date.
+             -->
+        <sourceUrl>http://www.comores-online.com/mwezinet/internet/262</sourceUrl>
+      </references>
       <!-- Formatting as per La Réunion. -->
       <generalDesc>
         <nationalNumberPattern>[268]\d{8}</nationalNumberPattern>
         <nationalNumberPattern>80\d{7}</nationalNumberPattern>
         <exampleNumber>801234567</exampleNumber>
       </tollFree>
-      <!-- http://www.sfr-mayotte.com/la-carte/les-services-@/article.jspz?oid=679&categ=345 -->
-      <!-- http://www.sccfd.org/travel.html -->
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            12|
-            5
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{2,3}</possibleNumberPattern>
-        <exampleNumber>15</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- South Africa -->
-    <!-- http://www.itu.int/dms_pub/itu-t/oth/02/02/T02020000C10001PDFE.pdf -->
-    <!-- http://en.wikipedia.org/wiki/Telephone_numbers_in_South_Africa -->
     <territory id="ZA" countryCode="27" internationalPrefix="00"
-               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+               nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG"
+               mobileNumberPortableRegion="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000C1/en</sourceUrl>
+        <sourceUrl>http://en.wikipedia.org/wiki/Telephone_numbers_in_South_Africa</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(860)(\d{3})(\d{3})">
           <leadingDigits>860</leadingDigits>
         <possibleNumberPattern>\d{9}</possibleNumberPattern>
         <exampleNumber>861123456</exampleNumber>
       </uan>
-      <emergency>
-        <nationalNumberPattern>
-          1(?:
-            01(?:
-              11|
-              77
-            )|
-            12
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3,5}</possibleNumberPattern>
-        <exampleNumber>10111</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Zambia -->
-    <!-- http://www.itu.int/oth/T02020000E8/en -->
     <territory id="ZM" countryCode="260" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E8/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="([29]\d)(\d{7})">
           <leadingDigits>[29]</leadingDigits>
         <exampleNumber>211234567</exampleNumber>
       </fixedLine>
       <mobile>
-        <!-- Adding extra prefixes 50, 6[1-57-9] and 7[13-6] since SMS messages have been
-             successfully delivered to these numbers, and numbers like this can be found on the
-             Internet. Adding prefix 960 based on information received from MTN Zambia. -->
+        <!-- Adding extra prefixes 50 and 6[1-57-9] since SMS messages have been successfully
+             delivered to these numbers, and numbers like this can be found on the Internet. Adding
+             prefix 960 based on information received from MTN Zambia. The 97 range has been
+             expanded based on their IR21 document, which states the range 97[1-9] is used. -->
         <nationalNumberPattern>
           9(?:
             5[05]|
             6\d|
-            7[13-9]
+            7[1-9]
           )\d{6}
         </nationalNumberPattern>
         <exampleNumber>955123456</exampleNumber>
         <nationalNumberPattern>800\d{6}</nationalNumberPattern>
         <exampleNumber>800123456</exampleNumber>
       </tollFree>
-      <emergency>
-        <nationalNumberPattern>
-          (?:
-            112|
-            99[139]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Zimbabwe -->
-    <!-- http://www.itu.int/oth/T02020000E9/en -->
     <territory id="ZW" countryCode="263" internationalPrefix="00"
                nationalPrefix="0" nationalPrefixFormattingRule="$NP$FG">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E9/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- One-digit area codes -->
         <numberFormat pattern="([49])(\d{3})(\d{2,5})">
         <possibleNumberPattern>\d{10}</possibleNumberPattern>
         <exampleNumber>8686123456</exampleNumber>
       </voip>
-      <emergency>
-        <nationalNumberPattern>
-          (?:
-            112|
-            99[3459]
-          )
-        </nationalNumberPattern>
-        <possibleNumberPattern>\d{3}</possibleNumberPattern>
-        <exampleNumber>999</exampleNumber>
-      </emergency>
     </territory>
 
     <!-- Universal International Toll Free Number -->
-    <!-- http://www.itu.int/en/ITU-T/inr/unum/Pages/uifn.aspx -->
     <territory id="001" countryCode="800" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/en/ITU-T/inr/unum/Pages/uifn.aspx</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <format>$1 $2</format>
     </territory>
 
     <!-- Universal International Shared Cost Number -->
-    <!-- http://www.itu.int/rec/T-REC-E.169-200205-I/en -->
     <territory id="001" countryCode="808" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/rec/T-REC-E.169-200205-I/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{4})(\d{4})">
           <format>$1 $2</format>
     </territory>
 
     <!-- Inmarsat Global Limited -->
-    <!-- http://www.itu.int/oth/T0202000065/en -->
-    <!-- www.inmarsat.com -->
     <territory id="001" countryCode="870">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T0202000065/en</sourceUrl>
+        <sourceUrl>http://www.inmarsat.com</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
           <format>$1 $2 $3</format>
     </territory>
 
     <!-- VISIONng -->
-    <!-- http://www.itu.int/oth/T02020000E5/en -->
     <!-- Number length has been derived from examples found online. -->
     <territory id="001" countryCode="878">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000E5/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formatting chosen based on online examples. -->
         <numberFormat pattern="(\d{2})(\d{5})(\d{5})">
     </territory>
 
     <!-- Iridium -->
-    <!-- www.iridium.com -->
-    <!-- http://www.itu.int/oth/T0202000069/en -->
     <!-- Globalstar also reports using this prefix, but we cannot find any online numbers with the
          Globalstar prefixes, so are not sure how exactly these work, and what length the numbers
          are. For this reason, we only support Iridium numbers at the moment. -->
     <territory id="001" countryCode="881">
+      <references>
+        <sourceUrl>http://www.iridium.com</sourceUrl>
+        <sourceUrl>http://www.itu.int/oth/T0202000069/en</sourceUrl>
+      </references>
       <availableFormats>
         <!-- Formatting chosen based on ITU document and Iridium website FAQ. -->
         <numberFormat pattern="(\d)(\d{3})(\d{5})">
       </mobile>
     </territory>
 
-    <!-- BebbiCell (Formerly Global Networks Switzerland AG) +88234 -->
-    <!-- http://www.itu.int/oth/T0202000054/en -->
-    <!-- http://www.gsm.aq/numberplan.php -->
-    <!-- http://www.global.aq -->
-    <!-- Maritime Communications Partner (MCP) +88232 -->
-    <!-- http://www.itu.int/oth/T02020000F4/en -->
-    <!-- Oration Technologies +88237 -->
-    <!-- http://www.itu.int/oth/T02020000A0/en -->
-    <!-- Telespazio S.p.A. +88213 -->
-    <!-- http://www.itu.int/oth/T02020000CC/en -->
-    <!-- Thuraya +88216 -->
-    <!-- http://www.itu.int/oth/T02020000CF/en -->
     <territory id="001" countryCode="882">
+      <references>
+        <!-- BebbiCell (Formerly Global Networks Switzerland AG) +88234 -->
+        <sourceUrl>http://www.itu.int/oth/T0202000054/en</sourceUrl>
+        <sourceUrl>http://www.gsm.aq/numberplan.php</sourceUrl>
+        <sourceUrl>http://www.global.aq</sourceUrl>
+        <!-- Maritime Communications Partner (MCP) +88232 -->
+        <sourceUrl>http://www.itu.int/oth/T02020000F4/en</sourceUrl>
+        <!-- Oration Technologies +88237 -->
+        <sourceUrl>http://www.itu.int/oth/T02020000A0/en</sourceUrl>
+        <!-- Telespazio S.p.A. +88213 -->
+        <sourceUrl>http://www.itu.int/oth/T02020000CC/en</sourceUrl>
+        <!-- Thuraya +88216 -->
+        <sourceUrl>http://www.itu.int/oth/T02020000CF/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{2})(\d{4})(\d{3})">
           <leadingDigits>3[23]</leadingDigits>
       </voicemail>
     </territory>
 
-    <!-- http://www.itu.int/oth/T02020000F3/en -->
-    <!-- http://www.republicwireless.com/world-wi-fi-number -->
     <territory id="001" countryCode="883">
+      <references>
+        <!-- bandwidth.com -->
+        <sourceUrl>http://www.itu.int/oth/T02020000FB/en</sourceUrl>
+        <!-- SipMe -->
+        <sourceUrl>http://www.itu.int/oth/T02020000FC/en</sourceUrl>
+        <!-- Voxbone -->
+        <sourceUrl>http://www.itu.int/oth/T02020000F3/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})">
+          <leadingDigits>510</leadingDigits>
           <format>$1 $2 $3</format>
         </numberFormat>
         <numberFormat pattern="(\d{3})(\d{3})(\d{3})(\d{3})">
+          <leadingDigits>510</leadingDigits>
           <format>$1 $2 $3 $4</format>
         </numberFormat>
+        <!-- When only 8 digits follow the "area code" formatting as XXXX XXXX
+             seems preferred (see Bandwidth.com and SipMe). -->
+        <numberFormat pattern="(\d{4})(\d{4})(\d{4})">
+          <leadingDigits>51[13]</leadingDigits>
+          <format>$1 $2 $3</format>
+        </numberFormat>
       </availableFormats>
       <generalDesc>
         <!-- Wikipedia also listed a few other +883 ranges, but no information on their lengths and
         <nationalNumberPattern>
           51(?:
             00\d{5}(?:\d{3})?|
-            10\d{8}
+            [13]0\d{8}
           )
         </nationalNumberPattern>
       </voip>
     </territory>
 
     <!-- United Nations- OCHA -->
-    <!-- http://www.itu.int/oth/T02020000FA/en -->
     <!-- Numbers here are classified as UAN, as they are non-geographical and universally
          accessible. In addition, the end-user tariff to reach these numbers is lower or similar to
          the tariff of a national call. -->
     <territory id="001" countryCode="888" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/oth/T02020000FA/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d{3})(\d{3})(\d{5})">
           <format>$1 $2 $3</format>
     </territory>
 
     <!-- Universal International Premium Rate Number -->
-    <!-- http://www.itu.int/rec/T-REC-E.169-200205-I/en -->
     <territory id="001" countryCode="979" leadingZeroPossible="true">
+      <references>
+        <sourceUrl>http://www.itu.int/rec/T-REC-E.169-200205-I/en</sourceUrl>
+      </references>
       <availableFormats>
         <numberFormat pattern="(\d)(\d{4})(\d{4})">
           <format>$1 $2 $3</format>