1 /*
2  * Copyright (c) 2022 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 
16 #include "base/log/frame_report.h"
17 
18 namespace OHOS::Ace {
GetInstance()19 FrameReport& FrameReport::GetInstance()
20 {
21     static FrameReport instance;
22     return instance;
23 }
24 
FrameReport()25 FrameReport::FrameReport() {}
26 
~FrameReport()27 FrameReport::~FrameReport() {}
28 
LoadLibrary()29 bool FrameReport::LoadLibrary()
30 {
31     frameSchedHandle_ = nullptr;
32     frameSchedSoLoaded_ = false;
33     enable_ = false;
34     return false;
35 }
36 
CloseLibrary()37 void FrameReport::CloseLibrary() {}
38 
LoadSymbol(const char * symName)39 void* FrameReport::LoadSymbol(const char* symName)
40 {
41     return nullptr;
42 }
43 
Init()44 void FrameReport::Init()
45 {
46     frameInitFunc_ = nullptr;
47 }
48 
GetEnable()49 int FrameReport::GetEnable()
50 {
51     frameGetEnableFunc_ = nullptr;
52     return false;
53 }
54 
GetFrameReportEnable()55 int FrameReport::GetFrameReportEnable()
56 {
57     return false;
58 }
59 
BeginFlushAnimation()60 void FrameReport::BeginFlushAnimation()
61 {
62     beginFlushAnimationFunc_ = nullptr;
63 }
64 
EndFlushAnimation()65 void FrameReport::EndFlushAnimation()
66 {
67     endFlushAnimationFunc_ = nullptr;
68 }
69 
BeginFlushBuild()70 void FrameReport::BeginFlushBuild()
71 {
72     beginFlushBuildFunc_ = nullptr;
73 }
74 
EndFlushBuild()75 void FrameReport::EndFlushBuild()
76 {
77     endFlushBuildFunc_ = nullptr;
78 }
79 
BeginFlushLayout()80 void FrameReport::BeginFlushLayout()
81 {
82     beginFlushLayoutFunc_ = nullptr;
83 }
84 
EndFlushLayout()85 void FrameReport::EndFlushLayout()
86 {
87     endFlushLayoutFunc_ = nullptr;
88 }
89 
BeginFlushRender()90 void FrameReport::BeginFlushRender()
91 {
92     beginFlushRenderFunc_ = nullptr;
93 }
94 
EndFlushRender()95 void FrameReport::EndFlushRender()
96 {
97     endFlushRenderFunc_ = nullptr;
98 }
99 
BeginFlushRenderFinish()100 void FrameReport::BeginFlushRenderFinish()
101 {
102     beginFlushRenderFinishFunc_ = nullptr;
103 }
104 
EndFlushRenderFinish()105 void FrameReport::EndFlushRenderFinish()
106 {
107     endFlushRenderFinishFunc_ = nullptr;
108 }
109 
BeginProcessPostFlush()110 void FrameReport::BeginProcessPostFlush()
111 {
112     beginProcessPostFunc_ = nullptr;
113 }
114 
BeginListFling()115 void FrameReport::BeginListFling()
116 {
117     beginListFlingFunc_ = nullptr;
118 }
119 
EndListFling()120 void FrameReport::EndListFling()
121 {
122     endListFlingFunc_ = nullptr;
123 }
124 
FlushBegin()125 void FrameReport::FlushBegin()
126 {
127     flushBeginFunc_ = nullptr;
128 }
129 
FlushEnd()130 void FrameReport::FlushEnd()
131 {
132     flushEndFunc_ = nullptr;
133 }
134 
SetFrameParam(int requestId,int load,int schedFrameNum,int value)135 void FrameReport::SetFrameParam(int requestId, int load, int schedFrameNum, int value)
136 {
137     setFrameParamFunc_ = nullptr;
138 }
139 
EnableSelfRender()140 void FrameReport::EnableSelfRender()
141 {
142     enableSelfRenderFunc_ = nullptr;
143 }
144 
DisableSelfRender()145 void FrameReport::DisableSelfRender()
146 {
147     disableSelfRenderFunc_ = nullptr;
148 }
149 } // namespace OHOS::Ace
150