From 541996c2f12f88963676d540c1a669213c916a5d Mon Sep 17 00:00:00 2001 From: Joshua Gigg Date: Mon, 4 Nov 2024 10:39:35 +0000 Subject: [PATCH] Upstream metadata changes from Google for v8.13.49 - Updated phone metadata for region code(s): CO, EE, MG, MQ, MV, PM, SG, TJ - Updated short number metadata for region code(s): MQ, PM --- METADATA-VERSION.php | 2 +- src/data/PhoneNumberMetadata_CO.php | 30 +++++++++++++++++++++++++++-- src/data/PhoneNumberMetadata_EE.php | 2 +- src/data/PhoneNumberMetadata_MG.php | 2 +- src/data/PhoneNumberMetadata_MQ.php | 13 ++++++------- src/data/PhoneNumberMetadata_MV.php | 2 +- src/data/PhoneNumberMetadata_PM.php | 13 ++++++------- src/data/PhoneNumberMetadata_SG.php | 2 +- src/data/PhoneNumberMetadata_TJ.php | 2 +- src/data/ShortNumberMetadata_MQ.php | 25 +++++++++++++++++++----- src/data/ShortNumberMetadata_PM.php | 16 ++++++++++----- 11 files changed, 77 insertions(+), 32 deletions(-) diff --git a/METADATA-VERSION.php b/METADATA-VERSION.php index f1d1bb04..81f02f14 100644 --- a/METADATA-VERSION.php +++ b/METADATA-VERSION.php @@ -5,4 +5,4 @@ * For more information, look at the phing tasks in build.xml * @internal */ -return 'v8.13.48'; +return 'v8.13.49'; diff --git a/src/data/PhoneNumberMetadata_CO.php b/src/data/PhoneNumberMetadata_CO.php index 4b8de98e..dd46554c 100644 --- a/src/data/PhoneNumberMetadata_CO.php +++ b/src/data/PhoneNumberMetadata_CO.php @@ -10,22 +10,26 @@ 'id' => 'CO', 'countryCode' => 57, 'generalDesc' => [ - 'pattern' => '60\\d{8}|(?:1\\d|[39])\\d{9}', + 'pattern' => '(?:46|60\\d\\d)\\d{6}|(?:1\\d|[39])\\d{9}', 'posLength' => [ + 8, 10, 11, ], 'posLengthLocal' => [ + 4, 7, ], ], 'fixedLine' => [ - 'pattern' => '601055(?:[0-4]\\d|50)\\d\\d|6010(?:[0-4]\\d|5[0-4])\\d{4}|60(?:[124-7][2-9]|8[1-9])\\d{6}', + 'pattern' => '601055(?:[0-4]\\d|50)\\d\\d|6010(?:[0-4]\\d|5[0-4])\\d{4}|(?:46|60(?:[124-7][2-9]|8[1-9]))\\d{6}', 'example' => '6012345678', 'posLength' => [ + 8, 10, ], 'posLengthLocal' => [ + 4, 7, ], ], @@ -46,6 +50,10 @@ 'premiumRate' => [ 'pattern' => '(?:19(?:0[01]|4[78])|901)\\d{7}', 'example' => '19001234567', + 'posLength' => [ + 10, + 11, + ], ], 'sharedCost' => [ 'posLength' => [ @@ -86,6 +94,15 @@ 'nationalPrefix' => '0', 'nationalPrefixForParsing' => '0([3579]|4(?:[14]4|56))?', 'numberFormat' => [ + [ + 'pattern' => '(\\d{4})(\\d{4})', + 'format' => '$1 $2', + 'leadingDigitsPatterns' => [ + '46', + ], + 'nationalPrefixFormattingRule' => '', + 'domesticCarrierCodeFormattingRule' => '', + ], [ 'pattern' => '(\\d{3})(\\d{7})', 'format' => '$1 $2', @@ -115,6 +132,15 @@ ], ], 'intlNumberFormat' => [ + [ + 'pattern' => '(\\d{4})(\\d{4})', + 'format' => '$1 $2', + 'leadingDigitsPatterns' => [ + '46', + ], + 'nationalPrefixFormattingRule' => '', + 'domesticCarrierCodeFormattingRule' => '', + ], [ 'pattern' => '(\\d{3})(\\d{7})', 'format' => '$1 $2', diff --git a/src/data/PhoneNumberMetadata_EE.php b/src/data/PhoneNumberMetadata_EE.php index 1db49caf..725595d2 100644 --- a/src/data/PhoneNumberMetadata_EE.php +++ b/src/data/PhoneNumberMetadata_EE.php @@ -25,7 +25,7 @@ ], ], 'mobile' => [ - 'pattern' => '(?:5\\d{5}|8(?:1(?:0(?:0(?:00|[178]\\d)|[3-9]\\d\\d)|(?:1(?:0[236]|1\\d)|(?:2[0-59]|[3-79]\\d)\\d)\\d)|2(?:0(?:0(?:00|4\\d)|(?:19|[2-7]\\d)\\d)|(?:(?:[124-6]\\d|3[5-9])\\d|7(?:[0-79]\\d|8[13-9])|8(?:[2-6]\\d|7[01]))\\d)|[349]\\d{4}))\\d\\d|5(?:(?:[02]\\d|5[0-478])\\d|1(?:[0-8]\\d|95)|6(?:4[0-4]|5[1-589]))\\d{3}', + 'pattern' => '(?:5\\d{5}|8(?:1(?:0(?:0(?:00|[178]\\d)|[3-9]\\d\\d)|(?:1(?:0[2-6]|1\\d)|(?:2[0-59]|[3-79]\\d)\\d)\\d)|2(?:0(?:0(?:00|4\\d)|(?:19|[2-7]\\d)\\d)|(?:(?:[124-69]\\d|3[5-9])\\d|7(?:[0-79]\\d|8[13-9])|8(?:[2-6]\\d|7[01]))\\d)|[349]\\d{4}))\\d\\d|5(?:(?:[02]\\d|5[0-478])\\d|1(?:[0-8]\\d|95)|6(?:4[0-4]|5[1-589]))\\d{3}', 'example' => '51234567', 'posLength' => [ 7, diff --git a/src/data/PhoneNumberMetadata_MG.php b/src/data/PhoneNumberMetadata_MG.php index 5bb7d082..19636ecf 100644 --- a/src/data/PhoneNumberMetadata_MG.php +++ b/src/data/PhoneNumberMetadata_MG.php @@ -19,7 +19,7 @@ ], ], 'fixedLine' => [ - 'pattern' => '2072[29]\\d{4}|20(?:2\\d|4[47]|5[3467]|6[279]|7[356]|8[268]|9[245])\\d{5}', + 'pattern' => '2072[29]\\d{4}|20(?:2\\d|4[47]|5[3467]|6[279]|7[356]|8[268]|9[2457])\\d{5}', 'example' => '202123456', 'posLengthLocal' => [ 7, diff --git a/src/data/PhoneNumberMetadata_MQ.php b/src/data/PhoneNumberMetadata_MQ.php index e5ca6e1c..06de411e 100644 --- a/src/data/PhoneNumberMetadata_MQ.php +++ b/src/data/PhoneNumberMetadata_MQ.php @@ -10,17 +10,17 @@ 'id' => 'MQ', 'countryCode' => 596, 'generalDesc' => [ - 'pattern' => '596\\d{6}|(?:69|80|9\\d)\\d{7}', + 'pattern' => '596\\d{6}|(?:69|[89]\\d)\\d{7}', 'posLength' => [ 9, ], ], 'fixedLine' => [ - 'pattern' => '596(?:[03-7]\\d|1[05]|2[7-9]|8[0-39]|9[04-9])\\d{4}', + 'pattern' => '(?:596(?:[03-7]\\d|1[05]|2[7-9]|8[0-39]|9[04-9])|80[6-9]\\d\\d|9(?:477[6-9]|767[4589]))\\d{4}', 'example' => '596301234', ], 'mobile' => [ - 'pattern' => '69(?:6(?:[0-46-9]\\d|5[0-6])|727)\\d{4}', + 'pattern' => '69[67]\\d{6}', 'example' => '696201234', ], 'tollFree' => [ @@ -28,9 +28,8 @@ 'example' => '800012345', ], 'premiumRate' => [ - 'posLength' => [ - -1, - ], + 'pattern' => '8[129]\\d{7}', + 'example' => '810123456', ], 'sharedCost' => [ 'posLength' => [ @@ -74,7 +73,7 @@ 'pattern' => '(\\d{3})(\\d{2})(\\d{2})(\\d{2})', 'format' => '$1 $2 $3 $4', 'leadingDigitsPatterns' => [ - '[569]', + '[569]|8(?:0[6-9]|[36])', ], 'nationalPrefixFormattingRule' => '0$1', 'domesticCarrierCodeFormattingRule' => '', diff --git a/src/data/PhoneNumberMetadata_MV.php b/src/data/PhoneNumberMetadata_MV.php index 39c416b5..86783a24 100644 --- a/src/data/PhoneNumberMetadata_MV.php +++ b/src/data/PhoneNumberMetadata_MV.php @@ -17,7 +17,7 @@ ], ], 'fixedLine' => [ - 'pattern' => '(?:3(?:0[0-3]|3[0-59])|6(?:[58][024689]|6[024-68]|7[02468]))\\d{4}', + 'pattern' => '(?:3(?:0[0-4]|3[0-59])|6(?:[58][024689]|6[024-68]|7[02468]))\\d{4}', 'example' => '6701234', 'posLength' => [ 7, diff --git a/src/data/PhoneNumberMetadata_PM.php b/src/data/PhoneNumberMetadata_PM.php index 95833d28..c672f355 100644 --- a/src/data/PhoneNumberMetadata_PM.php +++ b/src/data/PhoneNumberMetadata_PM.php @@ -10,21 +10,18 @@ 'id' => 'PM', 'countryCode' => 508, 'generalDesc' => [ - 'pattern' => '[45]\\d{5}|(?:708|80\\d)\\d{6}', + 'pattern' => '[45]\\d{5}|(?:708|8\\d\\d)\\d{6}', 'posLength' => [ 6, 9, ], ], 'fixedLine' => [ - 'pattern' => '(?:4[1-35-7]|5[01])\\d{4}', + 'pattern' => '(?:4[1-35-9]|5[0-47-9]|80[6-9]\\d\\d)\\d{4}', 'example' => '430123', - 'posLength' => [ - 6, - ], ], 'mobile' => [ - 'pattern' => '(?:4[02-4]|5[056]|708[45][0-5])\\d{4}', + 'pattern' => '(?:4[02-489]|5[02-9]|708[45][0-5])\\d{4}', 'example' => '551234', ], 'tollFree' => [ @@ -35,8 +32,10 @@ ], ], 'premiumRate' => [ + 'pattern' => '8[129]\\d{7}', + 'example' => '810123456', 'posLength' => [ - -1, + 9, ], ], 'sharedCost' => [ diff --git a/src/data/PhoneNumberMetadata_SG.php b/src/data/PhoneNumberMetadata_SG.php index 323ee668..f72b9e05 100644 --- a/src/data/PhoneNumberMetadata_SG.php +++ b/src/data/PhoneNumberMetadata_SG.php @@ -25,7 +25,7 @@ ], ], 'mobile' => [ - 'pattern' => '(?:8(?:0(?:[1-8]\\d|9[0-689])|[1-8]\\d\\d|9(?:[0-4]\\d|5[0-3]|6[0-2]))|9[0-8]\\d\\d)\\d{4}', + 'pattern' => '8(?:09[0-689]|96[0-2])\\d{4}|(?:8(?:0[1-8]|[1-8]\\d|9[0-5])|9[0-8]\\d)\\d{5}', 'example' => '81234567', 'posLength' => [ 8, diff --git a/src/data/PhoneNumberMetadata_TJ.php b/src/data/PhoneNumberMetadata_TJ.php index 3d3f99bf..5a48ff38 100644 --- a/src/data/PhoneNumberMetadata_TJ.php +++ b/src/data/PhoneNumberMetadata_TJ.php @@ -32,7 +32,7 @@ ], ], 'mobile' => [ - 'pattern' => '(?:33[03-9]|4(?:1[18]|4[02-479])|81[1-9])\\d{6}|(?:[09]\\d|1[017]|2[02]|[34]0|5[05]|7[01578]|8[078])\\d{7}', + 'pattern' => '(?:33[03-9]|4(?:1[18]|4[02-479])|81[1-9])\\d{6}|(?:[09]\\d|1[0178]|2[02]|[34]0|5[05]|7[01578]|8[078])\\d{7}', 'example' => '917123456', ], 'tollFree' => [ diff --git a/src/data/ShortNumberMetadata_MQ.php b/src/data/ShortNumberMetadata_MQ.php index d38ebb4d..a029083c 100644 --- a/src/data/ShortNumberMetadata_MQ.php +++ b/src/data/ShortNumberMetadata_MQ.php @@ -10,32 +10,47 @@ 'id' => 'MQ', 'countryCode' => 0, 'generalDesc' => [ - 'pattern' => '1\\d\\d?', + 'pattern' => '[13]\\d(?:\\d(?:\\d(?:\\d{2})?)?)?', 'posLength' => [ 2, 3, + 4, + 6, ], ], 'tollFree' => [ - 'pattern' => '1(?:12|[578])', + 'pattern' => '1(?:12|[578])|3[01]\\d\\d', 'example' => '15', + 'posLength' => [ + 2, + 3, + 4, + ], ], 'premiumRate' => [ + 'pattern' => '3[2469]\\d\\d', + 'example' => '3200', 'posLength' => [ - -1, + 4, ], ], 'emergency' => [ 'pattern' => '1(?:12|[578])', 'example' => '15', + 'posLength' => [ + 2, + 3, + ], ], 'shortCode' => [ - 'pattern' => '1(?:12|[578])', + 'pattern' => '1(?:12|[578])|(?:118[02-9]|3[0-2469])\\d\\d', 'example' => '15', ], 'standardRate' => [ + 'pattern' => '118\\d{3}', + 'example' => '118000', 'posLength' => [ - -1, + 6, ], ], 'carrierSpecific' => [ diff --git a/src/data/ShortNumberMetadata_PM.php b/src/data/ShortNumberMetadata_PM.php index e24d1ce0..78635e24 100644 --- a/src/data/ShortNumberMetadata_PM.php +++ b/src/data/ShortNumberMetadata_PM.php @@ -10,22 +10,26 @@ 'id' => 'PM', 'countryCode' => 0, 'generalDesc' => [ - 'pattern' => '[13]\\d(?:\\d{2})?', + 'pattern' => '[13]\\d(?:\\d\\d(?:\\d{2})?)?', 'posLength' => [ 2, 4, + 6, ], ], 'tollFree' => [ - 'pattern' => '1[578]', + 'pattern' => '1[578]|3(?:0\\d|1[689])\\d', 'example' => '15', 'posLength' => [ 2, + 4, ], ], 'premiumRate' => [ + 'pattern' => '3[2469]\\d\\d', + 'example' => '3200', 'posLength' => [ - -1, + 4, ], ], 'emergency' => [ @@ -36,12 +40,14 @@ ], ], 'shortCode' => [ - 'pattern' => '1[578]|3103', + 'pattern' => '1[578]|31(?:03|[689]\\d)|(?:118[02-9]|3[02469])\\d\\d', 'example' => '15', ], 'standardRate' => [ + 'pattern' => '118\\d{3}', + 'example' => '118000', 'posLength' => [ - -1, + 6, ], ], 'carrierSpecific' => [