• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 /*
2  * Copyright (c) 2024 Huawei Device Co., Ltd.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at
6  *
7  *     http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 #include "event_loop.h"
16 #include "event_publish.h"
17 #include "sys_event.h"
18 #include "audit.h"
19 #include "event.h"
20 #include "hiview_event_report.h"
21 #include "base/raw_data_base_def.h"
22 
23 namespace OHOS {
24 namespace HiviewDFX {
25 namespace EventRaw {
IsBaseInfo(const std::string & key)26 bool RawDataBuilder::IsBaseInfo(const std::string& key)
27 {
28     return true;
29 }
30 
GetValue(const std::string & key)31 std::shared_ptr<EncodedParam> RawDataBuilder::GetValue(const std::string& key)
32 {
33     return nullptr;
34 }
35 
ParseTimeZone(const std::string & tzStr)36 int ParseTimeZone(const std::string& tzStr)
37 {
38     return 0;
39 }
40 } // namespace EventRaw
41 
UpdatePluginStats(const std::string & name,const std::string & procName,uint32_t procTime)42 void HiviewEventReport::UpdatePluginStats(const std::string &name, const std::string &procName, uint32_t procTime)
43 {
44 }
45 
IsEnabled()46 bool Audit::IsEnabled()
47 {
48     return true;
49 }
50 
~Audit()51 Audit::~Audit()
52 {
53     enabled_ = false;
54 }
55 
WriteAuditEvent(StatsEvent eventType,uint64_t eventId,const std::string & digest)56 bool Audit::WriteAuditEvent(StatsEvent eventType, uint64_t eventId, const std::string& digest)
57 {
58     return true;
59 }
60 
AddTimerEvent(std::shared_ptr<EventHandler> handler,std::shared_ptr<Event> event,const Task & task,uint64_t interval,bool repeat)61 uint64_t EventLoop::AddTimerEvent(std::shared_ptr<EventHandler> handler, std::shared_ptr<Event> event,
62     const Task &task, uint64_t interval, bool repeat)
63 {
64     return 0;
65 }
66 
ResetTimestamp()67 void Event::ResetTimestamp()
68 {
69 }
70 
GetEventIntValue(const std::string & key)71 int64_t SysEvent::GetEventIntValue(const std::string& key)
72 {
73     return 0;
74 }
75 
GetUid() const76 int32_t SysEvent::GetUid() const
77 {
78     return 0;
79 }
80 
GetPid() const81 int32_t SysEvent::GetPid() const
82 {
83     return 0;
84 }
85 
GetEventValue(const std::string & key)86 std::string SysEvent::GetEventValue(const std::string& key)
87 {
88     return nullptr;
89 }
90 
PushEvent(int32_t uid,const std::string & eventName,HiSysEvent::EventType eventType,const std::string & paramJson)91 void EventPublish::PushEvent(int32_t uid, const std::string& eventName, HiSysEvent::EventType eventType,
92     const std::string& paramJson)
93 {
94 }
95 
RemoveEvent(uint64_t seq)96 bool EventLoop::RemoveEvent(uint64_t seq)
97 {
98     return true;
99 }
100 } // namespace HiviewDFX
101 } // namespace OHOS