/external/cronet/third_party/icu/source/common/unicode/ |
D | locid.h | 195 class U_COMMON_API Locale : public UObject { 198 static const Locale &U_EXPORT2 getRoot(void); 200 static const Locale &U_EXPORT2 getEnglish(void); 202 static const Locale &U_EXPORT2 getFrench(void); 204 static const Locale &U_EXPORT2 getGerman(void); 206 static const Locale &U_EXPORT2 getItalian(void); 208 static const Locale &U_EXPORT2 getJapanese(void); 210 static const Locale &U_EXPORT2 getKorean(void); 212 static const Locale &U_EXPORT2 getChinese(void); 214 static const Locale &U_EXPORT2 getSimplifiedChinese(void); [all …]
|
D | localematcher.h | 226 inline const Locale *getDesiredLocale() const { return desiredLocale; } in getDesiredLocale() 237 inline const Locale *getSupportedLocale() const { return supportedLocale; } in getSupportedLocale() 272 Locale makeResolvedLocale(UErrorCode &errorCode) const; 275 Result(const Locale *desired, const Locale *supported, in Result() 284 const Locale *desiredLocale; 285 const Locale *supportedLocale; 356 Builder &setSupportedLocales(Locale::Iterator &locales); 414 Builder &addSupportedLocale(const Locale &locale); 436 Builder &setDefaultLocale(const Locale *defaultLocale); 496 Builder &setMaxDistance(const Locale &desired, const Locale &supported); [all …]
|
/external/icu/icu4c/source/common/unicode/ |
D | locid.h | 195 class U_COMMON_API Locale : public UObject { 198 static const Locale &U_EXPORT2 getRoot(void); 200 static const Locale &U_EXPORT2 getEnglish(void); 202 static const Locale &U_EXPORT2 getFrench(void); 204 static const Locale &U_EXPORT2 getGerman(void); 206 static const Locale &U_EXPORT2 getItalian(void); 208 static const Locale &U_EXPORT2 getJapanese(void); 210 static const Locale &U_EXPORT2 getKorean(void); 212 static const Locale &U_EXPORT2 getChinese(void); 214 static const Locale &U_EXPORT2 getSimplifiedChinese(void); [all …]
|
D | localematcher.h | 226 inline const Locale *getDesiredLocale() const { return desiredLocale; } in getDesiredLocale() 237 inline const Locale *getSupportedLocale() const { return supportedLocale; } in getSupportedLocale() 272 Locale makeResolvedLocale(UErrorCode &errorCode) const; 275 Result(const Locale *desired, const Locale *supported, in Result() 284 const Locale *desiredLocale; 285 const Locale *supportedLocale; 356 Builder &setSupportedLocales(Locale::Iterator &locales); 414 Builder &addSupportedLocale(const Locale &locale); 436 Builder &setDefaultLocale(const Locale *defaultLocale); 496 Builder &setMaxDistance(const Locale &desired, const Locale &supported); [all …]
|
/external/icu/libicu/cts_headers/unicode/ |
D | locid.h | 195 class U_COMMON_API Locale : public UObject { 198 static const Locale &U_EXPORT2 getRoot(void); 200 static const Locale &U_EXPORT2 getEnglish(void); 202 static const Locale &U_EXPORT2 getFrench(void); 204 static const Locale &U_EXPORT2 getGerman(void); 206 static const Locale &U_EXPORT2 getItalian(void); 208 static const Locale &U_EXPORT2 getJapanese(void); 210 static const Locale &U_EXPORT2 getKorean(void); 212 static const Locale &U_EXPORT2 getChinese(void); 214 static const Locale &U_EXPORT2 getSimplifiedChinese(void); [all …]
|
D | localematcher.h | 226 inline const Locale *getDesiredLocale() const { return desiredLocale; } in getDesiredLocale() 237 inline const Locale *getSupportedLocale() const { return supportedLocale; } in getSupportedLocale() 272 Locale makeResolvedLocale(UErrorCode &errorCode) const; 275 Result(const Locale *desired, const Locale *supported, in Result() 284 const Locale *desiredLocale; 285 const Locale *supportedLocale; 356 Builder &setSupportedLocales(Locale::Iterator &locales); 414 Builder &addSupportedLocale(const Locale &locale); 436 Builder &setDefaultLocale(const Locale *defaultLocale); 496 Builder &setMaxDistance(const Locale &desired, const Locale &supported); [all …]
|
/external/libtextclassifier/native/utils/i18n/ |
D | locale_test.cc | 25 Locale locale = Locale::Invalid(); in TEST() 30 Locale locale = Locale::FromBCP47("en-CH"); in TEST() 38 Locale locale = Locale::FromBCP47("zh-CN"); in TEST() 46 Locale locale = Locale::FromBCP47("zh-Hant-TW"); in TEST() 54 Locale locale = Locale::FromBCP47("en"); in TEST() 62 Locale locale = Locale::FromBCP47("zh-Hant"); in TEST() 70 std::vector<Locale> locales = {Locale::FromBCP47("zh-HK"), in TEST() 71 Locale::FromBCP47("en-UK")}; in TEST() 72 std::vector<Locale> supported_locales = {Locale::FromBCP47("en")}; in TEST() 74 EXPECT_TRUE(Locale::IsAnyLocaleSupported(locales, supported_locales, in TEST() [all …]
|
D | locale.cc | 82 Locale Locale::FromBCP47(const std::string& locale_tag) { in FromBCP47() 85 return Locale::Invalid(); in FromBCP47() 91 return Locale::Invalid(); in FromBCP47() 117 return Locale(language.ToString(), script.ToString(), region.ToString()); in FromBCP47() 120 Locale Locale::FromLanguageTag(const LanguageTag* language_tag) { in FromLanguageTag() 122 return Locale::Invalid(); in FromLanguageTag() 127 return Locale::Invalid(); in FromLanguageTag() 145 return Locale(language.ToString(), script.ToString(), region.ToString()); in FromLanguageTag() 148 bool Locale::IsUnknown() const { in IsUnknown() 152 bool Locale::IsLocaleSupported(const Locale& locale, in IsLocaleSupported() [all …]
|
D | locale.h | 30 class Locale { 34 static Locale FromBCP47(const std::string& locale_tag); 37 static Locale FromLanguageTag(const LanguageTag* language_tag); 40 static Locale Invalid() { in Invalid() 41 Locale locale(/*language=*/"", /*script=*/"", /*region=*/""); in Invalid() 59 static bool IsAnyLocaleSupported(const std::vector<Locale>& locales, 60 const std::vector<Locale>& supported_locales, 63 bool operator==(const Locale& locale) const; 64 bool operator!=(const Locale& locale) const; 65 bool operator<(const Locale& locale) const; [all …]
|
/external/libchrome/base/android/javatests/src/org/chromium/base/ |
D | LocaleUtilsTest.java | 19 import java.util.Locale; 56 Locale locale = new Locale("jp"); in testGetUpdatedLocaleForChromium() 57 Locale updatedLocale = LocaleUtils.getUpdatedLocaleForChromium(locale); in testGetUpdatedLocaleForChromium() 60 locale = new Locale("iw"); in testGetUpdatedLocaleForChromium() 62 Assert.assertEquals(new Locale("he"), updatedLocale); in testGetUpdatedLocaleForChromium() 64 locale = new Locale("ji"); in testGetUpdatedLocaleForChromium() 66 Assert.assertEquals(new Locale("yi"), updatedLocale); in testGetUpdatedLocaleForChromium() 68 locale = new Locale("in"); in testGetUpdatedLocaleForChromium() 70 Assert.assertEquals(new Locale("id"), updatedLocale); in testGetUpdatedLocaleForChromium() 72 locale = new Locale("tl"); in testGetUpdatedLocaleForChromium() [all …]
|
/external/apache-commons-lang/src/test/java/org/apache/commons/lang3/time/ |
D | FastDateParserSDFTest.java | 28 import java.util.Locale; 47 …Arguments.of("z yyyy", "GMT 2010", Locale.UK, true), // no offset specified, but this is all… in data() 48 Arguments.of("z yyyy", "GMT-123 2010", Locale.UK, false), in data() 49 Arguments.of("z yyyy", "GMT-1234 2010", Locale.UK, false), in data() 50 Arguments.of("z yyyy", "GMT-12:34 2010", Locale.UK, true), in data() 51 Arguments.of("z yyyy", "GMT-1:23 2010", Locale.UK, true), in data() 53 Arguments.of("z yyyy", "-1234 2010", Locale.UK, true), in data() 54 Arguments.of("z yyyy", "-12:34 2010", Locale.UK, false), in data() 55 Arguments.of("z yyyy", "-123 2010", Locale.UK, false), in data() 57 Arguments.of( "MM/dd/yyyy", "01/11/12", Locale.UK, true), in data() [all …]
|
/external/cronet/base/android/javatests/src/org/chromium/base/ |
D | LocaleUtilsTest.java | 21 import java.util.Locale; 58 Locale locale = new Locale("jp"); in testGetUpdatedLocaleForChromium() 59 Locale updatedLocale = LocaleUtils.getUpdatedLocaleForChromium(locale); in testGetUpdatedLocaleForChromium() 62 locale = new Locale("iw"); in testGetUpdatedLocaleForChromium() 64 Assert.assertEquals(new Locale("he"), updatedLocale); in testGetUpdatedLocaleForChromium() 66 locale = new Locale("ji"); in testGetUpdatedLocaleForChromium() 68 Assert.assertEquals(new Locale("yi"), updatedLocale); in testGetUpdatedLocaleForChromium() 70 locale = new Locale("in"); in testGetUpdatedLocaleForChromium() 72 Assert.assertEquals(new Locale("id"), updatedLocale); in testGetUpdatedLocaleForChromium() 74 locale = new Locale("tl"); in testGetUpdatedLocaleForChromium() [all …]
|
/external/icu/icu4j/demos/src/com/ibm/icu/dev/demo/rbnf/ |
D | RbnfSampleRuleSets.java | 11 import java.util.Locale; 1699 public static final Locale[] sampleRuleSetLocales = 1700 { Locale.US, 1701 Locale.UK, 1702 new Locale("es", "", ""), 1703 Locale.FRANCE, 1704 new Locale("fr", "CH", ""), 1705 Locale.GERMAN, 1706 Locale.ITALIAN, 1707 new Locale("sv", "", ""), [all …]
|
/external/apache-commons-lang/src/test/java/org/apache/commons/lang3/ |
D | LocaleUtilsTest.java | 35 import java.util.Locale; 48 private static final Locale LOCALE_EN = new Locale("en", ""); 49 private static final Locale LOCALE_EN_US = new Locale("en", "US"); 50 private static final Locale LOCALE_EN_US_ZZZZ = new Locale("en", "US", "ZZZZ"); 51 private static final Locale LOCALE_FR = new Locale("fr", ""); 52 private static final Locale LOCALE_FR_CA = new Locale("fr", "CA"); 53 private static final Locale LOCALE_QQ = new Locale("qq", ""); 54 private static final Locale LOCALE_QQ_ZZ = new Locale("qq", "ZZ"); 59 LocaleUtils.isAvailableLocale(Locale.getDefault()); in setUp() 81 final Locale locale = LocaleUtils.toLocale(language); in assertValidToLocale() [all …]
|
/external/libphonenumber/geocoder/test/com/google/i18n/phonenumbers/geocoding/ |
D | PhoneNumberOfflineGeocoderTest.java | 22 import java.util.Locale; 73 geocoder.getDescriptionForNumber(US_NUMBER1, Locale.SIMPLIFIED_CHINESE)); in testGetDescriptionForNumberWithNoDataFile() 75 geocoder.getDescriptionForNumber(BS_NUMBER1, new Locale("en", "US"))); in testGetDescriptionForNumberWithNoDataFile() 77 geocoder.getDescriptionForNumber(AU_NUMBER, new Locale("en", "US"))); in testGetDescriptionForNumberWithNoDataFile() 79 new Locale("en", "US"))); in testGetDescriptionForNumberWithNoDataFile() 81 new Locale("en", "US"))); in testGetDescriptionForNumberWithNoDataFile() 88 geocoder.getDescriptionForNumber(US_NUMBER4, new Locale("en", "US"))); in testGetDescriptionForNumberWithMissingPrefix() 95 geocoder.getDescriptionForNumber(NANPA_TOLL_FREE, new Locale("en", "US"))); in testGetDescriptionForNumberBelongingToMultipleCountriesIsEmpty() 100 geocoder.getDescriptionForNumber(US_NUMBER1, new Locale("en", "US"))); in testGetDescriptionForNumber_en_US() 102 geocoder.getDescriptionForNumber(US_NUMBER2, new Locale("en", "US"))); in testGetDescriptionForNumber_en_US() [all …]
|
/external/apache-commons-lang/src/main/java/org/apache/commons/lang3/ |
D | LocaleUtils.java | 24 import java.util.Locale; 47 private static final List<Locale> AVAILABLE_LOCALE_LIST; 49 private static final Set<Locale> AVAILABLE_LOCALE_SET; 52 …final List<Locale> list = new ArrayList<>(Arrays.asList(Locale.getAvailableLocales())); // extra … 59 private static final ConcurrentMap<String, List<Locale>> cLanguagesByCountry = 63 private static final ConcurrentMap<String, List<Locale>> cCountriesByLanguage = 75 public static List<Locale> availableLocaleList() { in availableLocaleList() 79 private static List<Locale> availableLocaleList(final Predicate<Locale> predicate) { in availableLocaleList() 92 public static Set<Locale> availableLocaleSet() { in availableLocaleSet() 105 public static List<Locale> countriesByLanguage(final String languageCode) { in countriesByLanguage() [all …]
|
/external/cronet/third_party/icu/source/test/intltest/ |
D | loctest.cpp | 302 Locale testLocale(""); in TestBasicGetters() 304 … testLocale = Locale(rawData[LANG][i], rawData[SCRIPT][i], rawData[CTRY][i], rawData[VAR][i]); in TestBasicGetters() 307 testLocale = Locale(rawData[LANG][i], rawData[CTRY][i], rawData[VAR][i]); in TestBasicGetters() 330 Locale testLocale(""); in TestBasicGetters() 332 testLocale = Locale(rawData[LANG][i], rawData[SCRIPT][i], rawData[CTRY][i]); in TestBasicGetters() 335 testLocale = Locale(rawData[LANG][i], rawData[CTRY][i]); in TestBasicGetters() 353 Locale test8 = Locale::createFromName("x-klingon-latn-zx.utf32be@special"); in TestBasicGetters() 374 if (Locale::getDefault() != Locale::createFromName(NULL)) in TestBasicGetters() 383 Locale bogusLang("THISISABOGUSLANGUAGE"); // Jitterbug 2864: language code too long in TestBasicGetters() 388 bogusLang=Locale("eo"); in TestBasicGetters() [all …]
|
D | localematchertest.cpp | 24 const char *locString(const Locale *loc) { in locString() 100 const Locale *best = matcher.getBestMatch(Locale::getFrench(), errorCode); in testEmpty() 126 Locale locales[] = { "fr", "en_GB", "en" }; in testBasics() 130 const Locale *best = matcher.getBestMatch("en_GB", errorCode); in testBasics() 141 std::vector<Locale> locales{ "fr", "en_GB", "en" }; in testBasics() 144 const Locale *best = matcher.getBestMatch("en_GB", errorCode); in testBasics() 154 Locale::RangeIterator<Locale *> iter(ARRAY_RANGE(locales)); in testBasics() 157 const Locale *best = matcher.getBestMatch("en_GB", errorCode); in testBasics() 167 Locale *pointers[] = { locales, locales + 1, locales + 2 }; in testBasics() 172 ARRAY_RANGE(pointers), [](const Locale *p) -> const Locale & { return *p; }). in testBasics() [all …]
|
/external/icu/icu4c/source/test/intltest/ |
D | loctest.cpp | 302 Locale testLocale(""); in TestBasicGetters() 304 … testLocale = Locale(rawData[LANG][i], rawData[SCRIPT][i], rawData[CTRY][i], rawData[VAR][i]); in TestBasicGetters() 307 testLocale = Locale(rawData[LANG][i], rawData[CTRY][i], rawData[VAR][i]); in TestBasicGetters() 330 Locale testLocale(""); in TestBasicGetters() 332 testLocale = Locale(rawData[LANG][i], rawData[SCRIPT][i], rawData[CTRY][i]); in TestBasicGetters() 335 testLocale = Locale(rawData[LANG][i], rawData[CTRY][i]); in TestBasicGetters() 353 Locale test8 = Locale::createFromName("x-klingon-latn-zx.utf32be@special"); in TestBasicGetters() 374 if (Locale::getDefault() != Locale::createFromName(NULL)) in TestBasicGetters() 383 Locale bogusLang("THISISABOGUSLANGUAGE"); // Jitterbug 2864: language code too long in TestBasicGetters() 388 bogusLang=Locale("eo"); in TestBasicGetters() [all …]
|
D | localematchertest.cpp | 24 const char *locString(const Locale *loc) { in locString() 100 const Locale *best = matcher.getBestMatch(Locale::getFrench(), errorCode); in testEmpty() 126 Locale locales[] = { "fr", "en_GB", "en" }; in testBasics() 130 const Locale *best = matcher.getBestMatch("en_GB", errorCode); in testBasics() 141 std::vector<Locale> locales{ "fr", "en_GB", "en" }; in testBasics() 144 const Locale *best = matcher.getBestMatch("en_GB", errorCode); in testBasics() 154 Locale::RangeIterator<Locale *> iter(ARRAY_RANGE(locales)); in testBasics() 157 const Locale *best = matcher.getBestMatch("en_GB", errorCode); in testBasics() 167 Locale *pointers[] = { locales, locales + 1, locales + 2 }; in testBasics() 172 ARRAY_RANGE(pointers), [](const Locale *p) -> const Locale & { return *p; }). in testBasics() [all …]
|
/external/libphonenumber/carrier/test/com/google/i18n/phonenumbers/ |
D | PhoneNumberToCarrierMapperTest.java | 21 import java.util.Locale; 66 carrierMapper.getNameForNumber(UK_MOBILE1, Locale.ENGLISH)); in testGetNameForMobilePortableRegion() 68 carrierMapper.getNameForNumber(UK_MOBILE1, new Locale("sv", "SE"))); in testGetNameForMobilePortableRegion() 70 carrierMapper.getNameForNumber(UK_MOBILE1, Locale.FRENCH)); in testGetNameForMobilePortableRegion() 72 assertEquals("", carrierMapper.getSafeDisplayName(UK_MOBILE1, Locale.ENGLISH)); in testGetNameForMobilePortableRegion() 77 carrierMapper.getNameForNumber(AO_MOBILE1, Locale.ENGLISH)); in testGetNameForNonMobilePortableRegion() 79 carrierMapper.getSafeDisplayName(AO_MOBILE1, Locale.ENGLISH)); in testGetNameForNonMobilePortableRegion() 83 assertEquals("", carrierMapper.getNameForNumber(AO_FIXED1, Locale.ENGLISH)); in testGetNameForFixedLineNumber() 84 assertEquals("", carrierMapper.getNameForNumber(UK_FIXED1, Locale.ENGLISH)); in testGetNameForFixedLineNumber() 88 carrierMapper.getNameForValidNumber(AO_FIXED2, Locale.ENGLISH)); in testGetNameForFixedLineNumber() [all …]
|
/external/icu/icu4c/source/test/perf/normperf/ |
D | dtfmtrtperf.h | 117 const Locale testLocales[] = { in call() 118 Locale("en"), in call() 119 Locale("en_US"), in call() 120 Locale("en_AU"), in call() 121 Locale("de_DE"), in call() 122 Locale("fr"), in call() 123 Locale("ja_JP"), in call() 124 Locale("ko"), in call() 125 Locale("pt"), in call() 126 Locale("th_TH"), in call() [all …]
|
/external/cronet/third_party/icu/source/test/perf/normperf/ |
D | dtfmtrtperf.h | 117 const Locale testLocales[] = { in call() 118 Locale("en"), in call() 119 Locale("en_US"), in call() 120 Locale("en_AU"), in call() 121 Locale("de_DE"), in call() 122 Locale("fr"), in call() 123 Locale("ja_JP"), in call() 124 Locale("ko"), in call() 125 Locale("pt"), in call() 126 Locale("th_TH"), in call() [all …]
|
/external/icu/icu4j/main/tests/localespi/src/com/ibm/icu/dev/test/localespi/ |
D | LocaleNameTest.java | 13 import java.util.Locale; 30 … mGetDisplayScript = Locale.class.getMethod("getDisplayScript", new Class[] {Locale.class}); 39 Locale[] locales = Locale.getAvailableLocales(); in TestLanguageNames() 41 for (Locale inLocale : locales) { in TestLanguageNames() 48 Locale inLocaleICU = TestUtil.toICUExtendedLocale(inLocale); in TestLanguageNames() 49 for (Locale forLocale : locales) { in TestLanguageNames() 105 Locale[] locales = Locale.getAvailableLocales(); in TestScriptNames() 106 for (Locale inLocale : locales) { in TestScriptNames() 113 Locale inLocaleICU = TestUtil.toICUExtendedLocale(inLocale); in TestScriptNames() 118 Locale forLocale = forULocale.toLocale(); in TestScriptNames() [all …]
|
/external/icu/icu4j/main/classes/localespi/src/com/ibm/icu/impl/javaspi/ |
D | ICULocaleServiceProvider.java | 17 import java.util.Locale; 41 private static final Locale[] SPECIAL_LOCALES = { 42 new Locale("ja", "JP", "JP"), 43 new Locale("no"), 44 new Locale("no", "NO"), 45 new Locale("no", "NO", "NY"), 46 new Locale("sr", "CS"), 47 new Locale("th", "TH", "TH"), 50 private static Map<Locale, Locale> SPECIAL_LOCALES_MAP = null; 52 private static Locale[] LOCALES = null; [all …]
|