/base/location/interfaces/inner_api/include/ |
H A D | country_code.h | 36 explicit CountryCode(CountryCode& country) in CountryCode() argument 38 SetCountryCodeStr(country.GetCountryCodeStr()); in CountryCode() 39 SetCountryCodeType(country.GetCountryCodeType()); in CountryCode() 44 inline bool IsSame(CountryCode& country) const in IsSame() 46 return (countryCodeStr_ == country.GetCountryCodeStr()) && in IsSame() 47 (countryCodeType_ == country.GetCountryCodeType()); in IsSame() 60 inline void SetCountryCodeStr(std::string country) in SetCountryCodeStr() argument 62 countryCodeStr_ = country; in SetCountryCodeStr() 89 auto country = std::make_shared<CountryCode>(); in Unmarshalling() local 90 country in Unmarshalling() [all...] |
H A D | i_country_code_callback.h | 36 virtual void OnCountryCodeChange(const std::shared_ptr<CountryCode>& country) = 0;
|
/base/global/i18n/frameworks/intl/entity_recognition/phone_number_recognition/include/ |
H A D | phone_number_matched.h | 36 PhoneNumberMatched(std::string& country); 44 std::string& country); 47 std::vector<int> DealWithoutFixed(icu::UnicodeString& message, std::string& country); 48 bool HandleWithShortAndShort(std::vector<MatchedNumberInfo>& result, std::string& country, 50 std::vector<MatchedNumberInfo> GetPossibleNumberInfos(std::string& country, 52 std::vector<PhoneNumberMatch*> FindNumbers(std::string& country, icu::UnicodeString& filteredString); 53 std::vector<MatchedNumberInfo> FindShortNumbers(std::string& country, icu::UnicodeString& message); 67 std::string country; member in OHOS::Global::I18n::PhoneNumberMatched
|
H A D | phone_number_rule.h | 36 PhoneNumberRule(std::string& country); 45 // Indicates whether the rules of the country are optimized 62 std::string country; member in OHOS::Global::I18n::PhoneNumberRule
|
/base/global/i18n/frameworks/intl/entity_recognition/phone_number_recognition/src/ |
H A D | phone_number_matched.cpp | 32 PhoneNumberMatched::PhoneNumberMatched(std::string& country) in PhoneNumberMatched() argument 34 phoneNumberRule = new PhoneNumberRule(country); in PhoneNumberMatched() 37 this->country = country; in PhoneNumberMatched() 53 return DealWithoutFixed(messageStr, country); in GetMatchedPhoneNumber() 56 std::vector<MatchedNumberInfo> matchedNumberInfoList = GetPossibleNumberInfos(country, in GetMatchedPhoneNumber() 58 std::vector<MatchedNumberInfo> shortList = FindShortNumbers(country, filteredString); in GetMatchedPhoneNumber() 69 std::vector<int> PhoneNumberMatched::DealWithoutFixed(icu::UnicodeString& message, std::string& country) in DealWithoutFixed() argument 71 std::vector<PhoneNumberMatch*> matchList = FindNumbers(country, message); in DealWithoutFixed() 86 std::vector<MatchedNumberInfo> shortResult = FindShortNumbers(country, messag in DealWithoutFixed() 126 FindShortNumbers(std::string& country, icu::UnicodeString& message) FindShortNumbers() argument 176 AddPhoneNumber(std::string& number, int start, std::vector<PhoneNumberMatch*>& matchList, std::string& country) AddPhoneNumber() argument 202 FindNumbers(std::string& country, icu::UnicodeString& filteredString) FindNumbers() argument 256 HandleWithShortAndShort(std::vector<MatchedNumberInfo>& result, std::string& country, MatchedNumberInfo& info, std::pair<int, int>& pos, icu::UnicodeString& filteredString) HandleWithShortAndShort() argument 297 GetPossibleNumberInfos(std::string& country, icu::UnicodeString& src, icu::UnicodeString& filteredString) GetPossibleNumberInfos() argument [all...] |
H A D | phone_number_rule.cpp | 37 PhoneNumberRule::PhoneNumberRule(std::string& country) in PhoneNumberRule() argument 39 xmlPath = "/system/usr/ohos_locale_config/phonenumber/" + country + ".xml"; in PhoneNumberRule() 56 this->country = country; in PhoneNumberRule() 96 // Load the rules of the corresponding country
|
/base/location/frameworks/cj/source/ |
H A D | country_code_callback.cpp | 30 callback_ = [ lambda = CJLambda::Create(cFunc)](const std::shared_ptr<Location::CountryCode>& country) -> in CountryCodeCallback() 31 void { lambda(CountryCodeToCJCountryCode(country)); }; in CountryCodeCallback() 61 void CountryCodeCallback::OnCountryCodeChange(const std::shared_ptr<Location::CountryCode>& country) in OnCountryCodeChange() argument 66 callback_(country); in OnCountryCodeChange()
|
H A D | geolocationmanager_utils.cpp | 101 std::string country = request.country; in CJReverseGeoCodeRequestToMessageParcel() local 116 dataParcel.WriteString16(Str8ToStr16(country)); // country in CJReverseGeoCodeRequestToMessageParcel() 177 std::string country = request.country; in CJGeoCodeRequestToMessageParcel() local 212 dataParcel.WriteString16(Str8ToStr16(country)); // country in CJGeoCodeRequestToMessageParcel() 308 CJCountryCode CountryCodeToCJCountryCode(const std::shared_ptr<Location::CountryCode>& country) in CountryCodeToCJCountryCode() argument 310 return CJCountryCode{ .country in CountryCodeToCJCountryCode() [all...] |
/base/location/services/location_locator/callback/source/ |
H A D | country_code_callback_proxy.cpp | 30 void CountryCodeCallbackProxy::OnCountryCodeChange(const std::shared_ptr<CountryCode>& country) in OnCountryCodeChange() argument 34 if (country == nullptr) { in OnCountryCodeChange() 35 LBSLOGI(COUNTRY_CODE_CALLBACK, "CountryCodeCallbackProxy::country is nullptr"); in OnCountryCodeChange() 41 country->Marshalling(data); in OnCountryCodeChange()
|
/base/global/i18n/frameworks/zone/test/unittest/ |
H A D | zone_util_test.cpp | 90 string country = "CN";
in HWTEST_F() local 93 util.GetZoneList(country, out);
in HWTEST_F() 101 country = "fake";
in HWTEST_F() 103 util.GetZoneList(country, out);
in HWTEST_F() 115 string country = "GB";
in HWTEST_F() local 118 util.GetZoneList(country, out);
in HWTEST_F() 135 string country = "DE";
in HWTEST_F() local 138 util.GetZoneList(country, out);
in HWTEST_F() 155 string country = "CN";
in HWTEST_F() local 158 util.GetZoneList(country, 360 in HWTEST_F() [all...] |
H A D | zone_util_performance_test.cpp | 111 string country = "CN";
in HWTEST_F() local 116 util.GetZoneList(country, out);
in HWTEST_F() 134 string country = "GB";
in HWTEST_F() local 139 util.GetZoneList(country, out);
in HWTEST_F() 157 string country = "DE";
in HWTEST_F() local 162 util.GetZoneList(country, out);
in HWTEST_F() 180 string country = "CN";
in HWTEST_F() local 185 util.GetZoneList(country, 3600 * 1000 * 8, out);
in HWTEST_F()
|
/base/location/frameworks/js/napi/source/ |
H A D | country_code_callback_napi.cpp | 83 bool CountryCodeCallbackNapi::Send(const std::shared_ptr<CountryCode>& country) in Send() argument 95 if (country == nullptr) { in Send() 96 LBSLOGE(COUNTRY_CODE_CALLBACK, "country == nullptr."); in Send() 119 context->country = country; in Send() 160 if (context->country) { in UvQueueWork() 161 CountryCodeToJs(context->env, context->country, jsEvent); in UvQueueWork() 163 LBSLOGE(LOCATOR_STANDARD, "country is nullptr!"); in UvQueueWork() 183 void CountryCodeCallbackNapi::OnCountryCodeChange(const std::shared_ptr<CountryCode>& country) in OnCountryCodeChange() argument 186 Send(country); in OnCountryCodeChange() [all...] |
/base/location/frameworks/cj/include/ |
H A D | country_code_callback.h | 35 void OnCountryCodeChange(const std::shared_ptr<Location::CountryCode>& country) override; 44 std::function<void(const std::shared_ptr<Location::CountryCode>& country)> callback_ = nullptr;
|
H A D | geolocationmanager_utils.h | 69 char* country; member 81 char* country; member 87 char* country; member 95 char* country; member 217 CJCountryCode CountryCodeToCJCountryCode(const std::shared_ptr<Location::CountryCode>& country);
|
/base/global/i18n/interfaces/native/inner_api/zone/include/ |
H A D | zone_util.h | 64 * @brief Get the default timezone for the given country
66 * @param country Indicating the country code
67 * @return Returns the default timezone if the country code is valid, otherwise
70 std::string GetDefaultZone(const std::string &country);
83 * @brief Get the default timezone name for the given country code
85 * @param country Indicating the country code
87 * @return Returns the default timezone name if the country code is valid, otherwise
90 std::string GetDefaultZone(const std::string country, cons [all...] |
/base/location/frameworks/js/napi/include/ |
H A D | country_code_callback_napi.h | 36 void OnCountryCodeChange(const std::shared_ptr<CountryCode>& country) override; 37 bool Send(const std::shared_ptr<CountryCode>& country);
|
/base/global/i18n/frameworks/intl/test/fuzztest/regexrule_fuzzer/ |
H A D | regexrule_fuzzer.cpp | 39 std::string country = LocaleConfig::GetSystemRegion(); in DoSomethingInterestingWithMyAPI() local 40 phoneNumberUtil->Parse(input, country, &phoneNumber); in DoSomethingInterestingWithMyAPI()
|
/base/location/frameworks/native/locator_sdk/source/ |
H A D | country_code_manager.cpp | 61 auto country = std::make_shared<CountryCode>(*lastCountry_); in NotifyAllListener() local 67 countryCodeCallback->OnCountryCodeChange(country); in NotifyAllListener() 246 CountryCode country; in GetIsoCountryCode() local 247 country.SetCountryCodeStr(countryCodeStr8); in GetIsoCountryCode() 248 country.SetCountryCodeType(type); in GetIsoCountryCode() 249 if (lastCountry_ && !country.IsSame(*lastCountry_) && !lastCountry_->IsMoreReliable(type)) { in GetIsoCountryCode() 344 CountryCode country; in OnLocationReport() local 345 country.SetCountryCodeStr(code); in OnLocationReport() 346 country.SetCountryCodeType(COUNTRY_CODE_FROM_LOCATION); in OnLocationReport()
|
H A D | country_code_callback_host.cpp | 44 void CountryCodeCallbackHost::OnCountryCodeChange(const std::shared_ptr<CountryCode>& country) in OnCountryCodeChange() argument
|
/base/location/services/location_locator/callback/include/ |
H A D | country_code_callback_proxy.h | 31 void OnCountryCodeChange(const std::shared_ptr<CountryCode>& country) override;
|
/base/location/services/location_geocode/geocode/source/ |
H A D | geo_convert_request.cpp | 166 void GeoConvertRequest::SetCountry(std::string country) in SetCountry() argument 168 country_ = country; in SetCountry() 200 parcel.WriteString16(Str8ToStr16(country_)); // country in Marshalling() 231 country_ = Str16ToStr8(parcel.ReadString16()); // country in ReadFromParcel() 252 auto country = in.ReadString16(); in OrderParcel() local 257 out.WriteString16(country); // country in OrderParcel()
|
/base/location/frameworks/native/locator_sdk/include/ |
H A D | country_code_callback_host.h | 29 void OnCountryCodeChange(const std::shared_ptr<CountryCode>& country) override;
|
/base/global/i18n/frameworks/zone/src/ |
H A D | zone_util.cpp | 38 const char *ZoneUtil::SECOND_TAG = "country";
79 string ZoneUtil::GetDefaultZone(const string &country)
in GetDefaultZone() argument 81 string temp(country);
in GetDefaultZone() 114 string ZoneUtil::GetDefaultZone(const string country, const int32_t offset)
in GetDefaultZone() argument 118 TimeZone::createTimeZoneIDEnumeration(UCAL_ZONE_TYPE_ANY, country.c_str(), &offset, status);
in GetDefaultZone() 148 void ZoneUtil::GetZoneList(const string country, vector<string> &retVec)
in GetZoneList() argument 150 StringEnumeration *strEnum = TimeZone::createEnumeration(country.c_str());
in GetZoneList() 158 void ZoneUtil::GetZoneList(const string country, const int32_t offset, vector<string> &retVec)
in GetZoneList() argument 162 TimeZone::createTimeZoneIDEnumeration(UCAL_ZONE_TYPE_ANY, country.c_str(), &offset, status);
in GetZoneList()
|
/base/global/i18n/frameworks/intl/src/ |
H A D | utils.cpp | 185 std::string GetISO3Country(const string& country) in GetISO3Country() argument 189 if (LocaleConfig::IsValidRegion(country)) { in GetISO3Country() 190 locale = icu::LocaleBuilder().setLanguage("zh").setRegion(country).build(icuStatus); in GetISO3Country() 191 } else if (LocaleConfig::IsValidTag(country)) { in GetISO3Country() 192 locale = icu::Locale::forLanguageTag(country.data(), icuStatus); in GetISO3Country()
|
H A D | phone_number_format.cpp | 110 country = countryTag; in PhoneNumberFormat() 113 country = locale.getCountry(); in PhoneNumberFormat() 136 formatter = std::unique_ptr<AsYouTypeFormatter>(util->GetAsYouTypeFormatter(country)); in PhoneNumberFormat() 171 PhoneNumberUtil::ErrorType type = util->Parse(number, country, &phoneNumber); in isValidPhoneNumber() 186 PhoneNumberUtil::ErrorType type = util->ParseAndKeepRawInput(number, country, &phoneNumber); in format() 192 util->FormatInOriginalFormat(phoneNumber, country, &formatted_number); in format() 243 // Combine country and locale parameters in getLocationName() 247 icu::LocaleBuilder builder = icu::LocaleBuilder().setRegion(country); in getLocationName() 269 // Check if region name is a country name in getLocationName()
|