/base/powermgr/battery_statistics/test/unittest/src/servicetest/utils/ |
D | hisysevent_operation.cpp | 26 bool HiSysEventOperation::IsError(HiSysEventOperation::EventBase &eventBase) in IsError() argument 28 return (eventBase.retCode_ < SUCCESS); in IsError() 31 void HiSysEventOperation::ExplainRetCode(HiSysEventOperation::EventBase &eventBase) in ExplainRetCode() argument 33 if (eventBase.retCode_ > SUCCESS) { in ExplainRetCode() 35 eventBase.retCode_, ERR_MSG_LEVEL1[eventBase.retCode_ - 1]); in ExplainRetCode() 36 } else if (eventBase.retCode_ < SUCCESS) { in ExplainRetCode() 38 eventBase.retCode_, ERR_MSG_LEVEL0[-eventBase.retCode_ - 1]); in ExplainRetCode() 50 bool HiSysEventOperation::IsWarnAndUpdate(int retCode, EventBase &eventBase) in IsWarnAndUpdate() argument 53 eventBase.retCode_ = retCode; in IsWarnAndUpdate() 59 bool HiSysEventOperation::UpdateAndCheckKeyNumIsOver(HiSysEventOperation::EventBase &eventBase) in UpdateAndCheckKeyNumIsOver() argument [all …]
|
/base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/include/ |
D | inner_writer.h | 62 EventBase eventBase(domain, eventName, type); in InnerWrite() 63 WritebaseInfo(eventBase); in InnerWrite() 64 if (IsError(eventBase)) { in InnerWrite() 65 ExplainRetCode(eventBase); in InnerWrite() 66 return eventBase.GetRetCode(); in InnerWrite() 69 InnerWrite(eventBase, keyValues...); in InnerWrite() 70 if (IsError(eventBase)) { in InnerWrite() 71 ExplainRetCode(eventBase); in InnerWrite() 72 return eventBase.GetRetCode(); in InnerWrite() 75 SendSysEvent(eventBase); in InnerWrite() [all …]
|
D | hisysevent.h | 259 EventBase eventBase(domain, eventName, type); 260 eventBase.jsonStr_ << "{"; 261 WritebaseInfo(eventBase); 262 if (IsError(eventBase)) { 263 ExplainRetCode(eventBase); 264 return eventBase.retCode_; 267 InnerWrite(eventBase, keyValues...); 268 if (IsError(eventBase)) { 269 ExplainRetCode(eventBase); 270 return eventBase.retCode_; [all …]
|
/base/powermgr/battery_statistics/test/unittest/include/servicetest/utils/ |
D | hisysevent_operation.h | 55 EventBase eventBase(domain, eventName, type); in InnerCombine() 56 eventBase.jsonStr_ << "{"; in InnerCombine() 57 CombineBaseInfo(eventBase); in InnerCombine() 58 if (IsError(eventBase)) { in InnerCombine() 59 ExplainRetCode(eventBase); in InnerCombine() 60 return eventBase.jsonStr_.str(); in InnerCombine() 63 InnerCombine(eventBase, keyValues...); in InnerCombine() 64 if (IsError(eventBase)) { in InnerCombine() 65 ExplainRetCode(eventBase); in InnerCombine() 66 return eventBase.jsonStr_.str(); in InnerCombine() [all …]
|
/base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent/ |
D | hisysevent.cpp | 109 void HiSysEvent::ExplainRetCode(HiSysEvent::EventBase &eventBase) in ExplainRetCode() argument 111 if (eventBase.retCode_ > SUCCESS) { in ExplainRetCode() 113 eventBase.retCode_, ERR_MSG_LEVEL1[eventBase.retCode_ - 1]); in ExplainRetCode() 114 } else if (eventBase.retCode_ < SUCCESS) { in ExplainRetCode() 116 eventBase.retCode_, ERR_MSG_LEVEL0[-eventBase.retCode_ - 1]); in ExplainRetCode() 120 bool HiSysEvent::IsError(HiSysEvent::EventBase &eventBase) in IsError() argument 122 return (eventBase.retCode_ < SUCCESS); in IsError() 125 bool HiSysEvent::IsErrorAndUpdate(int retCode, HiSysEvent::EventBase &eventBase) in IsErrorAndUpdate() argument 128 eventBase.retCode_ = retCode; in IsErrorAndUpdate() 134 bool HiSysEvent::IsWarnAndUpdate(int retCode, EventBase &eventBase) in IsWarnAndUpdate() argument [all …]
|
D | inner_writer.cpp | 118 void InnerWriter::ExplainRetCode(EventBase& eventBase) in ExplainRetCode() argument 120 auto retCode = eventBase.GetRetCode(); in ExplainRetCode() 130 bool InnerWriter::IsError(EventBase& eventBase) in IsError() argument 132 return (eventBase.GetRetCode() < SUCCESS); in IsError() 135 bool InnerWriter::IsErrorAndUpdate(int retCode, EventBase& eventBase) in IsErrorAndUpdate() argument 138 eventBase.SetRetCode(retCode); in IsErrorAndUpdate() 144 bool InnerWriter::IsWarnAndUpdate(int retCode, EventBase& eventBase) in IsWarnAndUpdate() argument 147 eventBase.SetRetCode(retCode); in IsWarnAndUpdate() 153 bool InnerWriter::UpdateAndCheckKeyNumIsOver(EventBase& eventBase) in UpdateAndCheckKeyNumIsOver() argument 155 if (eventBase.GetParamCnt() >= MAX_PARAM_NUMBER) { in UpdateAndCheckKeyNumIsOver() [all …]
|
/base/hiviewdfx/hisysevent/interfaces/js/kits/napi/src/ |
D | napi_hisysevent_adapter.cpp | 183 void NapiHiSysEventAdapter::InnerWrite(InnerWriter::EventBase& eventBase, in InnerWrite() argument 186 AppendParams(eventBase, eventInfo.boolParams); in InnerWrite() 187 AppendParams(eventBase, eventInfo.boolArrayParams); in InnerWrite() 188 AppendParams(eventBase, eventInfo.doubleParams); in InnerWrite() 189 AppendParams(eventBase, eventInfo.doubleArrayParams); in InnerWrite() 190 AppendParams(eventBase, eventInfo.stringParams); in InnerWrite() 191 AppendParams(eventBase, eventInfo.stringArrayParams); in InnerWrite() 196 InnerWriter::EventBase eventBase(eventInfo.domain, eventInfo.name, eventInfo.eventType); in Write() local 197 InnerWriter::WritebaseInfo(eventBase); in Write() 198 if (InnerWriter::IsError(eventBase)) { in Write() [all …]
|
/base/hiviewdfx/hisysevent/interfaces/js/kits/napi/include/ |
D | napi_hisysevent_adapter.h | 63 static void InnerWrite(InnerWriter::EventBase& eventBase, const HiSysEventInfo& eventInfo); 68 …static void AppendParams(InnerWriter::EventBase& eventBase, const std::unordered_map<std::string, … in AppendParams() argument 71 InnerWriter::InnerWrite(eventBase, iter->first, iter->second); in AppendParams()
|