Home
last modified time | relevance | path

Searched refs:localeInfo (Results 1 – 25 of 31) sorted by relevance

12

/base/global/resource_management_lite/frameworks/resmgr_lite/test/unittest/lite/common/
Dlocale_info_test.cpp175 LocaleInfo* localeInfo = BuildFromString("zh-CN", '-', state); variable
176 if (localeInfo == nullptr) {
180 UpdateSysDefault(*localeInfo, false);
184 delete localeInfo;
189 delete localeInfo;
190 localeInfo = nullptr;
201 LocaleInfo* localeInfo = BuildFromString("zh-CN", '-', state); variable
202 if (localeInfo == nullptr) {
206 UpdateSysDefault(*localeInfo, false);
210 delete localeInfo;
[all …]
/base/global/resource_management/frameworks/resmgr/test/unittest/common/
Dlocale_info_test.cpp175 Locale *localeInfo = BuildFromString("zh-CN", '-', state); variable
176 if (localeInfo == nullptr) {
180 UpdateSysDefault(*localeInfo, false);
184 delete localeInfo;
189 delete localeInfo;
200 Locale *localeInfo = BuildFromString("zh-CN", '-', state); variable
201 if (localeInfo == nullptr) {
205 UpdateSysDefault(*localeInfo, false);
209 delete localeInfo;
214 delete localeInfo;
[all …]
/base/global/i18n/frameworks/intl/src/
Drelative_time_format.cpp60 localeInfo = std::make_unique<LocaleInfo>(curLocale, configs); in RelativeTimeFormat()
61 if (!localeInfo->InitSuccess()) { in RelativeTimeFormat()
64 locale = localeInfo->GetLocale(); in RelativeTimeFormat()
65 localeBaseName = localeInfo->GetBaseName(); in RelativeTimeFormat()
77 localeInfo = std::make_unique<LocaleInfo>(LocaleConfig::GetSystemLocale(), configs); in RelativeTimeFormat()
78 if (localeInfo->InitSuccess()) { in RelativeTimeFormat()
79 locale = localeInfo->GetLocale(); in RelativeTimeFormat()
80 localeBaseName = localeInfo->GetBaseName(); in RelativeTimeFormat()
88 numberingSystem = localeInfo->GetNumberingSystem(); in RelativeTimeFormat()
Ddate_time_format.cpp57 if (!localeInfo || !dateFormat) { in DateTimeFormat()
72 if (localeInfo != nullptr) { in FreeDateTimeFormat()
73 delete localeInfo; in FreeDateTimeFormat()
74 localeInfo = nullptr; in FreeDateTimeFormat()
85 …if (dateIntvFormat == nullptr || calendar == nullptr || dateFormat == nullptr || localeInfo == nul… in CheckInitSuccess()
103 localeInfo = new LocaleInfo(curLocale, configs); in InitWithLocale()
104 if (localeInfo == nullptr || !localeInfo->InitSuccess()) { in InitWithLocale()
107 locale = localeInfo->GetLocale(); in InitWithLocale()
108 localeTag = localeInfo->GetBaseName(); in InitWithLocale()
110 hourCycle = localeInfo->GetHourCycle(); in InitWithLocale()
[all …]
Dnumber_format.cpp72 localeInfo = std::make_unique<LocaleInfo>(curLocale, configs); in NumberFormat()
73 if (!localeInfo->InitSuccess()) { in NumberFormat()
76 locale = localeInfo->GetLocale(); in NumberFormat()
77 localeBaseName = localeInfo->GetBaseName(); in NumberFormat()
89 localeInfo = std::make_unique<LocaleInfo>(LocaleConfig::GetSystemLocale(), configs); in NumberFormat()
90 if (localeInfo->InitSuccess()) { in NumberFormat()
91 locale = localeInfo->GetLocale(); in NumberFormat()
92 localeBaseName = localeInfo->GetBaseName(); in NumberFormat()
296 GetDefaultPreferredUnit(localeInfo->GetRegion(), unitType, preferredUnits); in Format()
298 GetPreferredUnit(localeInfo->GetRegion(), unitUsage, preferredUnits); in Format()
[all …]
Dcollator.cpp86 localeInfo = std::make_unique<LocaleInfo>(curLocale, options); in Collator()
87 if (!localeInfo->InitSuccess()) { in Collator()
90 locale = localeInfo->GetLocale(); in Collator()
91 localeStr = localeInfo->GetBaseName(); in Collator()
139 collation = localeInfo->GetCollation(); in SetCollation()
169 numeric = localeInfo->GetNumeric(); in SetNumeric()
190 caseFirst = localeInfo->GetCaseFirst(); in SetCaseFirst()
Dplural_rules.cpp120 localeInfo = std::make_unique<LocaleInfo>(curLocale, options); in InitPluralRules()
121 if (!localeInfo->InitSuccess()) { in InitPluralRules()
124 locale = localeInfo->GetLocale(); in InitPluralRules()
125 localeStr = localeInfo->GetBaseName(); in InitPluralRules()
/base/global/resource_management_lite/frameworks/resmgr_lite/src/
Dres_locale.cpp334 bool ResLocale::UpdateDefault(const LocaleInfo &localeInfo, bool needNotify) in UpdateDefault() argument
337 LocaleInfo *temp = new(std::nothrow) LocaleInfo(localeInfo.GetLanguage(), in UpdateDefault()
338 localeInfo.GetScript(), localeInfo.GetRegion()); in UpdateDefault()
369 LocaleInfo *localeInfo = new(std::nothrow) LocaleInfo(resLocale->GetLanguage(), in BuildFromString() local
371 if (localeInfo == nullptr) { in BuildFromString()
376 return localeInfo; in BuildFromString()
407 LocaleInfo *localeInfo = new(std::nothrow) LocaleInfo(language, script, region); in BuildFromParts() local
408 if (localeInfo == nullptr) { in BuildFromParts()
412 return localeInfo; in BuildFromParts()
420 void UpdateSysDefault(const LocaleInfo &localeInfo, bool needNotify) in UpdateSysDefault() argument
[all …]
Dres_config_impl.cpp33 RState ResConfigImpl::SetLocaleInfo(LocaleInfo &localeInfo) in SetLocaleInfo() argument
35 …return this->SetLocaleInfo(localeInfo.GetLanguage(), localeInfo.GetScript(), localeInfo.GetRegion(… in SetLocaleInfo()
Dlocale_matcher.cpp518 bool LocaleMatcher::Normalize(ResLocale *localeInfo) in Normalize() argument
520 if (localeInfo == nullptr) { in Normalize()
523 if (!Utils::IsStrEmpty(localeInfo->GetScript())) { in Normalize()
526 uint32_t encodedScript = FindDefaultScriptEncode(localeInfo->GetLanguage(), in Normalize()
527 localeInfo->GetRegion()); in Normalize()
537 localeInfo->script_ = tempScript; in Normalize()
555 bool IsSimilarToUsEnglish(const ResLocale *localeInfo) in IsSimilarToUsEnglish() argument
558 (localeInfo == nullptr) ? nullptr : localeInfo->GetRegion()); in IsSimilarToUsEnglish()
/base/global/resource_management_lite/frameworks/resmgr_lite/include/
Dres_config.h31 virtual RState SetLocaleInfo(LocaleInfo &localeInfo) = 0;
56 void UpdateSysDefault(const LocaleInfo &localeInfo, bool needNotify);
Dres_config_impl.h54 RState SetLocaleInfo(LocaleInfo &localeInfo);
Dres_locale.h64 static bool UpdateDefault(const LocaleInfo &localeInfo, bool needNotify);
/base/global/i18n_lite/frameworks/i18n/src/
Dweek_info.cpp29 WeekInfo::WeekInfo(const LocaleInfo &localeInfo, I18nStatus &status) in WeekInfo() argument
31 locale = localeInfo; in WeekInfo()
Ddata_resource.cpp31 DataResource::DataResource(const LocaleInfo *localeInfo) in DataResource() argument
34 if (localeInfo == nullptr) { in DataResource()
37 localeMask = localeInfo->GetMask(); in DataResource()
38 if (localeInfo->IsDefaultLocale()) { in DataResource()
41 fallbackMask = GetFallbackMask(*localeInfo); in DataResource()
/base/global/resource_management/interfaces/inner_api/include/
Dres_config.h35 virtual RState SetLocaleInfo(Locale &localeInfo) = 0;
88 EXPORT_FUNC void UpdateSysDefault(const Locale &localeInfo, bool needNotify);
/base/global/resource_management/frameworks/resmgr/src/
Dlocale_matcher.cpp517 bool LocaleMatcher::Normalize(ResLocale *localeInfo) in Normalize() argument
519 if (localeInfo == nullptr) { in Normalize()
522 if (!Utils::IsStrEmpty(localeInfo->GetScript())) { in Normalize()
525 uint32_t encodedScript = FindDefaultScriptEncode(localeInfo->GetLanguage(), in Normalize()
526 localeInfo->GetRegion()); in Normalize()
536 localeInfo->script_ = tempScript; in Normalize()
554 bool IsSimilarToUsEnglish(const ResLocale *localeInfo) in IsSimilarToUsEnglish() argument
557 (localeInfo == nullptr) ? nullptr : localeInfo->GetRegion()); in IsSimilarToUsEnglish()
Dres_config_impl.cpp80 RState ResConfigImpl::SetLocaleInfo(Locale &localeInfo) in SetLocaleInfo() argument
82 …return this->SetLocaleInfo(localeInfo.getLanguage(), localeInfo.getScript(), localeInfo.getCountry… in SetLocaleInfo()
106 RState ResConfigImpl::BuildLocaleInfo(const ResLocale *resLocale, Locale **localeInfo) in BuildLocaleInfo() argument
114 delete *localeInfo; in BuildLocaleInfo()
115 *localeInfo = new Locale(temp); in BuildLocaleInfo()
Dres_locale.cpp335 bool ResLocale::UpdateDefault(const Locale &localeInfo, bool needNotify) in UpdateDefault() argument
339 Locale temp = icu::LocaleBuilder().setLocale(localeInfo).build(errCode); in UpdateDefault()
414 Locale localeInfo = icu::LocaleBuilder().setLanguage(language) in BuildFromParts() local
420 Locale *retLocal = new Locale(localeInfo); in BuildFromParts()
429 void UpdateSysDefault(const Locale &localeInfo, bool needNotify) in UpdateSysDefault() argument
431 ResLocale::UpdateDefault(localeInfo, needNotify); in UpdateSysDefault()
/base/global/resource_management/frameworks/resmgr/include/
Dres_config_impl.h54 RState SetLocaleInfo(Locale &localeInfo);
191 RState BuildLocaleInfo(const ResLocale *resLocale, Locale **localeInfo);
Dres_locale.h70 static bool UpdateDefault(const Locale &localeInfo, bool needNotify);
/base/global/i18n_lite/interfaces/kits/i18n/include/
Dweek_info.h31 WeekInfo(const LocaleInfo &localeInfo, I18nStatus &status);
/base/global/i18n/frameworks/intl/include/
Dplural_rules.h40 std::unique_ptr<LocaleInfo> localeInfo = nullptr; variable
Dcollator.h56 std::unique_ptr<LocaleInfo> localeInfo = nullptr; variable
/base/global/resource_management/interfaces/js/innerkits/core/src/
Dresource_manager_napi_utils.cpp461 const icu::Locale *localeInfo = cfg->GetLocaleInfo(); in GetLocale() local
462 if (localeInfo == nullptr) { in GetLocale()
465 const char *lang = localeInfo->getLanguage(); in GetLocale()
471 const char *script = localeInfo->getScript(); in GetLocale()
476 const char *region = localeInfo->getCountry(); in GetLocale()

12