Home
last modified time | relevance | path

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

12

/base/hiviewdfx/hiview/plugins/usage_event_report/
Dusage_event_report.cpp71 auto nowTime = TimeUtil::GetMilliseconds(); in Init()
98 …nextReportTime_ = static_cast<uint64_t>(TimeUtil::Get0ClockStampMs()) + TimeUtil::MILLISECS_PER_DA… in Init()
101 if (nowTime >= (lastReportTime_ + TimeUtil::MILLISECS_PER_DAY)) { in Init()
142 auto nowTime = TimeUtil::GetMilliseconds(); in ReportDailyEvent()
143 if (nowTime > (nextReportTime_ + TimeUtil::MILLISECS_PER_DAY) in ReportDailyEvent()
144 || nowTime < (nextReportTime_ - TimeUtil::MILLISECS_PER_DAY)) { in ReportDailyEvent()
146 …nextReportTime_ = static_cast<uint64_t>(TimeUtil::Get0ClockStampMs()) + TimeUtil::MILLISECS_PER_DA… in ReportDailyEvent()
157 lastReportTime_ = TimeUtil::GetMilliseconds(); in ReportDailyEvent()
158 nextReportTime_ += TimeUtil::MILLISECS_PER_DAY; in ReportDailyEvent()
177 lastSysReportTime_ = TimeUtil::GetMilliseconds(); in ReportSysUsageEvent()
/base/hiviewdfx/hiview/base/event_pool/test/unittest/common/
Devent_pool_test.cpp57 auto startTime = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
77 auto time = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
82 time = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
91 time = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
100 auto end = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
117 auto startTime = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
144 auto time = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
151 time = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
160 auto end = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
177 auto startTime = OHOS::HiviewDFX::TimeUtil::GetMilliseconds();
[all …]
/base/hiviewdfx/hiview/plugins/eventlogger/
Devent_logger.cpp56 HIVIEW_LOGD("event time:%{public}llu jsonExtraInfo is %{public}s", TimeUtil::GetMilliseconds(), in IsInterestedPipelineEvent()
90 … HIVIEW_LOGD("event time:%{public}llu jsonExtraInfo is %{public}s", TimeUtil::GetMilliseconds(), in OnEvent()
116 uint64_t logTime = event->happenTime_ / TimeUtil::SEC_TO_MILLISEC; in StartLogCollect()
120 + TimeUtil::TimestampFormatToDate(logTime, "%Y%m%d%H%M%S") + ".log"; in StartLogCollect()
133 auto start = TimeUtil::GetMilliseconds(); in StartLogCollect()
134 uint64_t startTime = start / TimeUtil::SEC_TO_MILLISEC; in StartLogCollect()
135 std::string startTimeStr = TimeUtil::TimestampFormatToDate(startTime, "%Y/%m/%d-%H:%M:%S"); in StartLogCollect()
136 startTimeStr += ":" + std::to_string(start % TimeUtil::SEC_TO_MILLISEC); in StartLogCollect()
142 auto end = TimeUtil::GetMilliseconds(); in StartLogCollect()
162 uint64_t logTime = event->happenTime_ / TimeUtil::SEC_TO_MILLISEC; in WriteCommonHead()
[all …]
/base/hiviewdfx/hiview/plugins/eventservice/store/
Dsys_event_db_cleaner.cpp37 const int64_t MILLISECS_PER_HOUR = TimeUtil::SECONDS_PER_HOUR * TimeUtil::SEC_TO_MILLISEC;
60 int64_t delEndTime = static_cast<int64_t>(TimeUtil::GetMilliseconds()); in TryToCleanDb()
Dsys_event_db_mgr.cpp55 int delay = TimeUtil::SECONDS_PER_HOUR; // 1 hour in StartCheckStoreTask()
/base/hiviewdfx/hiview/plugins/freeze_detector/test/unittest/common/
Dfreeze_detector_unittest.cpp164 .InitTimestamp(TimeUtil::GetMilliseconds())
170 .InitTimestamp(TimeUtil::GetMilliseconds())
193 .InitTimestamp(TimeUtil::GetMilliseconds())
199 .InitTimestamp(TimeUtil::GetMilliseconds())
Dfreeze_detector_test.cpp44 auto time = TimeUtil::GetMilliseconds(); in makeEvent()
58 sysEvent->SetEventValue("tz_", TimeUtil::GetTimeZone()); in makeEvent()
188 sysEvent->SetEventValue("time_", TimeUtil::GetMilliseconds());
192 sysEvent->SetEventValue("tz_", TimeUtil::GetTimeZone());
/base/security/access_token/services/privacymanager/include/common/
Dtime_util.h22 class TimeUtil {
/base/hiviewdfx/hiappevent/frameworks/native/libhiappevent/utility/include/
Dtime_util.h22 namespace TimeUtil {
/base/hiviewdfx/hiview/adapter/utility/
Dtime_util.cpp22 namespace TimeUtil { namespace
/base/hiviewdfx/hiview/plugins/usage_event_report/service/factory/
Dapp_usage_event_factory.cpp97 int64_t today0Time = TimeUtil::Get0ClockStampMs(); in GetAppUsageInfosByUserId()
98 int64_t gapTime = static_cast<int64_t>(TimeUtil::MILLISECS_PER_DAY); in GetAppUsageInfosByUserId()
111 std::string dateStr = TimeUtil::TimestampFormatToDate(startTime / MILLISEC_TO_SEC, DATE_FORMAT); in GetAppUsageInfosByUserId()
Dsys_usage_event_factory.cpp40 event->Update(KEY_OF_END, TimeUtil::GetMilliseconds()); in Create()
/base/security/access_token/services/privacymanager/src/common/
Dtime_util.cpp22 int64_t TimeUtil::GetCurrentTimestamp() in GetCurrentTimestamp()
/base/hiviewdfx/hiview/adapter/utility/platform/ohos/
Dcommon_utils.cpp61 uint64_t startTime = TimeUtil::GetNanoTime(); in ExecCommand()
68 uint64_t duration = TimeUtil::GetNanoTime() - startTime; in ExecCommand()
/base/security/access_token/services/privacymanager/src/database/
Ddata_translator.cpp39 int64_t beginTime = TimeUtil::GetCurrentTimestamp() - Constant::LATEST_RECORD_TIME; in TranslationIntoGenericValues()
41 end = TimeUtil::GetCurrentTimestamp(); in TranslationIntoGenericValues()
/base/hiviewdfx/hiappevent/frameworks/native/libhiappevent/utility/
Dtime_util.cpp23 namespace TimeUtil { namespace
/base/hiviewdfx/hiview/base/event_pool/
Devent_thread_pool.cpp62 uint64_t targetTime = TimeUtil::GetMilliseconds() + delay; in AddTask()
103 uint64_t now = TimeUtil::GetMilliseconds(); in TaskCallback()
Devent_thread_pool.h35 seq = TimeUtil::GetNanoTime(); in TaskEvent()
/base/hiviewdfx/hiview/plugins/eventlogger/test/unittest/common/
Devent_logger_plugin_test.cpp174 event->happenTime_ = TimeUtil::GetMilliseconds();
200 event->happenTime_ = TimeUtil::GetMilliseconds();
226 event->happenTime_ = TimeUtil::GetMilliseconds();
252 event->happenTime_ = TimeUtil::GetMilliseconds();
/base/hiviewdfx/hiview/core/
Dplatform_monitor.h82 uint32_t collectPeriod_ = 5 * TimeUtil::SECONDS_PER_MINUTE; // 5 minute
83 uint32_t reportPeriod_ = TimeUtil::SECONDS_PER_HOUR; // one hour
Dplatform_monitor.cpp108 curRealSpeed_ = (TimeUtil::SEC_TO_MICROSEC * onceTotalCnt) / onceTotalRealTime; in CollectPerfProfiler()
121 curProcSpeed_ = (TimeUtil::SEC_TO_MICROSEC * onceTotalCnt) / onceTotalProcTime; in CollectPerfProfiler()
390 breakTimestamp_ = TimeUtil::GenerateTimestamp(); in Breaking()
397 TimeUtil::Sleep(SLEEP_TEN_SECONDS); in Breaking()
400 recoverTimestamp_ = TimeUtil::GenerateTimestamp(); in Breaking()
/base/hiviewdfx/hiview/adapter/utility/test/unittest/common/
Dadapter_utility_ohos_test.cpp144 auto time = TimeUtil::GetMillSecOfSec();
147 TimeUtil::Sleep(sleepSecs);
159 auto time1 = TimeUtil::Get0ClockStampMs();
160 auto time2 = TimeUtil::GetSteadyClockTimeMs();
/base/hiviewdfx/hiview/adapter/utility/include/
Dtime_util.h26 namespace TimeUtil {
/base/hiviewdfx/hiview/utility/common_utils/
Dtbox.cpp159 uint64_t startTime = TimeUtil::GetNanoTime(); in WaitForDoneFile()
161 uint64_t duration = TimeUtil::GetNanoTime() - startTime; in WaitForDoneFile()
/base/hiviewdfx/hiview/plugins/hicollie_collector/test/unittest/common/
Dhicollie_collector_test.cpp42 auto time = TimeUtil::GetMilliseconds(); in makeEvent()
56 sysEvent->SetEventValue("tz_", TimeUtil::GetTimeZone()); in makeEvent()

12