/arkcompiler/ets_runtime/ecmascript/ |
D | js_date.cpp | 34 void DateUtils::TransferTimeToDate(int64_t timeMs, std::array<int64_t, DATE_LENGTH> *date) in TransferTimeToDate() argument 36 …(*date)[HOUR] = Mod(timeMs, MS_PER_DAY); // ms from hour, minutes,… in TransferTimeToDate() 37 …(*date)[DAYS] = (timeMs - (*date)[HOUR]) / MS_PER_DAY; // days from year, month,… in TransferTimeToDate() 38 (*date)[MS] = (*date)[HOUR] % MS_PER_SECOND; // ms in TransferTimeToDate() 39 …(*date)[HOUR] = ((*date)[HOUR] - (*date)[MS]) / MS_PER_SECOND; // s from hour, minutes, … in TransferTimeToDate() 40 (*date)[SEC] = (*date)[HOUR] % SEC_PER_MINUTE; // second in TransferTimeToDate() 41 … (*date)[HOUR] = ((*date)[HOUR] - (*date)[SEC]) / SEC_PER_MINUTE; // min from hour, minutes in TransferTimeToDate() 42 (*date)[MIN] = (*date)[HOUR] % SEC_PER_MINUTE; // min in TransferTimeToDate() 43 (*date)[HOUR] = ((*date)[HOUR] - (*date)[MIN]) / SEC_PER_MINUTE; // hour in TransferTimeToDate() 44 (*date)[WEEKDAY] = Mod(((*date)[DAYS] + LEAP_NUMBER[0]), DAY_PER_WEEK); // weekday in TransferTimeToDate() [all …]
|
D | date_parse.cpp | 175 DateUnit date = proxy->NextDate(); in ParseLegacyDates() local 177 while (!date.IsStringEnd()) { in ParseLegacyDates() 178 if (date.IsNumber()) { in ParseLegacyDates() 180 int num = date.GetValue(); in ParseLegacyDates() 217 } else if (date.IsMonth()) { in ParseLegacyDates() 218 dayValue->SetMonth(date.GetValue()); in ParseLegacyDates() 219 } else if (date.IsTimeZone() && hasNumber) { in ParseLegacyDates() 221 } else if (date.IsTimeFlag() || date.IsInvalidWord()) { in ParseLegacyDates() 228 } else if (date.IsSign() && ((timeValue->GetIndex() > 0) || timeZone->IsUTC())) { in ParseLegacyDates() 229 if (date.IsSymbol('-')) { in ParseLegacyDates() [all …]
|
D | js_date.h | 68 static void TransferTimeToDate(int64_t timeMs, std::array<int64_t, DATE_LENGTH> *date); 74 static void GetYearFromDays(std::array<int64_t, DATE_LENGTH> *date); 94 static double MakeDay(double year, double month, double date); 160 static double SetDateValues(const std::array<int64_t, DATE_LENGTH> *date, bool isLocal); 162 static void GetDateValues(double timeMs, std::array<int64_t, DATE_LENGTH> *date, bool isLocal); 167 bool GetThisDateValues(std::array<int64_t, DATE_LENGTH> *date, bool isLocal) const;
|
D | object_fast_operator-inl.h | 459 int date = 1; in FastParseDate() local 472 if (!GetNumFromString(data, len, &index, &date)) { in FastParseDate() 478 if (date < 1 || date > JSDate::MAX_DAYS_MONTH) { in FastParseDate() 481 double day = JSDate::MakeDay(year, month - 1, date); in FastParseDate()
|
D | js_serializer.cpp | 557 JSHandle<JSDate> date = JSHandle<JSDate>::Cast(value); in WriteJSDate() local 564 double timeValue = date->GetTimeValue().GetDouble(); in WriteJSDate() 568 double localOffset = date->GetLocalOffset().GetDouble(); in WriteJSDate() 1415 … JSHandle<JSDate> date = JSHandle<JSDate>::Cast(factory_->NewJSObjectByConstructor(dateFunction)); in ReadJSDate() local 1416 JSHandle<JSTaggedValue> dateTag = JSHandle<JSTaggedValue>::Cast(date); in ReadJSDate() 1425 date->SetTimeValue(thread_, JSTaggedValue(timeValue)); in ReadJSDate() 1430 date->SetLocalOffset(thread_, JSTaggedValue(localOffset)); in ReadJSDate()
|
/arkcompiler/ets_frontend/arkguard/test/grammar/date_validation/ |
D | date_tojson.ts | 18 let date = new Date(); variable 20 const dateJson = date.toJSON(); 22 const dateStr = date.toISOString();
|
/arkcompiler/ets_runtime/test/aottest/formatrangetoparts/ |
D | formatrangetoparts.js | 35 const date = Date.now(); constant 36 const expected = dtf.formatRangeToParts(0, date); 38 compare(dtf.formatRangeToParts(-0.9, date), expected, "formatRangeToParts(-0.9)");
|
/arkcompiler/ets_frontend/es2panda/test/type_extractor/testcases_with_assert/projects/test-import-export-type/ |
D | export.ts | 33 date: string, property 38 date: number;
|
D | import-main.ts | 33 date: "2023", 40 AssertType(math.date, "string");
|
/arkcompiler/ets_frontend/es2panda/test/type_extractor/testcases_with_assert/projects/test-import-export/ |
D | import-main.ts | 32 date: "2023" 44 AssertType(math.date, "string");
|
D | export.ts | 46 date: string property
|
/arkcompiler/ets_runtime/test/typeinfer/builtins/ |
D | builtins.ts | 80 let date = new Date(); 81 AssertType(date.getDate(), "number"); 82 AssertType(date.setDate(111), "number"); 83 AssertType(date.toDateString(), "string"); 84 AssertType(date.toISOString(), "string"); 85 AssertType(date.valueOf(), "number");
|
/arkcompiler/ets_runtime/test/typeinfer/automatedcases/ |
D | useRegexpGroups.ts | 31 let date = result[0]; 32 AssertType(date, "string");
|
D | LICENSE.txt | 33 …granted to You under this License for that Work shall terminate as of the date such litigation is …
|
/arkcompiler/ets_runtime/ecmascript/builtins/ |
D | builtins_date_time_format.cpp | 161 JSHandle<JSTaggedValue> date = GetCallArg(argv, 0); in AnonymousDateTimeFormat() local 163 if (date->IsUndefined()) { in AnonymousDateTimeFormat() 166 JSTaggedNumber xNumber = JSTaggedValue::ToNumber(thread, date); in AnonymousDateTimeFormat() 194 JSHandle<JSTaggedValue> date = GetCallArg(argv, 0); in FormatToParts() local 196 if (date->IsUndefined()) { in FormatToParts() 199 JSTaggedNumber xNumber = JSTaggedValue::ToNumber(thread, date); in FormatToParts()
|
/arkcompiler/ets_frontend/test262/ |
D | intl_tests.txt | 74 intl402/Date/prototype/this-value-non-date.js 76 intl402/Date/prototype/this-value-invalid-date.js 87 intl402/DateTimeFormat/test-option-date-time-components.js 93 intl402/DateTimeFormat/required-date-time-formats.js 115 intl402/DateTimeFormat/taint-Object-prototype-date-time-components.js 124 intl402/DateTimeFormat/prototype/formatRangeToParts/argument-date-string.js 130 intl402/DateTimeFormat/prototype/formatRangeToParts/date-x-greater-than-y-throws.js 131 intl402/DateTimeFormat/prototype/formatRangeToParts/date-is-nan-throws.js 135 intl402/DateTimeFormat/prototype/formatRangeToParts/date-is-infinity-throws.js 136 intl402/DateTimeFormat/prototype/formatRangeToParts/date-undefined-throws.js [all …]
|
D | README.md | 123 up to date in 2.225s 129 up to date in 1.446s 135 up to date in 2.412s
|
/arkcompiler/ets_runtime/ecmascript/ts_types/ |
D | lib_ark_builtins.d.ts | 204 …constructor(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?… 242 setDate(date: number): number; 244 setFullYear(year: number, month?: number, date?: number): number; 252 setMonth(month: number, date?: number): number; 258 setUTCDate(date: number): number; 260 setUTCFullYear(year: number, month?: number, date?: number): number; 268 setUTCMonth(month: number, date?: number): number; 294 …static UTC(year: number, month: number, date?: number, hours?: number, minutes?: number, seconds?:…
|
/arkcompiler/ets_frontend/es2panda/test/ |
D | test262skiplist-long.txt | 14 built-ins/Date/prototype/getTimezoneOffset/this-value-valid-date.js
|
/arkcompiler/ets_runtime/ecmascript/tests/ |
D | dump_test.cpp | 611 … JSHandle<JSDate> date = JSHandle<JSDate>::Cast(factory->NewJSObjectWithInit(dateClass)); in HWTEST_F_L0() local 612 date->SetTimeValue(thread, JSTaggedValue(0.0)); in HWTEST_F_L0() 613 date->SetLocalOffset(thread, JSTaggedValue(0.0)); in HWTEST_F_L0() 614 DUMP_FOR_HANDLE(date) in HWTEST_F_L0()
|
/arkcompiler/ets_runtime/ecmascript/builtins/tests/ |
D | builtins_date_time_format_test.cpp | 149 static double BuiltinsDateCreate(const double year, const double month, const double date) in BuiltinsDateCreate() argument 151 const double day = JSDate::MakeDay(year, month, date); in BuiltinsDateCreate()
|
/arkcompiler/ets_runtime/test/moduletest/stubbuilder/ |
D | stubbuilder.js | 993 var date = new Date(); variable
|
/arkcompiler/ets_runtime/ecmascript/napi/ |
D | jsnapi.cpp | 2493 JSHandle<JSDate> date(JSNApiHelper::ToJSHandle(this)); in ToString() local 2494 LOG_IF_SPECIAL(date, ERROR); in ToString() 2495 JSTaggedValue dateStr = date->ToString(thread); in ToString() 2506 JSHandle<JSDate> date(JSNApiHelper::ToJSHandle(this)); in GetTime() local 2507 LOG_IF_SPECIAL(date, ERROR); in GetTime() 2508 if (!date->IsDate()) { in GetTime() 2511 return date->GetTime().GetDouble(); in GetTime()
|
/arkcompiler/toolchain/tooling/test/ |
D | pt_types_test.cpp | 407 Local<DateRef> date = DateRef::New(ecmaVm, input); in HWTEST_F_L0() local 408 std::string description = ObjectRemoteObject::DescriptionForObject(ecmaVm, date); in HWTEST_F_L0()
|
/arkcompiler/ets_runtime/ |
D | LICENSE | 88 as of the date such litigation is filed.
|