Home
last modified time | relevance | path

Searched refs:cond (Results 1 – 25 of 52) sorted by relevance

123

/base/sensors/miscdevice/utils/include/
Dsensors_errors.h110 #define CHKPL(cond, ...) \ argument
112 if ((cond) == nullptr) { \
114 __FILE__, __LINE__, #cond); \
118 #define CHKPV(cond) \ argument
120 if ((cond) == nullptr) { \
122 __FILE__, __LINE__, #cond); \
127 #define CHKPF(cond) \ argument
129 if ((cond) == nullptr) { \
131 __FILE__, __LINE__, #cond); \
136 #define CHKPC(cond) \ argument
[all …]
/base/sensors/sensor/utils/include/
Dsensors_errors.h140 #define CHKPL(cond, ...) \ argument
142 if ((cond) == nullptr) { \
144 __FILE__, __LINE__, #cond); \
148 #define CHKPV(cond) \ argument
150 if ((cond) == nullptr) { \
152 __FILE__, __LINE__, #cond); \
157 #define CHKPF(cond) \ argument
159 if ((cond) == nullptr) { \
161 __FILE__, __LINE__, #cond); \
166 #define CHKPC(cond) \ argument
[all …]
/base/hiviewdfx/hiview/base/event_store/
Dsys_event_query.cpp203 Cond &Cond::And(const Cond &cond) in And() argument
205 andConds_.emplace_back(cond); in And()
251 Cond &Cond::Or(const Cond &cond) in Or() argument
253 orConds_.emplace_back(cond); in Or()
257 void Cond::GetCondEqualValue(DataQuery &dataQuery, Cond &cond) in GetCondEqualValue() argument
259 if (cond.fieldValue_.IsInteger()) { in GetCondEqualValue()
260 dataQuery.EqualTo(cond.col_, cond.fieldValue_.GetInteger()); in GetCondEqualValue()
263 if (cond.fieldValue_.IsFloat()) { in GetCondEqualValue()
264 dataQuery.EqualTo(cond.col_, cond.fieldValue_.GetFloat()); in GetCondEqualValue()
267 if (cond.fieldValue_.IsDouble()) { in GetCondEqualValue()
[all …]
/base/useriam/user_auth_framework/common/utils/
Diam_check.h25 #define IF_FALSE_LOGE_AND_RETURN(cond) \ argument
27 if (!(cond)) { \
28 IAM_LOGE("(" #cond ") check fail, return"); \
33 #define IF_FALSE_LOGE_AND_RETURN_VAL(cond, retVal) \ argument
35 if (!(cond)) { \
36 IAM_LOGE("(" #cond ") check fail, return"); \
/base/security/device_auth/deps_adapter/os_adapter/impl/src/linux/
Dhc_condition.c22 int Wait(pthread_cond_t* cond, HcMutex* mutex) in Wait() argument
24 if (cond == NULL || mutex == NULL) { in Wait()
27 return -pthread_cond_wait(cond, &mutex->mutex); in Wait()
30 void Notify(pthread_cond_t* cond) in Notify() argument
32 if (cond == NULL) { in Notify()
35 pthread_cond_signal(cond); in Notify()
49 ret = Wait(&hcCond->cond, hcCond->mutex); in HcCondWaitWithoutLock()
67 Notify(&hcCond->cond); in HcCondNotifyWithoutLock()
87 ret = Wait(&hcCond->cond, hcCond->mutex); in HcCondWait()
108 Notify(&hcCond->cond); in HcCondNotify()
[all …]
/base/powermgr/battery_manager/utils/native/include/
Dpower_common.h27 #define RETURN_IF_WITH_RET(cond, retval) if (cond) {return (retval);} argument
28 #define RETURN_IF(cond) if (cond) {return;} argument
29 #define RETURN_IF_WITH_LOG(cond, loginfo) \ argument
31 if (cond) { \
/base/powermgr/power_manager/utils/native/include/
Dpower_common.h27 #define RETURN_IF_WITH_RET(cond, retval) if (cond) {return (retval);} argument
28 #define RETURN_IF(cond) if (cond) {return;} argument
29 #define RETURN_IF_WITH_LOG(cond, loginfo) \ argument
31 if (cond) { \
/base/powermgr/thermal_manager/utils/native/include/
Dthermal_common.h27 #define THERMAL_RETURN_IF_WITH_RET(cond, retval) \ argument
28 if (cond) { return (retval); }
29 #define THERMAL_RETURN_IF(cond) if (cond) {return;} argument
30 #define THERMAL_RETURN_IF_WITH_LOG(cond, loginfo) … argument
32 if (cond) { \
/base/powermgr/display_manager/utils/native/include/
Ddisplay_common.h27 #define RETURN_IF_WITH_RET(cond, retval) if (cond) {return (retval);} argument
28 #define RETURN_IF(cond) if (cond) {return;} argument
29 #define RETURN_IF_WITH_LOG(cond, loginfo) \ argument
31 if (cond) { \
/base/msdp/device_status/utils/include/
Ddevicestatus_common.h27 #define DEVICESTATUS_RETURN_IF_WITH_RET(cond, retval) if (cond) {return (retval);} argument
28 #define DEVICESTATUS_RETURN_IF(cond) if (cond) {return;} argument
29 #define DEVICESTATUS_RETURN_IF_WITH_LOG(cond, loginfo) \ argument
31 if (cond) { \
/base/powermgr/battery_statistics/utils/native/include/
Dstats_common.h27 #define STATS_RETURN_IF_WITH_RET(cond, retval) if (cond) { return (retval); } argument
28 #define STATS_RETURN_IF(cond) if (cond) { return; } argument
29 #define STATS_RETURN_IF_WITH_LOG(loglabel, cond, loginfo) \ argument
31 if (cond) { \
/base/hiviewdfx/hiappevent/test/unittest/common/native/
Dhiappevent_watcher_test.cpp56 TriggerCondition cond) : AppEventWatcher(name, filters, cond) {} in AppEventWatcherTest() argument
80 TriggerCondition cond = { in BuildCondition() local
85 return cond; in BuildCondition()
91 TriggerCondition cond = BuildCondition(0, 0, 0); in BuildSimpleWatcher() local
92 return std::make_shared<AppEventWatcherTest>(TEST_WATCHER, filters, cond); in BuildSimpleWatcher()
99 TriggerCondition cond = BuildCondition(1, 0, 0); // row is 1 in BuildWatcherWithRow() local
100 return std::make_shared<AppEventWatcherTest>(TEST_WATCHER_ROW, filters, cond); in BuildWatcherWithRow()
107 TriggerCondition cond = BuildCondition(0, 10, 0); // size is 10 byte in BuildWatcherWithSize() local
108 return std::make_shared<AppEventWatcherTest>(TEST_WATCHER_SIZE, filters, cond); in BuildWatcherWithSize()
115 TriggerCondition cond = BuildCondition(0, 0, 1); // timeout is 1 in BuildWatcherWithTimeout() local
[all …]
/base/usb/usb_manager/utils/native/include/
Dusb_common.h86 #define RETURN_IF_WITH_RET(cond, retval) \ argument
87 if (cond) { \
90 #define RETURN_IF(cond) \ argument
91 if (cond) { \
94 #define RETURN_IF_WITH_LOG(cond, loginfo) \ argument
96 if (cond) { \
/base/security/huks/utils/condition/
Dhks_condition.c29 pthread_cond_t cond; member
46 ret = pthread_cond_wait(&condition->cond, &condition->mutex); in HksConditionWait()
68 ret = pthread_cond_signal(&condition->cond); in HksConditionNotify()
87 ret = pthread_cond_init(&condition->cond, &attr); in HksConditionCreate()
103 pthread_cond_destroy(&condition->cond); in HksConditionDestroy()
/base/hiviewdfx/hiappevent/frameworks/js/napi/src/
Dnapi_hiappevent_watch.cpp62 bool IsValidConditon(const napi_env env, const napi_value cond) in IsValidConditon() argument
64 if (cond == nullptr) { in IsValidConditon()
67 if (!NapiUtil::IsObject(env, cond)) { in IsValidConditon()
72 napi_value propValue = NapiUtil::GetProperty(env, cond, propName); in IsValidConditon()
155 int GetConditionValue(const napi_env env, const napi_value cond, const std::string& name) in GetConditionValue() argument
157 if (auto value = NapiUtil::GetProperty(env, cond, name); value != nullptr) { in GetConditionValue()
175 napi_value cond = NapiUtil::GetProperty(env, watcher, COND_PROPERTY); in GetCondition() local
176 if (cond == nullptr) { in GetCondition()
181 int row = GetConditionValue(env, cond, COND_PROPS[index++]); in GetCondition()
188 int size = GetConditionValue(env, cond, COND_PROPS[index++]); in GetCondition()
[all …]
/base/time/time_service/utils/native/include/
Dtime_hilog_wreapper.h72 #define CHECK_AND_RETURN_RET_LOG(module, cond, ret, ...) \ argument
74 if (!(cond)) { \
80 #define CHECK_AND_RETURN_LOG(module, cond, ...) \ argument
82 if (!(cond)) { \
/base/hiviewdfx/hiview/base/event_store/include/
Dsys_event_query.h113 Cond &And(const Cond &cond);
121 Cond &Or(const Cond &cond);
126 static bool IsSimpleCond(Cond &cond);
127 static void Traval(DataQuery &dataQuery, Cond &cond);
128 static void GetCond(DataQuery &dataQuery, Cond &cond);
129 static void GetCondEqualValue(DataQuery &dataQuery, Cond &cond);
130 static void GetCondNotEqualValue(DataQuery &dataQuery, Cond &cond);
131 static void GetCondLessThanValue(DataQuery &dataQuery, Cond &cond);
132 static void GetCondLessEqualValue(DataQuery &dataQuery, Cond &cond);
133 static void GetCondGreatThanValue(DataQuery &dataQuery, Cond &cond);
[all …]
/base/security/device_security_level/baselib/utils/src/
Dutils_work_queue.c33 pthread_cond_t cond; member
58 pthread_cond_wait(&queue->cond, &queue->mutex); in WorkQueueThread()
107 iRet = pthread_cond_init(&queue->cond, NULL); in CreateWorkQueue()
116 (void)pthread_cond_destroy(&(queue->cond)); in CreateWorkQueue()
133 int32_t iRet = pthread_cond_broadcast(&queue->cond); in DestroyWorkQueue()
177 (void)pthread_cond_broadcast(&queue->cond); in QueueWork()
/base/hiviewdfx/hiview/adapter/plugins/eventservice/service/test/unittest/common/
Dsys_event_service_ohos_test.cpp632 EventStore::Cond cond; variable
635 auto ret = parser.ParseCondition(condStr, cond);
637 ret = parser.ParseCondition(condStr, cond);
641 ret = parser.ParseCondition(condStr1, cond);
643 ret = parser.ParseCondition(condStr1, cond);
647 ret = parser.ParseCondition(condStr2, cond);
649 ret = parser.ParseCondition(condStr2, cond);
654 ret = parser.ParseCondition(condStr3, cond);
656 ret = parser.ParseCondition(condStr3, cond);
661 ret = parser.ParseCondition(condStr4, cond);
[all …]
/base/hiviewdfx/hiappevent/frameworks/native/libhiappevent/cache/
Dapp_event_blocks_dao.cpp81 std::string cond; in RemoveBlock() local
82 cond += Blocks::FIELD_NAME; in RemoveBlock()
83 cond += " = ?"; in RemoveBlock()
86 if (int ret = dbStore->Delete(delRow, table_, cond, fields); ret != NativeRdb::E_OK) { in RemoveBlock()
/base/hiviewdfx/hisysevent/adapter/native/idl/include/
Dsys_event_query_rule.h33 … uint32_t ruleType = RuleType::WHOLE_WORD, uint32_t eventType = 0, const std::string& cond = "")
34 … : domain(domain), eventList(events), ruleType(ruleType), eventType(eventType), condition(cond) {}; in domain()
/base/hiviewdfx/hiview/adapter/plugins/eventservice/service/idl/include/
Dsys_event_query_rule.h30 … uint32_t ruleType = RuleType::WHOLE_WORD, uint32_t eventType = 0, const std::string& cond = "")
31 … : domain(domain), eventList(events), ruleType(ruleType), eventType(eventType), condition(cond) {}; in domain()
/base/powermgr/thermal_manager/test/fuzztest/thermal_fuzzer/
Dthermal_fuzzer_test.cpp149 int32_t cond[1]; in DoSomethingInterestingWithMyAPI() local
151 if (memcpy_s(cond, sizeof(cond), data, idSize) != EOK) { in DoSomethingInterestingWithMyAPI()
161 cond[0] = randomNum(engine); in DoSomethingInterestingWithMyAPI()
163 switch (static_cast<ApiNumber>(cond[0])) { in DoSomethingInterestingWithMyAPI()
/base/hiviewdfx/hisysevent/test/moduletest/common/
Dhisysevent_manager_c_test.cpp63 void InitQueryRuleWithCondition(HiSysEventQueryRule& rule, const std::string& cond) in InitQueryRuleWithCondition() argument
68 (void)StringUtil::CreateCString(&rule.condition, cond); in InitQueryRuleWithCondition()
120 void QueryTestWithCondition(const std::string& cond) in QueryTestWithCondition() argument
127 InitQueryRuleWithCondition(rule, cond); in QueryTestWithCondition()
378 std::string cond = R"~({"version":"V1","condition":{"and":[{"param":"NAME","op":"=", variable
380 QueryTestWithCondition(cond);
399 …std::string cond = R"~({"version":"V1","condition":{"and":[{"param":"uid_","op":"=","value":1201}]… variable
400 QueryTestWithCondition(cond);
419 …std::string cond = R"~({"version":"V1","condition":{"and":[{"param":"pid_","op":">=","value":0}]}}… variable
420 QueryTestWithCondition(cond);
[all …]
/base/hiviewdfx/hisysevent/interfaces/native/innerkits/hisysevent_manager/
Dhisysevent_manager_c.cpp44 std::string cond = rules[i].condition == nullptr ? "" : rules[i].condition; in HiSysEventQuery() local
45 queryRules.emplace_back(rules[i].domain, eventList, WHOLE_WORD, 0, cond); in HiSysEventQuery()

123