Home
last modified time | relevance | path

Searched refs:listenerPtr_ (Results 1 – 14 of 14) sorted by relevance

/base/powermgr/battery_statistics/test/unittest/include/servicetest/utils/
Dstats_service_write_event.h33 if (service->listenerPtr_ != nullptr) { in StatsWriteHiSysEvent()
34 service->listenerPtr_->OnEvent(sysEvent); in StatsWriteHiSysEvent()
/base/powermgr/battery_statistics/services/native/src/
Dbattery_stats_service.cpp84 HiviewDFX::HiSysEventManager::RemoveListener(listenerPtr_); in OnStop()
158 if (!listenerPtr_) { in AddHiSysEventListener()
160 listenerPtr_ = std::make_shared<BatteryStatsListener>(); in AddHiSysEventListener()
167 auto res = HiviewDFX::HiSysEventManager::AddListener(listenerPtr_, sysRules); in AddHiSysEventListener()
/base/powermgr/battery_statistics/test/unittest/src/servicetest/
Dstats_service_alarm_test.cpp44 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
45 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
55 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_subscriber_test.cpp52 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
53 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
69 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_audio_test.cpp44 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
45 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
55 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_dump_test.cpp49 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
50 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
61 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_powermgr_test.cpp47 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
48 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
58 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_location_test.cpp44 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
45 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
55 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_display_test.cpp68 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
69 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
82 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_wifi_test.cpp45 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
46 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
56 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_camera_test.cpp44 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
45 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
55 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_phone_test.cpp46 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
47 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
57 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
Dstats_service_bluetooth_test.cpp86 if (g_statsService->listenerPtr_ == nullptr) { in SetUpTestCase()
87 g_statsService->listenerPtr_ = std::make_shared<BatteryStatsListener>(); in SetUpTestCase()
97 g_statsService->listenerPtr_ = nullptr; in TearDownTestCase()
/base/powermgr/battery_statistics/services/native/include/
Dbattery_stats_service.h70 std::shared_ptr<HiviewDFX::HiSysEventListener> listenerPtr_; variable