Home
last modified time | relevance | path

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

12345678910>>...17

/base/notification/common_event_service/interfaces/kits/napi/support/src/
Dsupport.cpp35 …env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_BOOT_COMPLETED, "COMMON_EVENT_BOOT_COMPLETED"… in SupportInit()
38 EventFwk::CommonEventSupport::COMMON_EVENT_LOCKED_BOOT_COMPLETED, in SupportInit()
40 …SetNamedPropertyByStr(env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_SHUTDOWN, "COMMON_EVENT… in SupportInit()
42 …env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_BATTERY_CHANGED, "COMMON_EVENT_BATTERY_CHANGE… in SupportInit()
43 …SetNamedPropertyByStr(env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_BATTERY_LOW, "COMMON_EV… in SupportInit()
45 … env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_BATTERY_OKAY, "COMMON_EVENT_BATTERY_OKAY"); in SupportInit()
47 …env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_POWER_CONNECTED, "COMMON_EVENT_POWER_CONNECTE… in SupportInit()
49 …env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_POWER_DISCONNECTED, "COMMON_EVENT_POWER_DISCO… in SupportInit()
50 …SetNamedPropertyByStr(env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_SCREEN_OFF, "COMMON_EVE… in SupportInit()
51 …SetNamedPropertyByStr(env, obj, EventFwk::CommonEventSupport::COMMON_EVENT_SCREEN_ON, "COMMON_EVEN… in SupportInit()
[all …]
/base/notification/distributed_notification_service/services/ans/src/
Dsystem_event_observer.cpp29 EventFwk::MatchingSkills matchingSkills; in SystemEventObserver()
30 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED); in SystemEventObserver()
32 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_SCREEN_ON); in SystemEventObserver()
33 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_SCREEN_OFF); in SystemEventObserver()
35 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_USER_SWITCHED); in SystemEventObserver()
36 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED); in SystemEventObserver()
37 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_DATA_CLEARED); in SystemEventObserver()
38 EventFwk::CommonEventSubscribeInfo commonEventSubscribeInfo(matchingSkills); in SystemEventObserver()
39 commonEventSubscribeInfo.SetThreadMode(EventFwk::CommonEventSubscribeInfo::COMMON); in SystemEventObserver()
44 EventFwk::CommonEventManager::SubscribeCommonEvent(subscriber_); in SystemEventObserver()
[all …]
/base/notification/distributed_notification_service/services/ans/test/unittest/
Dsystem_event_observer_test.cpp65 EventFwk::Want want;
66 EventFwk::CommonEventData data;
67 data.SetWant(want.SetAction(EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED));
79 EventFwk::Want want;
80 EventFwk::CommonEventData data;
81 data.SetWant(want.SetAction(EventFwk::CommonEventSupport::COMMON_EVENT_USER_SWITCHED));
92 EventFwk::Want want;
93 EventFwk::CommonEventData data;
94 data.SetWant(want.SetAction(EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED));
105 EventFwk::Want want;
[all …]
/base/theme/wallpaper_mgr/services/src/
Dwallpaper_common_event_subscriber.cpp24 void WallpaperCommonEventSubscriber::OnReceiveEvent(const OHOS::EventFwk::CommonEventData &data) in OnReceiveEvent()
29 if (action == EventFwk::CommonEventSupport::COMMON_EVENT_BOOT_COMPLETED) { in OnReceiveEvent()
31 } else if (action == EventFwk::CommonEventSupport::COMMON_EVENT_USER_ADDED) { in OnReceiveEvent()
33 } else if (action == EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED) { in OnReceiveEvent()
35 } else if (action == EventFwk::CommonEventSupport::COMMON_EVENT_USER_SWITCHED) { in OnReceiveEvent()
42 OHOS::EventFwk::MatchingSkills matchingSkills; in CreateSubscriberInfo()
43 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_BOOT_COMPLETED); in CreateSubscriberInfo()
44 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_USER_ADDED); in CreateSubscriberInfo()
45 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED); in CreateSubscriberInfo()
46 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_USER_SWITCHED); in CreateSubscriberInfo()
/base/security/certificate_manager/services/cert_manager_standard/cert_manager_service/main/os_dependency/sa/
Dcm_event_observer.cpp32 SystemEventSubscriber::SystemEventSubscriber(const OHOS::EventFwk::CommonEventSubscribeInfo &subscr… in SystemEventSubscriber()
33 : OHOS::EventFwk::CommonEventSubscriber(subscriberInfo) in SystemEventSubscriber()
37 void SystemEventSubscriber::OnReceiveEvent(const OHOS::EventFwk::CommonEventData &data) in OnReceiveEvent()
45 if (action == OHOS::EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED || in OnReceiveEvent()
46 action == OHOS::EventFwk::CommonEventSupport::COMMON_EVENT_SANDBOX_PACKAGE_REMOVED) { in OnReceiveEvent()
53 } else if (action == OHOS::EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED) { in OnReceiveEvent()
69 OHOS::EventFwk::MatchingSkills matchingSkills; in SubscribeSystemEvent()
70 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED); in SubscribeSystemEvent()
71 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_SANDBOX_PACKAGE_REMOVED); in SubscribeSystemEvent()
72 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED); in SubscribeSystemEvent()
[all …]
/base/account/os_account/services/accountmgr/src/
Daccount_event_subscribe.cpp32 …const EventFwk::CommonEventSubscribeInfo &subscribeInfo, const AccountCommonEventCallback &callbac… in AccountEventSubscriberCallback()
36 void AccountEventSubscriberCallback::OnReceiveEvent(const EventFwk::CommonEventData &data) in OnReceiveEvent()
40 if (action == EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED) { in OnReceiveEvent()
48 EventFwk::MatchingSkills matchingSkills; in AccountEventSubscriber()
49 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED); in AccountEventSubscriber()
50 EventFwk::CommonEventSubscribeInfo subscribeInfo(matchingSkills); in AccountEventSubscriber()
56 return EventFwk::CommonEventManager::SubscribeCommonEvent(subscriber_); in CreateEventSubscribe()
61 return EventFwk::CommonEventManager::UnSubscribeCommonEvent(subscriber_); in DestroyEventSubscribe()
/base/notification/distributed_notification_service/services/ans/include/
Dsystem_event_subscriber.h25 class SystemEventSubscriber : public EventFwk::CommonEventSubscriber {
33 SystemEventSubscriber(const EventFwk::CommonEventSubscribeInfo &subscribeInfo, in SystemEventSubscriber()
34 const std::function<void(const EventFwk::CommonEventData &)> &callback) in SystemEventSubscriber()
35 : EventFwk::CommonEventSubscriber(subscribeInfo), callback_(callback) in SystemEventSubscriber()
49 void OnReceiveEvent(const EventFwk::CommonEventData &data) override in OnReceiveEvent()
57 std::function<void(const EventFwk::CommonEventData &)> callback_;
Dreminder_event_manager.h37 class ReminderEventSubscriber : public EventFwk::CommonEventSubscriber {
39 ReminderEventSubscriber(const EventFwk::CommonEventSubscribeInfo &subscriberInfo,
41 virtual void OnReceiveEvent(const EventFwk::CommonEventData &data);
44 sptr<NotificationBundleOption> GetBundleOption(const OHOS::EventFwk::Want &want) const;
45 void HandlePackageRemove(const EventFwk::Want &want) const;
46 void HandleProcessDied(const EventFwk::Want &want) const;
50 class ReminderEventCustomSubscriber : public EventFwk::CommonEventSubscriber {
52 ReminderEventCustomSubscriber(const EventFwk::CommonEventSubscribeInfo &subscriberInfo,
54 virtual void OnReceiveEvent(const EventFwk::CommonEventData &data);
/base/telephony/call_manager/services/call/include/
Dcall_broadcast_subscriber.h29 class CallBroadcastSubscriber : public EventFwk::CommonEventSubscriber {
31 explicit CallBroadcastSubscriber(const EventFwk::CommonEventSubscribeInfo &subscriberInfo);
33 virtual void OnReceiveEvent(const EventFwk::CommonEventData &data);
40 …using broadcastSubscriberFunc = void (CallBroadcastSubscriber::*)(const EventFwk::CommonEventData …
42 void UnknownBroadcast(const EventFwk::CommonEventData &data);
43 void SimStateBroadcast(const EventFwk::CommonEventData &data);
/base/theme/wallpaper_mgr/services/include/
Dwallpaper_common_event_subscriber.h26 using CommonEventSubscriber = OHOS::EventFwk::CommonEventSubscriber;
27 using CommonEventData = OHOS::EventFwk::CommonEventData;
28 using CommonEventSubscribeInfo = OHOS::EventFwk::CommonEventSubscribeInfo;
31 class WallpaperCommonEventSubscriber : public OHOS::EventFwk::CommonEventSubscriber {
39 void OnReceiveEvent(const OHOS::EventFwk::CommonEventData &data) override;
42 OHOS::EventFwk::CommonEventSubscribeInfo CreateSubscriberInfo();
/base/telephony/call_manager/services/call/src/
Dcall_broadcast_subscriber.cpp25 using namespace OHOS::EventFwk;
26 CallBroadcastSubscriber::CallBroadcastSubscriber(const OHOS::EventFwk::CommonEventSubscribeInfo &su… in CallBroadcastSubscriber()
33 void CallBroadcastSubscriber::OnReceiveEvent(const EventFwk::CommonEventData &data) in OnReceiveEvent()
36 OHOS::EventFwk::Want want = data.GetWant(); in OnReceiveEvent()
39 if (action == EventFwk::CommonEventSupport::COMMON_EVENT_SIM_STATE_CHANGED) { in OnReceiveEvent()
53 void CallBroadcastSubscriber::UnknownBroadcast(const EventFwk::CommonEventData &data) in UnknownBroadcast()
58 void CallBroadcastSubscriber::SimStateBroadcast(const EventFwk::CommonEventData &data) in SimStateBroadcast()
/base/telephony/sms_mms/test/unittest/
Dsms_broadcast_subscriber.h26 class SmsBroadcastSubscriber : public EventFwk::CommonEventSubscriber {
28 explicit SmsBroadcastSubscriber(const OHOS::EventFwk::CommonEventSubscribeInfo &subscriberInfo);
30 virtual void OnReceiveEvent(const OHOS::EventFwk::CommonEventData &data);
32 void CbMessageTest(const OHOS::EventFwk::Want &want) const;
33 void WapPushMessageTest(const OHOS::EventFwk::Want &want) const;
/base/web/webview/ohos_adapter/battery_mgr_adapter/src/
Dbattery_mgr_client_adapter_impl.cpp43 NWebBatteryEventSubscriber::NWebBatteryEventSubscriber(EventFwk::CommonEventSubscribeInfo& in, Batt… in NWebBatteryEventSubscriber()
44 : EventFwk::CommonEventSubscriber(in), eventCallback_(cb) {} in NWebBatteryEventSubscriber()
46 void NWebBatteryEventSubscriber::OnReceiveEvent(const EventFwk::CommonEventData &data) in OnReceiveEvent()
50 if (action != EventFwk::CommonEventSupport::COMMON_EVENT_BATTERY_CHANGED) { in OnReceiveEvent()
79 EventFwk::MatchingSkills skill = EventFwk::MatchingSkills(); in StartListen()
80 skill.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_BATTERY_CHANGED); in StartListen()
81 EventFwk::CommonEventSubscribeInfo info(skill); in StartListen()
83 bool ret = EventFwk::CommonEventManager::SubscribeCommonEvent(this->commonEventSubscriber_); in StartListen()
96 … bool result = EventFwk::CommonEventManager::UnSubscribeCommonEvent(this->commonEventSubscriber_); in StopListen()
/base/security/huks/services/huks_standard/huks_service/main/os_dependency/sa/
Dhks_event_observer.cpp90 SystemEventSubscriber::SystemEventSubscriber(const OHOS::EventFwk::CommonEventSubscribeInfo &subscr… in SystemEventSubscriber()
91 : OHOS::EventFwk::CommonEventSubscriber(subscriberInfo) in SystemEventSubscriber()
94 void SystemEventSubscriber::OnReceiveEvent(const OHOS::EventFwk::CommonEventData &data) in OnReceiveEvent()
100 if (action == OHOS::EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED || in OnReceiveEvent()
101 action == OHOS::EventFwk::CommonEventSupport::COMMON_EVENT_SANDBOX_PACKAGE_REMOVED) { in OnReceiveEvent()
113 } else if (action == OHOS::EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED) { in OnReceiveEvent()
134 OHOS::EventFwk::MatchingSkills matchingSkills; in SubscribeSystemEvent()
135 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_PACKAGE_REMOVED); in SubscribeSystemEvent()
136 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_SANDBOX_PACKAGE_REMOVED); in SubscribeSystemEvent()
137 matchingSkills.AddEvent(EventFwk::CommonEventSupport::COMMON_EVENT_USER_REMOVED); in SubscribeSystemEvent()
[all …]
/base/telephony/call_manager/test/unittest/ui_client/
Dcommon_event_subscriber_test.cpp24 using namespace OHOS::EventFwk;
27 CommonEventSubscriberTest::CommonEventSubscriberTest(const OHOS::EventFwk::CommonEventSubscribeInfo… in CommonEventSubscriberTest()
31 void CommonEventSubscriberTest::OnReceiveEvent(const OHOS::EventFwk::CommonEventData &data) in OnReceiveEvent()
33 OHOS::EventFwk::Want want = data.GetWant(); in OnReceiveEvent()
35 if (action == EventFwk::CommonEventSupport::COMMON_EVENT_INCOMING_CALL_MISSED) { in OnReceiveEvent()
/base/powermgr/thermal_manager/services/native/include/thermal_observer/
Dthermal_common_event_receiver.h28 using Ces = OHOS::EventFwk::CommonEventSubscriber;
29 using CesInfo = OHOS::EventFwk::CommonEventSubscribeInfo;
30 using EventHandle = std::function<void(const OHOS::EventFwk::CommonEventData &data)>;
48 void OnReceiveEvent(const EventFwk::CommonEventData &data) override in OnReceiveEvent()
54 void HandleEvent(const OHOS::EventFwk::CommonEventData &data);
62 void HandleEventChanged(const OHOS::EventFwk::CommonEventData &data) const;
63 void HandleBatteryChargerCompleted(const OHOS::EventFwk::CommonEventData &data) const;
/base/powermgr/battery_statistics/services/native/include/
Dbattery_stats_subscriber.h25 class BatteryStatsSubscriber : public EventFwk::CommonEventSubscriber {
27 explicit BatteryStatsSubscriber(const EventFwk::CommonEventSubscribeInfo& subscribeInfo) in BatteryStatsSubscriber()
28 : EventFwk::CommonEventSubscriber(subscribeInfo) {} in BatteryStatsSubscriber()
30 void OnReceiveEvent(const EventFwk::CommonEventData &data) override;
/base/inputmethod/imf/services/include/
Dim_common_event_manager.h46 class EventSubscriber : public EventFwk::CommonEventSubscriber {
48 EventSubscriber(const EventFwk::CommonEventSubscribeInfo &subscribeInfo);
49 void OnReceiveEvent(const EventFwk::CommonEventData &data);
50 void RemovePackage(const EventFwk::CommonEventData &data);
51 void StartUser(const EventFwk::CommonEventData &data);
52 void RemoveUser(const EventFwk::CommonEventData &data);
55 using EventListenerFunc = void (EventSubscriber::*)(const EventFwk::CommonEventData &data);
/base/notification/common_event_service/test/fuzztest/publishcommonevent_fuzzer/
Dpublishcommonevent_fuzzer.cpp28 want.SetAction(EventFwk::CommonEventSupport::COMMON_EVENT_TEST_ACTION1); in DoSomethingInterestingWithMyAPI()
29 EventFwk::CommonEventData commonEventData; in DoSomethingInterestingWithMyAPI()
36 EventFwk::CommonEventPublishInfo commonEventPublishInfo; in DoSomethingInterestingWithMyAPI()
41 std::shared_ptr<EventFwk::CommonEventSubscriber> subscriber = nullptr; in DoSomethingInterestingWithMyAPI()
44 EventFwk::CommonEventManager::PublishCommonEvent(commonEventData, commonEventPublishInfo); in DoSomethingInterestingWithMyAPI()
47 return EventFwk::CommonEventManager::PublishCommonEvent( in DoSomethingInterestingWithMyAPI()
51 return EventFwk::CommonEventManager::PublishCommonEvent( in DoSomethingInterestingWithMyAPI()
/base/hiviewdfx/hidumper/services/native/include/
Ddump_battery_stats_subscriber.h25 class DumpBatteryStatsSubscriber : public EventFwk::CommonEventSubscriber {
27 explicit DumpBatteryStatsSubscriber(const EventFwk::CommonEventSubscribeInfo& subscribeInfo) in DumpBatteryStatsSubscriber()
28 : EventFwk::CommonEventSubscriber(subscribeInfo) {} in DumpBatteryStatsSubscriber()
30 void OnReceiveEvent(const EventFwk::CommonEventData &data) override;
/base/notification/common_event_service/test/fuzztest/subscribecommonevent_fuzzer/
Dsubscribecommonevent_fuzzer.cpp27 namespace EventFwk { namespace
47 EventFwk::MatchingSkills matchingSkills; in DoSomethingInterestingWithMyAPI()
54 EventFwk::CommonEventSubscribeInfo::ThreadMode threadMode = in DoSomethingInterestingWithMyAPI()
55 EventFwk::CommonEventSubscribeInfo::ThreadMode(mode); in DoSomethingInterestingWithMyAPI()
56 EventFwk::CommonEventSubscribeInfo subscribeInfo(matchingSkills); in DoSomethingInterestingWithMyAPI()
72 std::shared_ptr<EventFwk::TestSubscriber> subscriber = in DoSomethingInterestingWithMyAPI()
73 std::make_shared<EventFwk::TestSubscriber>(subscribeInfo); in DoSomethingInterestingWithMyAPI()
78 return EventFwk::CommonEventManager::SubscribeCommonEvent(subscriber); in DoSomethingInterestingWithMyAPI()
/base/notification/common_event_service/test/fuzztest/publishcommoneventasuser_fuzzer/
Dpublishcommoneventasuser_fuzzer.cpp29 want.SetAction(EventFwk::CommonEventSupport::COMMON_EVENT_TEST_ACTION1); in DoSomethingInterestingWithMyAPI()
30 EventFwk::CommonEventData commonEventData; in DoSomethingInterestingWithMyAPI()
37 EventFwk::CommonEventPublishInfo commonEventPublishInfo; in DoSomethingInterestingWithMyAPI()
42 std::shared_ptr<EventFwk::CommonEventSubscriber> subscriber = nullptr; in DoSomethingInterestingWithMyAPI()
47 EventFwk::CommonEventManager::PublishCommonEventAsUser(commonEventData, userId); in DoSomethingInterestingWithMyAPI()
50 return EventFwk::CommonEventManager::PublishCommonEventAsUser( in DoSomethingInterestingWithMyAPI()
54 return EventFwk::CommonEventManager::PublishCommonEventAsUser( in DoSomethingInterestingWithMyAPI()
/base/notification/common_event_service/test/fuzztest/unsubscribecommonevent_fuzzer/
Dunsubscribecommonevent_fuzzer.cpp21 namespace EventFwk { namespace
41 EventFwk::MatchingSkills matchingSkills; in DoSomethingInterestingWithMyAPI()
46 EventFwk::CommonEventSubscribeInfo subscribeInfo(matchingSkills); in DoSomethingInterestingWithMyAPI()
52 std::shared_ptr<EventFwk::TestSubscriber> subscriber = in DoSomethingInterestingWithMyAPI()
53 std::make_shared<EventFwk::TestSubscriber>(subscribeInfo); in DoSomethingInterestingWithMyAPI()
54 return EventFwk::CommonEventManager::UnSubscribeCommonEvent(subscriber); in DoSomethingInterestingWithMyAPI()
/base/notification/common_event_service/test/fuzztest/commoneventsubscriber_fuzzer/
Dcommoneventsubscriber_fuzzer.cpp22 namespace EventFwk { namespace
45 EventFwk::CommonEvent commonEvent; in DoSomethingInterestingWithMyAPI()
48 EventFwk::CommonEventData commonEventData(want); in DoSomethingInterestingWithMyAPI()
52 EventFwk::CommonEventPublishInfo commonEventPublishInfo; in DoSomethingInterestingWithMyAPI()
61 EventFwk::MatchingSkills matchingSkills; in DoSomethingInterestingWithMyAPI()
64 EventFwk::CommonEventSubscribeInfo subscribeInfo(matchingSkills); in DoSomethingInterestingWithMyAPI()
66 std::shared_ptr<EventFwk::TestSubscriber> subscriber = in DoSomethingInterestingWithMyAPI()
67 std::make_shared<EventFwk::TestSubscriber>(subscribeInfo); in DoSomethingInterestingWithMyAPI()
/base/account/os_account/services/accountmgr/include/appaccount/
Dapp_account_common_event_subscriber.h26 using CommonEventSubscriber = OHOS::EventFwk::CommonEventSubscriber;
27 using CommonEventData = OHOS::EventFwk::CommonEventData;
28 using CommonEventSubscribeInfo = OHOS::EventFwk::CommonEventSubscribeInfo;
39 std::function<void(const EventFwk::CommonEventData &)> callback_;

12345678910>>...17