Home
last modified time | relevance | path

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

12

/base/time/time_service/services/time/src/
Dtimer_call_back.cpp47 bool TimerCallback::InsertTimerCallbackInfo(const uint64_t timerId, const std::shared_ptr<ITimerInf… in InsertTimerCallbackInfo() argument
55 auto info = timerInfoMap_.find(timerId); in InsertTimerCallbackInfo()
60 timerInfoMap_[timerId] = timerInfo; in InsertTimerCallbackInfo()
66 bool TimerCallback::RemoveTimerCallbackInfo(const uint64_t timerId) in RemoveTimerCallbackInfo() argument
70 auto info = timerInfoMap_.find(timerId); in RemoveTimerCallbackInfo()
80 void TimerCallback::NotifyTimer(const uint64_t timerId, const sptr<IRemoteObject> &timerCallback) in NotifyTimer() argument
86 auto it = timerInfoMap_.find(timerId); in NotifyTimer()
96 … TIME_HILOGE(TIME_MODULE_SERVICE, "timerCallback nullptr timerId:%{public}" PRId64 "", timerId); in NotifyTimer()
101 …ME_HILOGE(TIME_MODULE_SERVICE, "timerNotifyCallback nullptr timerId:%{public}" PRId64 "", timerId); in NotifyTimer()
104 timerNotifyCallback->Finish(timerId); in NotifyTimer()
Dtimer_notify_call_back.cpp28 void TimerNotifyCallback::Finish(const uint64_t timerId) in Finish() argument
/base/powermgr/thermal_manager/services/native/src/thermal_action/
Dthermal_timer.cpp68 uint64_t timerId = 0; in CreateTimer() local
69 timerId = TimeServiceClient::GetInstance()->CreateTimer(timerInfo); in CreateTimer()
70 if (timerId <= 0) { in CreateTimer()
72 return timerId; in CreateTimer()
74 return timerId; in CreateTimer()
77 bool ThermalTimer::StartTimer(uint64_t timerId, uint64_t triggerTime) in StartTimer() argument
80 auto ret = TimeServiceClient::GetInstance()->StartTimer(timerId, triggerTime); in StartTimer()
89 bool ThermalTimer::StopTimer(uint64_t timerId) in StopTimer() argument
91 auto ret = TimeServiceClient::GetInstance()->StopTimer(timerId); in StopTimer()
99 bool ThermalTimer::DestroyTimer(uint64_t timerId) in DestroyTimer() argument
[all …]
/base/time/time_service/services/time/test/unittest/src/
Dtime_client_test.cpp277 uint64_t timerId = 0; variable
278 auto ret = TimeServiceClient::GetInstance()->StartTimerV9(timerId, 5);
280 ret = TimeServiceClient::GetInstance()->StopTimerV9(timerId);
282 ret = TimeServiceClient::GetInstance()->DestroyTimerV9(timerId);
299 uint64_t timerId; variable
300 auto errCode = TimeServiceClient::GetInstance()->CreateTimerV9(timerInfo, timerId);
301 TIME_HILOGI(TIME_MODULE_CLIENT, "timerId now : %{public}" PRId64 "", timerId);
303 auto ret = TimeServiceClient::GetInstance()->StartTimerV9(timerId, 2000);
305 ret = TimeServiceClient::GetInstance()->StopTimerV9(timerId);
307 ret = TimeServiceClient::GetInstance()->DestroyTimerV9(timerId);
[all …]
/base/time/time_service/framework/js/napi/system_timer/src/
Dnapi_system_timer.cpp229 uint64_t timerId = 0; in CreateTimer() member
244 createTimerContext->timerId); in CreateTimer()
251 uint64_t timerId = static_cast<uint64_t>(createTimerContext->timerId); in CreateTimer() local
252 createTimerContext->status = napi_create_int64(createTimerContext->env, timerId, &output); in CreateTimer()
262 uint64_t timerId = 0; in StartTimer() member
269 int64_t timerId = 0; in StartTimer() local
270 startTimerContext->status = napi_get_value_int64(env, argv[ARGV_FIRST], &timerId); in StartTimer()
273 startTimerContext->timerId = static_cast<uint64_t>(timerId); in StartTimer()
284 …TimeServiceClient::GetInstance()->StartTimerV9(startTimerContext->timerId, startTimerContext->trig… in StartTimer()
297 uint64_t timerId = 0; in StopTimer() member
[all …]
/base/time/time_service/interfaces/inner_api/include/
Dtime_service_client.h148 int32_t CreateTimerV9(std::shared_ptr<ITimerInfo> timerOptions, uint64_t &timerId);
156 bool StartTimer(uint64_t timerId, uint64_t triggerTime);
157 int32_t StartTimerV9(uint64_t timerId, uint64_t triggerTime);
164 bool StopTimer(uint64_t timerId);
165 int32_t StopTimerV9(uint64_t timerId);
172 bool DestroyTimer(uint64_t timerId);
173 int32_t DestroyTimerV9(uint64_t timerId);
/base/time/time_service/interfaces/inner_api/src/
Dtime_service_client.cpp166 uint64_t timerId = 0; in CreateTimer() local
167 auto errCode = CreateTimerV9(TimerOptions, timerId); in CreateTimer()
168 TIME_HILOGI(TIME_MODULE_SERVICE, "CreateTimer id: %{public}" PRId64 "", timerId); in CreateTimer()
173 if (timerId == 0) { in CreateTimer()
177 TIME_HILOGI(TIME_MODULE_SERVICE, "CreateTimer id: %{public}" PRId64 "", timerId); in CreateTimer()
178 return timerId; in CreateTimer()
181 …t32_t TimeServiceClient::CreateTimerV9(std::shared_ptr<ITimerInfo> timerOptions, uint64_t &timerId) in CreateTimerV9() argument
199 auto errCode = proxy->CreateTimer(timerOptions, timerCallbackInfoObject, timerId); in CreateTimerV9()
204 TIME_HILOGI(TIME_MODULE_SERVICE, "CreateTimer id: %{public}" PRId64 "", timerId); in CreateTimerV9()
205 auto ret = TimerCallback::GetInstance()->InsertTimerCallbackInfo(timerId, timerOptions); in CreateTimerV9()
[all …]
/base/powermgr/powermgr_lite/utils/src/
Dpower_mgr_timer_util.c29 PowerTimer timerId; member
39 return GET_OBJECT(timer, PowerTimerInfo, timerId); in GetPowerTimerInfo()
92 int32_t ret = timer_create(CLOCK_REALTIME, &evp, &info->timerId); in PowerMgrCreateTimer()
98 POWER_HILOGD("Succeed to create timer, id: %p", info->timerId); in PowerMgrCreateTimer()
100 return &info->timerId; in PowerMgrCreateTimer()
126 return StartTimer(info->timerId, info->whenMsec, info->intervalMsec); in PowerMgrStartTimer()
148 return StartTimer(info->timerId, 0, 0); in PowerMgrStopTimer()
159 int32_t ret = timer_delete(info->timerId); in PowerMgrDestroyTimer()
/base/time/time_service/services/timer/include/
Dtimer_manager_interface.h56 int uid, uint64_t &timerId) = 0;
58 virtual int32_t StartTimer(uint64_t timerId, uint64_t triggerTime) = 0;
59 virtual int32_t StopTimer(uint64_t timerId) = 0;
60 virtual int32_t DestroyTimer(uint64_t timerId) = 0;
Dtimer_manager.h40 uint64_t &timerId) override;
41 int32_t StartTimer(uint64_t timerId, uint64_t triggerTime) override;
42 int32_t StopTimer(uint64_t timerId) override;
43 int32_t DestroyTimer(uint64_t timerId) override;
47 bool ShowTimerEntryById(int fd, uint64_t timerId);
48 bool ShowTimerTriggerById(int fd, uint64_t timerId);
/base/security/device_security_level/baselib/utils/src/
Dutils_timer.cpp58 uint32_t timerId = st.Register(std::bind(&DoTimerProcess, callback, context), interval, false); in StartPeriodicTimerTask() local
59 return static_cast<TimerHandle>(timerId); in StartPeriodicTimerTask()
65 uint32_t timerId = st.Register(std::bind(&DoTimerProcess, callback, context), interval, true); in StartOnceTimerTask() local
66 return static_cast<TimerHandle>(timerId); in StartOnceTimerTask()
/base/time/time_service/services/time/include/
Dtimer_call_back.h31 …virtual void NotifyTimer(const uint64_t timerId, const sptr<IRemoteObject> &timerCallback) overrid…
39 …bool InsertTimerCallbackInfo(const uint64_t timerId, const std::shared_ptr<ITimerInfo> &timerInfo);
40 bool RemoveTimerCallbackInfo(const uint64_t timerId);
/base/time/time_service/services/ipc/proxy/
Dtimer_notify_call_back_proxy.cpp30 void TimerNotifyCallbackProxy::Finish(const uint64_t timerId) in Finish() argument
32 TIME_HILOGD(TIME_MODULE_CLIENT, "start id:%{public}" PRId64 "", timerId); in Finish()
46 if (!data.WriteUint64(timerId)) { in Finish()
Dtime_service_proxy.h42 uint64_t &timerId) override;
43 int32_t StartTimer(uint64_t timerId, uint64_t triggerTime) override;
44 int32_t StopTimer(uint64_t timerId) override;
45 int32_t DestroyTimer(uint64_t timerId) override;
Dtimer_call_back_proxy.cpp31 void TimerCallbackProxy::NotifyTimer(const uint64_t timerId, const sptr<IRemoteObject> &timerCallba… in NotifyTimer() argument
33 TIME_HILOGD(TIME_MODULE_CLIENT, "start id: %{public}" PRId64 "", timerId); in NotifyTimer()
48 if (!data.WriteUint64(timerId)) { in NotifyTimer()
Dtime_service_proxy.cpp55 sptr<IRemoteObject> &timerCallback, uint64_t &timerId) in CreateTimer() argument
91 timerId = reply.ReadUint64(); in CreateTimer()
97 int32_t TimeServiceProxy::StartTimer(uint64_t timerId, uint64_t triggerTime) in StartTimer() argument
105 if (!data.WriteUint64(timerId)) { in StartTimer()
116 int32_t TimeServiceProxy::StopTimer(uint64_t timerId) in StopTimer() argument
124 if (!data.WriteUint64(timerId)) { in StopTimer()
131 int32_t TimeServiceProxy::DestroyTimer(uint64_t timerId) in DestroyTimer() argument
139 if (!data.WriteUint64(timerId)) { in DestroyTimer()
/base/time/time_service/services/ipc/stub/
Dtimer_notify_call_back_stub.cpp44 auto timerId = data.ReadUint64(); in OnFinishStub() local
45 TIME_HILOGD(TIME_MODULE_SERVICE, "id: %{public}" PRId64 "", timerId); in OnFinishStub()
46 Finish(timerId); in OnFinishStub()
Dtimer_call_back_stub.cpp44 auto timerId = data.ReadUint64(); in OnTriggerStub() local
45 TIME_HILOGD(TIME_MODULE_CLIENT, "id: %{public}" PRId64 "", timerId); in OnTriggerStub()
47 NotifyTimer(timerId, obj); in OnTriggerStub()
Dtime_service_stub.cpp274 uint64_t timerId = 0; in OnCreateTimer() local
275 auto errCode = CreateTimer(timerOptions, obj, timerId); in OnCreateTimer()
280 if (!reply.WriteUint64(timerId)) { in OnCreateTimer()
295 auto timerId = data.ReadUint64(); in OnStartTimer() local
297 if (StartTimer(timerId, triggerTime) != E_TIME_OK) { in OnStartTimer()
312 auto timerId = data.ReadUint64(); in OnStopTimer() local
313 if (StopTimer(timerId) != E_TIME_OK) { in OnStopTimer()
328 auto timerId = data.ReadUint64(); in OnDestroyTimer() local
329 if (DestroyTimer(timerId) != E_TIME_OK) { in OnDestroyTimer()
/base/time/time_service/services/ipc/base/
Dtime_service_interface.h148 uint64_t &timerId) = 0;
157 virtual int32_t StartTimer(uint64_t timerId, uint64_t triggerTime) = 0;
165 virtual int32_t StopTimer(uint64_t timerId) = 0;
173 virtual int32_t DestroyTimer(uint64_t timerId) = 0;
/base/useriam/user_auth_framework/services/base/src/
Drelative_timer.cpp42 void RelativeTimer::Unregister(uint32_t timerId) in Unregister() argument
44 return timer_.Unregister(timerId); in Unregister()
/base/time/time_service/services/
Dtime_system_ability.h62 uint64_t &timerId) override;
63 …2_t CreateTimer(TimerPara &paras, std::function<void(const uint64_t)> Callback, uint64_t &timerId);
64 int32_t StartTimer(uint64_t timerId, uint64_t triggerTimes) override;
65 int32_t StopTimer(uint64_t timerId) override;
66 int32_t DestroyTimer(uint64_t timerId) override;
/base/powermgr/thermal_manager/services/native/include/thermal_action/
Dthermal_timer.h56 bool StartTimer(uint64_t timerId, uint64_t triggerTime);
57 bool StopTimer(uint64_t timerId);
58 bool DestroyTimer(uint64_t timerId);
/base/useriam/user_auth_framework/services/ipc/src/
Dco_auth_service.cpp51 static uint32_t timerId = 0; in OnStart() local
59 if (timerId != 0) { in OnStart()
60 RelativeTimer::GetInstance().Unregister(timerId); in OnStart()
62 timerId = RelativeTimer::GetInstance().Register(Init, 0); in OnStart()
/base/time/time_service/services/timer/src/
Dtimer_manager.cpp76 uint64_t &timerId) in CreateTimer() argument
84 while (timerId == 0) { in CreateTimer()
85 timerId = random_(); in CreateTimer()
88 timerId, in CreateTimer()
98 timerEntryMap_.insert(std::make_pair(timerId, timerInfo)); in CreateTimer()
102 int32_t TimerManager::StartTimer(uint64_t timerId, uint64_t triggerTime) in StartTimer() argument
105 auto it = timerEntryMap_.find(timerId); in StartTimer()
107 TIME_HILOGE(TIME_MODULE_SERVICE, "Timer id not found: %{public}" PRId64 "", timerId); in StartTimer()
110 TIME_HILOGI(TIME_MODULE_SERVICE, "Start timer : %{public}" PRId64 "", timerId); in StartTimer()
125 int32_t TimerManager::StopTimer(uint64_t timerId) in StopTimer() argument
[all …]

12