Home
last modified time | relevance | path

Searched refs:RegionCode (Results 1 – 9 of 9) sorted by relevance

/external/libphonenumber/java/test/com/android/i18n/phonenumbers/
DShortNumberUtilTest.java34 assertTrue(shortUtil.connectsToEmergencyNumber("911", RegionCode.US)); in testConnectsToEmergencyNumber_US()
35 assertTrue(shortUtil.connectsToEmergencyNumber("112", RegionCode.US)); in testConnectsToEmergencyNumber_US()
36 assertFalse(shortUtil.connectsToEmergencyNumber("999", RegionCode.US)); in testConnectsToEmergencyNumber_US()
40 assertTrue(shortUtil.connectsToEmergencyNumber("9116666666", RegionCode.US)); in testConnectsToEmergencyNumberLongNumber_US()
41 assertTrue(shortUtil.connectsToEmergencyNumber("1126666666", RegionCode.US)); in testConnectsToEmergencyNumberLongNumber_US()
42 assertFalse(shortUtil.connectsToEmergencyNumber("9996666666", RegionCode.US)); in testConnectsToEmergencyNumberLongNumber_US()
46 assertTrue(shortUtil.connectsToEmergencyNumber("9-1-1", RegionCode.US)); in testConnectsToEmergencyNumberWithFormatting_US()
47 assertTrue(shortUtil.connectsToEmergencyNumber("1-1-2", RegionCode.US)); in testConnectsToEmergencyNumberWithFormatting_US()
48 assertFalse(shortUtil.connectsToEmergencyNumber("9-9-9", RegionCode.US)); in testConnectsToEmergencyNumberWithFormatting_US()
52 assertFalse(shortUtil.connectsToEmergencyNumber("+911", RegionCode.US)); in testConnectsToEmergencyNumberWithPlusSign_US()
[all …]
DShortNumberInfoTest.java37 assertTrue(shortInfo.isPossibleShortNumberForRegion("123456", RegionCode.FR)); in testIsPossibleShortNumber()
42 assertFalse(shortInfo.isPossibleShortNumberForRegion("9", RegionCode.FR)); in testIsPossibleShortNumber()
53 assertTrue(shortInfo.isValidShortNumberForRegion("1010", RegionCode.FR)); in testIsValidShortNumber()
56 assertFalse(shortInfo.isValidShortNumberForRegion("123456", RegionCode.FR)); in testIsValidShortNumber()
65 RegionCode.FR, ShortNumberInfo.ShortNumberCost.PREMIUM_RATE); in testGetExpectedCost()
67 shortInfo.getExpectedCostForRegion(premiumRateExample, RegionCode.FR)); in testGetExpectedCost()
74 RegionCode.FR, ShortNumberInfo.ShortNumberCost.STANDARD_RATE); in testGetExpectedCost()
76 shortInfo.getExpectedCostForRegion(standardRateExample, RegionCode.FR)); in testGetExpectedCost()
83 RegionCode.FR, ShortNumberInfo.ShortNumberCost.TOLL_FREE); in testGetExpectedCost()
85 shortInfo.getExpectedCostForRegion(tollFreeExample, RegionCode.FR)); in testGetExpectedCost()
[all …]
DPhoneNumberMatcherTest.java83 doTestFindInContext("033316005", RegionCode.NZ); in testFindNationalNumber()
87 doTestFindInContext("03-331 6005", RegionCode.NZ); in testFindNationalNumber()
88 doTestFindInContext("03 331 6005", RegionCode.NZ); in testFindNationalNumber()
91 doTestFindInContext("0064 3 331 6005", RegionCode.NZ); in testFindNationalNumber()
94 doTestFindInContext("01164 3 331 6005", RegionCode.US); in testFindNationalNumber()
95 doTestFindInContext("+64 3 331 6005", RegionCode.US); in testFindNationalNumber()
97 doTestFindInContext("64(0)64123456", RegionCode.NZ); in testFindNationalNumber()
100 doTestFindInContext("0123/456789", RegionCode.PL); in testFindNationalNumber()
101 doTestFindInContext("123-456-7890", RegionCode.US); in testFindNationalNumber()
106 doTestFindInContext("+1 (650) 333-6000", RegionCode.NZ); in testFindWithInternationalPrefixes()
[all …]
DPhoneNumberUtilTest.java145 PhoneMetadata metadata = phoneUtil.getMetadataForRegion(RegionCode.US); in testGetInstanceLoadUSMetadata()
166 PhoneMetadata metadata = phoneUtil.getMetadataForRegion(RegionCode.DE); in testGetInstanceLoadDEMetadata()
186 PhoneMetadata metadata = phoneUtil.getMetadataForRegion(RegionCode.AR); in testGetInstanceLoadARMetadata()
297 RegionCode.MX))); in testGetCountryMobileToken()
301 RegionCode.SE))); in testGetCountryMobileToken()
317 assertEquals(DE_NUMBER, phoneUtil.getExampleNumber(RegionCode.DE)); in testGetExampleNumber()
320 phoneUtil.getExampleNumberForType(RegionCode.DE, in testGetExampleNumber()
323 phoneUtil.getExampleNumberForType(RegionCode.DE, in testGetExampleNumber()
327 assertNotNull(phoneUtil.getExampleNumberForType(RegionCode.US, in testGetExampleNumber()
329 assertNotNull(phoneUtil.getExampleNumberForType(RegionCode.US, in testGetExampleNumber()
[all …]
DAsYouTypeFormatterTest.java30 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.ZZ); in testInvalidRegion()
52 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.ZZ); in testInvalidPlusSign()
72 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.ZZ); in testTooLongNumberMatchingMultipleLeadingDigits()
92 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.BY); in testCountryWithSpaceInNationalPrefixFormattingRule()
107 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.BY); in testCountryWithSpaceInNationalPrefixFormattingRuleAndLongNdd()
121 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.US); in testAYTFUS()
215 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.US); in testAYTFUSFullWidthCharacters()
229 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.US); in testAYTFUSMobileShortCode()
238 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.US); in testAYTFUSVanityNumber()
254 AsYouTypeFormatter formatter = phoneUtil.getAsYouTypeFormatter(RegionCode.US); in testAYTFAndRememberPositionUS()
[all …]
DRegionCode.java22 final class RegionCode { class
/external/chromium_org/content/renderer/android/
Dphone_number_detector.cc21 using i18n::phonenumbers::RegionCode;
33 : region_code_(RegionCode::GetUnknown()) { in PhoneNumberDetector()
38 : region_code_(region.empty() ? RegionCode::GetUnknown() in PhoneNumberDetector()
/external/chromium_org/third_party/libphonenumber/src/phonenumbers/
Dregion_code.h25 class RegionCode {
Dphonenumberutil.cc687 if (region_code == RegionCode::GetUnknown()) { in PhoneNumberUtil()
1625 region_codes.front() : RegionCode::GetUnknown(); in GetRegionCodeForCountryCode()
1640 *region_code = RegionCode::GetUnknown(); in GetRegionCodeForNumber()
1675 *region_code = RegionCode::GetUnknown(); in GetRegionCodeForNumberFromRegionList()
1740 RegionCode::ZZ(), number); in GetExampleNumberForNonGeoEntity()
2488 if (region_code != RegionCode::GetUnknown()) { in ExtractCountryCode()
2657 Parse(first_number, RegionCode::GetUnknown(), &first_number_as_proto); in IsNumberMatchWithTwoStrings()
2663 ErrorType error_type = Parse(second_number, RegionCode::GetUnknown(), in IsNumberMatchWithTwoStrings()
2669 error_type = ParseHelper(first_number, RegionCode::GetUnknown(), false, in IsNumberMatchWithTwoStrings()
2672 error_type = ParseHelper(second_number, RegionCode::GetUnknown(), false, in IsNumberMatchWithTwoStrings()
[all …]