/base/global/i18n_lite/frameworks/i18n/src/ |
H A D | date_time_format.cpp | 25 * construct a DateTimeFormat object with request pattern and locale.
29 DateTimeFormat::DateTimeFormat(AvailableDateTimeFormatPattern requestPattern, const LocaleInfo &locale)
in DateTimeFormat() function in DateTimeFormat 35 DateTimeFormat::~DateTimeFormat()
in ~DateTimeFormat() 43 bool DateTimeFormat::Init()
in Init() 94 void DateTimeFormat::Format(const time_t &cal, const string &zoneInfo, string &appendTo, I18nStatus &status)
in Format() 106 void DateTimeFormat::ApplyPattern(const AvailableDateTimeFormatPattern &requestPattern)
in ApplyPattern() 119 std::string DateTimeFormat::GetWeekName(const int32_t &index, DateTimeDataType type)
in GetWeekName() 130 std::string DateTimeFormat [all...] |
/base/global/i18n/frameworks/intl/src/ |
H A D | date_time_format.cpp | 24 const char* DateTimeFormat::DEVICE_TYPE_NAME = "const.product.devicetype"; 25 const char *DateTimeFormat::TIMEZONE_KEY = "persist.time.timezone"; 26 const char *DateTimeFormat::DEFAULT_TIMEZONE = "GMT"; 29 bool DateTimeFormat::icuInitialized = DateTimeFormat::Init(); 31 std::map<std::string, DateFormat::EStyle> DateTimeFormat::dateTimeStyle = { 38 std::unordered_map<std::string, DateTimeFormat::DefaultStyle> DateTimeFormat::DeviceToStyle = { 48 std::unordered_map<DateTimeFormat::DefaultStyle, DateFormat::EStyle> DateTimeFormat 54 DateTimeFormat::DateTimeFormat(const std::vector<std::string> &localeTags, std::map<std::string, std::string> &configs) DateTimeFormat() function in OHOS::Global::I18n::DateTimeFormat [all...] |
/base/global/i18n/frameworks/intl/test/fuzztest/datetimeformat_fuzzer/ |
H A D | datetimeformat_fuzzer.cpp | 33 DateTimeFormat dateTimeFormat(localeTags, configs); in DoSomethingInterestingWithMyAPI() 52 std::unique_ptr<DateTimeFormat> dtFormat = in DoSomethingInterestingWithMyAPI() 53 DateTimeFormat::CreateInstance(localeTags, configs); in DoSomethingInterestingWithMyAPI()
|
/base/global/i18n_lite/interfaces/kits/i18n/include/ |
H A D | date_time_format.h | 39 * Creating a <b>DateTimeFormat</b> instance: \n
40 * {@code DateTimeFormat formatter(AvailableDateTimeFormatPattern::HOUR_MINUTE, locale);}
64 class DateTimeFormat {
class 67 * @brief A constructor used to create a <b>DateTimeFormat</b> instance with specified pattern and locale.
74 DateTimeFormat(AvailableDateTimeFormatPattern requestPattern, const LocaleInfo &locale);
77 * @brief A destructor used to delete the <b>DateTimeFormat</b> instance.
82 ~DateTimeFormat();
|
/base/global/i18n/frameworks/intl/test/unittest/ |
H A D | intl_test.cpp | 135 * @tc.desc: Test Intl DateTimeFormat.format
153 DateTimeFormat *dateFormat = new (std::nothrow) DateTimeFormat(locales, options);
in HWTEST_F() 233 * @tc.desc: Test Intl DateTimeFormat.format
250 DateTimeFormat *dateFormat = new (std::nothrow) DateTimeFormat(locales, options);
in HWTEST_F() 266 * @tc.desc: Test Intl DateTimeFormat.format
279 DateTimeFormat *dateFormat = new (std::nothrow) DateTimeFormat(locales, options);
in HWTEST_F() 482 * @tc.desc: Test Intl DateTimeFormat
[all...] |
H A D | intl_test_extent.cpp | 693 std::unique_ptr<DateTimeFormat> defaultFormatter = DateTimeFormat::CreateInstance(locales, defaultOptions); in HWTEST_F() 699 std::unique_ptr<DateTimeFormat> dateFormatter = DateTimeFormat::CreateInstance(locales, dateOptions); in HWTEST_F() 705 std::unique_ptr<DateTimeFormat> timeFormatter = DateTimeFormat::CreateInstance(locales, timeOptions); in HWTEST_F() 744 std::unique_ptr<DateTimeFormat> monthFormatter = DateTimeFormat::CreateInstance(locales, monthOptions); in HWTEST_F() 750 std::unique_ptr<DateTimeFormat> weekdayFormatter = DateTimeFormat in HWTEST_F() [all...] |
/base/global/i18n/frameworks/intl/include/ |
H A D | date_time_format.h | 36 class DateTimeFormat { class 38 DateTimeFormat(const std::vector<std::string> &localeTags, std::map<std::string, std::string> &configs); 39 virtual ~DateTimeFormat(); 58 static std::unique_ptr<DateTimeFormat> CreateInstance(const std::vector<std::string> &localeTags, 128 static std::unordered_map<DateTimeFormat::DefaultStyle, icu::DateFormat::EStyle> DefaultDTStyle;
|
/base/global/i18n_lite/frameworks/i18n/test/unittest/lite/common/ |
H A D | i18n_test.cpp | 189 * @tc.desc: Test DateTimeFormat Constructor
196 DateTimeFormat *formatter = new DateTimeFormat(pattern, locale);
in HWTEST_F() 203 * @tc.desc: Test DateTimeFormat Init function
210 DateTimeFormat formatter(pattern, locale);
in HWTEST_F() 216 * @tc.desc: Test DateTimeFormat Format function
226 DateTimeFormat formatter(pattern, locale);
in HWTEST_F() 234 * @tc.desc: Test DateTimeFormat Format function
244 DateTimeFormat formatter(pattern, locale);
in HWTEST_F() 252 * @tc.desc: Test DateTimeFormat Forma [all...] |
/base/global/i18n/interfaces/js/kits/include/ |
H A D | intl_addon.h | 122 std::unique_ptr<DateTimeFormat> datefmt_ = nullptr;
|
/base/global/i18n/interfaces/js/kits/src/ |
H A D | intl_addon.cpp | 109 status = napi_define_class(env, "DateTimeFormat", NAPI_AUTO_LENGTH, DateTimeFormatConstructor, nullptr, in InitDateTimeFormat() 116 status = napi_set_named_property(env, exports, "DateTimeFormat", constructor); in InitDateTimeFormat() 417 HILOG_ERROR_I18N("DateTimeFormatConstructor: Init DateTimeFormat failed"); in DateTimeFormatConstructor() 434 datefmt_ = DateTimeFormat::CreateInstance(localeTags, map); in InitDateTimeFormatContext() 511 HILOG_ERROR_I18N("FormatDateTime: Get DateTimeFormat object failed"); in FormatDateTime() 543 HILOG_ERROR_I18N("FormatDateTimeRange: Get DateTimeFormat object failed"); in FormatDateTimeRange() 1073 HILOG_ERROR_I18N("GetDateTimeResolvedOptions: Get DateTimeFormat object failed"); in GetDateTimeResolvedOptions() 1357 HILOG_ERROR_I18N("CollatorConstructor: Init DateTimeFormat failed"); in CollatorConstructor() 1740 HILOG_ERROR_I18N("PluralRulesConstructor: Init DateTimeFormat failed"); in PluralRulesConstructor()
|