Home
last modified time | relevance | path

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

/base/notification/distributed_notification_service/frameworks/ans/test/unittest/
Dreminder_request_calendar_test.cpp43 std::shared_ptr<ReminderRequestCalendar> CreateCalendar(tm &nowTime) in CreateCalendar() argument
51 nowTime = *tmp; in CreateCalendar()
52 nowTime.tm_year = 0; in CreateCalendar()
53 nowTime.tm_mon = 0; in CreateCalendar()
54 nowTime.tm_mday = 1; in CreateCalendar()
55 nowTime.tm_hour = 1; in CreateCalendar()
56 nowTime.tm_min = 1; in CreateCalendar()
61 … auto calendar = std::make_shared<ReminderRequestCalendar>(nowTime, repeatMonths, repeatDays); in CreateCalendar()
95 struct tm nowTime; variable
96 auto calendar = ReminderRequestCalendarTest::CreateCalendar(nowTime);
[all …]
/base/inputmethod/imf/services/src/
Dglobal.cpp27 struct tm nowTime; in LogTimeStamp() local
28 localtime_r(&tv.tv_sec, &nowTime); in LogTimeStamp()
30 …printf("%02d-%02d %02d:%02d:%02d.%03d\t", nowTime.tm_mon, nowTime.tm_mday, nowTime.tm_hour, nowTim… in LogTimeStamp()
31 nowTime.tm_sec, static_cast<int32_t>(tv.tv_usec) / millSec); in LogTimeStamp()
/base/notification/eventhandler/frameworks/test/moduletest/
Devent_handler_send_timing_event_module_test.cpp45 int64_t nowTime = GetNowSysTime(); in WaitTaskCalled() local
48 if (handler->PostTimingTask(f, nowTime + delayTime)) { in WaitTaskCalled()
79 int64_t nowTime = GetNowSysTime(); in SendEventWithSmartPtr() local
83 handler->SendTimingEvent(RUN_EVENT_ID, sharedPtr, nowTime + delayTime); in SendEventWithSmartPtr()
87 handler->SendTimingEvent(RUN_EVENT_ID, weakPtr, nowTime + delayTime); in SendEventWithSmartPtr()
91 handler->SendTimingEvent(RUN_EVENT_ID, uniquePtr, nowTime + delayTime); in SendEventWithSmartPtr()
96 … RUN_EVENT_ID, std::unique_ptr<int, void (*)(int *)>((new int(1)), f), nowTime + delayTime); in SendEventWithSmartPtr()
102 handler->SendTimingEvent(STOP_EVENT_ID, delayTime + delayTime + nowTime); in SendEventWithSmartPtr()
149 int64_t nowTime = GetNowSysTime(); variable
154 bool result = handler->SendTimingEvent(nullPtr, nowTime + delayTime, EventQueue::Priority::LOW);
[all …]
/base/notification/distributed_notification_service/frameworks/ans/src/
Dreminder_request_alarm.cpp111 struct tm nowTime; in GetNextTriggerTime() local
112 (void)localtime_r(&now, &nowTime); in GetNextTriggerTime()
115 GetActualTime(TimeTransferType::YEAR, nowTime.tm_year), in GetNextTriggerTime()
116 GetActualTime(TimeTransferType::MONTH, nowTime.tm_mon), in GetNextTriggerTime()
117 nowTime.tm_mday, nowTime.tm_hour, nowTime.tm_min, nowTime.tm_sec, in GetNextTriggerTime()
118 GetActualTime(TimeTransferType::WEEK, nowTime.tm_wday), hour_, minute_); in GetNextTriggerTime()
121 tar.tm_year = nowTime.tm_year; in GetNextTriggerTime()
122 tar.tm_mon = nowTime.tm_mon; in GetNextTriggerTime()
123 tar.tm_mday = nowTime.tm_mday; in GetNextTriggerTime()
163 struct tm nowTime; in GetNextAlarm() local
[all …]
Dreminder_request_calendar.cpp131 struct tm nowTime; in GetNextDay() local
132 nowTime.tm_year = now.tm_year; in GetNextDay()
133 nowTime.tm_mon = now.tm_mon; in GetNextDay()
134 nowTime.tm_mday = now.tm_mday; in GetNextDay()
135 nowTime.tm_hour = now.tm_hour; in GetNextDay()
136 nowTime.tm_min = now.tm_min; in GetNextDay()
137 nowTime.tm_sec = now.tm_sec; in GetNextDay()
138 nowTime.tm_isdst = -1; in GetNextDay()
140 if (mktime(&nowTime) >= mktime(&setTime)) { in GetNextDay()
156 struct tm nowTime; in GetNextTriggerTime() local
[all …]
/base/hiviewdfx/hiview/plugins/usage_event_report/
Dusage_event_report.cpp77 auto nowTime = TimeUtil::GetMilliseconds(); in Init() local
93 lastReportTime_ = nowTime; in Init()
101 lastSysReportTime_ = nowTime; in Init()
107 if (nowTime >= (lastReportTime_ + TimeUtil::MILLISECS_PER_DAY)) { in Init()
113 if (nowTime >= (lastSysReportTime_ + 3600000)) { // 3600000ms: 1h in Init()
150 auto nowTime = TimeUtil::GetMilliseconds(); in ReportDailyEvent() local
151 if (nowTime > (nextReportTime_ + TimeUtil::MILLISECS_PER_DAY) in ReportDailyEvent()
152 || nowTime < (nextReportTime_ - TimeUtil::MILLISECS_PER_DAY)) { in ReportDailyEvent()
155 } else if (nowTime >= nextReportTime_) { in ReportDailyEvent()
/base/hiviewdfx/hiappevent/frameworks/native/libhiappevent/utility/
Dtime_util.cpp36 time_t nowTime = time(nullptr); in GetDate() local
37 if (nowTime < 0) { in GetDate()
42 if (localtime_r(&nowTime, &localTm) == nullptr) { in GetDate()
/base/time/time_service/test/unittest/js_test/nopermission/acl/
DSystemTime.test.js30 const nowTime = new Date().getTime();
31 systemTime.setTime(nowTime).then(() => {
49 const nowTime = new Date().getTime();
50 systemTime.setTime(nowTime, (err) => {
DSystemDateTime.test.js32 const nowTime = new Date().getTime();
33 systemDateTime.setTime(nowTime).then(() => {
51 const nowTime = new Date().getTime();
52 systemDateTime.setTime(nowTime, (err) => {
/base/time/time_service/test/unittest/js_test/nopermission/systemapi/
DSystemDateTime.test.js30 const nowTime = new Date().getTime();
31 systemDateTime.setTime(nowTime).then(() => {
49 const nowTime = new Date().getTime();
50 systemDateTime.setTime(nowTime, (err) => {
/base/time/time_service/test/unittest/js_test/permission/
DSystemDateTimeGet.test.js33 const nowTime = new Date().getTime();
36 expect(typeof (milliTime) === 'number' && milliTime >= nowTime).assertTrue();
49 const nowTime = new Date().getTime();
54 expect(typeof (data) === 'number' && data >= nowTime).assertTrue();
68 const nowTime = new Date().getTime();
71 expect(milliTime >= nowTime && typeof (milliTime) === 'number').assertTrue();
84 const nowTime = new Date().getTime();
89 expect(typeof (data) === 'number' && data >= nowTime).assertTrue();
103 const nowTime = new Date().getTime();
107 expect(milliTime >= nowTime).assertTrue();
[all …]
DSystemTimeGet.test.js33 const nowTime = new Date().getTime();
36 expect(typeof (milliTime) === 'number' && milliTime >= nowTime).assertTrue();
49 const nowTime = new Date().getTime();
54 expect(typeof (data) === 'number' && data >= nowTime).assertTrue();
68 const nowTime = new Date().getTime();
71 expect(milliTime >= nowTime && typeof (milliTime) === 'number').assertTrue();
84 const nowTime = new Date().getTime();
89 expect(typeof (data) === 'number' && data >= nowTime).assertTrue();
103 const nowTime = new Date().getTime();
107 expect(milliTime >= nowTime).assertTrue();
[all …]
/base/notification/distributed_notification_service/test/fuzztest/reminderrequestcalendar_fuzzer/
Dreminderrequestcalendar_fuzzer.cpp35 struct tm nowTime; in DoSomethingInterestingWithMyAPI() local
42 … Notification::ReminderRequestCalendar reminderRequestCalendar(nowTime, repeatMonths, repeatDays); in DoSomethingInterestingWithMyAPI()
48 reminderRequestCalendar.InitDateTime(nowTime); in DoSomethingInterestingWithMyAPI()
67 reminderRequestCalendar.GetNextDay(year, months, nowTime, target); in DoSomethingInterestingWithMyAPI()
72 reminderRequestCalendar.GetNextTriggerTimeAsRepeatReminder(nowTime, tarTime); in DoSomethingInterestingWithMyAPI()
/base/msdp/device_status/services/timer_manager/src/
Dtimer_manager.cpp182 int64_t nowTime = GetMillisTime(); in AddTimerInternal() local
183 if (!AddInt64(nowTime, timer->intervalMs, timer->nextCallTime)) { in AddTimerInternal()
209 int64_t nowTime = GetMillisTime(); in ResetTimerInternal() local
210 if (!AddInt64(nowTime, timer->intervalMs, timer->nextCallTime)) { in ResetTimerInternal()
237 int64_t nowTime = GetMillisTime(); in CalcNextDelayInternal() local
239 if (nowTime >= item->nextCallTime) { in CalcNextDelayInternal()
242 delay = item->nextCallTime - nowTime; in CalcNextDelayInternal()
253 int64_t nowTime = GetMillisTime(); in ProcessTimersInternal() local
259 if ((*tIter)->nextCallTime > nowTime) { in ProcessTimersInternal()
/base/update/updater/services/package/pkg_manager/
Dpkg_utils.cpp185 struct tm nowTime {}; in GetFileSize() struct
187 localtime_s(&nowTime, &when); in GetFileSize()
189 localtime_r(&when, &nowTime); in GetFileSize()
191 int year = nowTime.tm_year; in GetFileSize()
196 date |= static_cast<uint16_t>(static_cast<uint16_t>(nowTime.tm_mon + 1) << TM_MON_BITS); in GetFileSize()
197 date |= static_cast<uint16_t>(nowTime.tm_mday); in GetFileSize()
198 time = static_cast<uint16_t>(static_cast<uint16_t>(nowTime.tm_hour) << TM_HOUR_BITS); in GetFileSize()
199 time |= static_cast<uint16_t>(static_cast<uint16_t>(nowTime.tm_min) << TM_MIN_BITS); in GetFileSize()
200 time |= static_cast<uint16_t>(static_cast<uint16_t>(nowTime.tm_sec) >> 1); in GetFileSize()
/base/account/os_account/services/accountmgr/src/osaccount/
Dos_account_interface.cpp94 struct tm nowTime = {0}; in SendToAMSAccountStop() local
96 OHOS::GetSystemCurrentTime(&nowTime); in SendToAMSAccountStop()
97 while (OHOS::GetSecondsBetween(startTime, nowTime) < Constants::TIME_WAIT_TIME_OUT && in SendToAMSAccountStop()
100 OHOS::GetSystemCurrentTime(&nowTime); in SendToAMSAccountStop()
147 struct tm nowTime = {0}; in SendToIDMAccountDelete() local
149 OHOS::GetSystemCurrentTime(&nowTime); in SendToIDMAccountDelete()
150 while (OHOS::GetSecondsBetween(startTime, nowTime) < Constants::TIME_WAIT_TIME_OUT && in SendToIDMAccountDelete()
153 OHOS::GetSystemCurrentTime(&nowTime); in SendToIDMAccountDelete()
/base/hiviewdfx/hilog_lite/services/hilogcat/
Dhiview_logcat.c59 struct tm nowTime = {0}; in main() local
63 info = localtime_r(&rawtime, &nowTime); in main()
/base/hiviewdfx/hilog_lite/frameworks/mini/
Dhiview_output_log.c404 struct tm nowTime = {0}; in LogCommonFmt() local
407 localtime_r(&time, &nowTime); in LogCommonFmt()
408 month = nowTime.tm_mon + 1; in LogCommonFmt()
409 day = nowTime.tm_mday; in LogCommonFmt()
410 hour = nowTime.tm_hour; in LogCommonFmt()
411 min = nowTime.tm_min; in LogCommonFmt()
412 sec = nowTime.tm_sec; in LogCommonFmt()
/base/hiviewdfx/hilog_lite/services/apphilogcat/
Dhiview_applogcat.c206 struct tm nowTime = {0}; in main() local
210 info = localtime_r(&rawtime, &nowTime); in main()
/base/hiviewdfx/hidumper/frameworks/native/src/util/zip/
Dzip_writer.cpp134 auto nowTime = std::chrono::system_clock::to_time_t(std::chrono::system_clock::now()); in SetTimeToZipFileInfo() local
136 if (localtime_r(&nowTime, &localTime) == nullptr) { in SetTimeToZipFileInfo()
/base/usb/usb_manager/services/native/src/
Dusb_right_manager.cpp125 uint64_t nowTime = GetCurrentTimestamp(); in HasRight() local
133 return !helper->IsRecordExpired(uid, deviceName, bundleName, nowTime); in HasRight()
591 uint64_t nowTime = GetCurrentTimestamp(); in CleanUpRightNormalExpired() local
593 int32_t ret = helper->DeleteNormalExpiredRightRecord(uid, nowTime); in CleanUpRightNormalExpired()
595 … USB_HILOGD(MODULE_USB_SERVICE, "failed: clean up expired record at %{public}" PRIu64 "", nowTime); in CleanUpRightNormalExpired()
/base/startup/init/services/modules/bootevent/
Dbootevent.c170 time_t nowTime = time(NULL); in SaveServiceBootEvent() local
171 INIT_CHECK_RETURN_VALUE(nowTime > 0, -1); in SaveServiceBootEvent()
172 struct tm *p = localtime(&nowTime); in SaveServiceBootEvent()
/base/notification/distributed_notification_service/interfaces/inner_api/
Dreminder_request_calendar.h161 uint64_t GetNextTriggerTimeAsRepeatReminder(const tm &nowTime, const tm &tarTime) const;
/base/hiviewdfx/hidumper/frameworks/native/src/manager/
Ddump_implement.cpp287 struct tm nowTime; in GetTime() local
288 localtime_r(&curTime.tv_sec, &nowTime); in GetTime()
289 (void)strftime(buffer, sizeof(buffer), "%Y%m%d-%H%M%S", &nowTime); in GetTime()
/base/telephony/call_manager/services/call_manager_service/src/
Dcall_manager_service.cpp106 struct tm nowTime = { 0 }; in OnStart() local
111 timeNow = localtime_r(&second, &nowTime); in OnStart()
126 struct tm nowTime = { 0 }; in OnStop() local
131 timeNow = localtime_r(&second, &nowTime); in OnStop()