/foundation/distributedhardware/distributed_screen/common/src/ |
H A D | dscreen_json_util.cpp | 23 bool IsString(const nlohmann::json &jsonObj, const std::string &key) in IsString() argument 25 bool res = jsonObj.contains(key) && jsonObj[key].is_string() && jsonObj[key].size() <= MAX_MESSAGES_LEN; in IsString() 27 DHLOGE("the key %{public}s in jsonObj is invalid.", key.c_str()); in IsString() 32 bool IsUInt8(const nlohmann::json &jsonObj, const std::string &key) in IsUInt8() argument 34 bool res = jsonObj.contains(key) && jsonObj[key].is_number_unsigned() && jsonObj[key] <= UINT8_MAX; in IsUInt8() 36 DHLOGE("the key %{public}s in jsonObj i in IsUInt8() 41 IsInt32(const nlohmann::json &jsonObj, const std::string &key) IsInt32() argument 51 IsUInt32(const nlohmann::json &jsonObj, const std::string &key) IsUInt32() argument 60 IsInt64(const nlohmann::json &jsonObj, const std::string &key) IsInt64() argument 70 IsUInt64(const nlohmann::json &jsonObj, const std::string &key) IsUInt64() argument 79 IsFloat(const nlohmann::json &jsonObj, const std::string &key) IsFloat() argument 88 IsArray(const nlohmann::json &jsonObj, const std::string &key) IsArray() argument 97 IsBool(const nlohmann::json &jsonObj, const std::string &key) IsBool() argument [all...] |
/foundation/multimedia/av_session/services/session/server/remote/ |
H A D | json_utils.cpp | 74 bool JsonUtils::IsInt32(const json& jsonObj, const std::string& key) in IsInt32() argument 76 bool res = jsonObj.contains(key) && jsonObj[key].is_number_integer() in IsInt32() 77 && INT32_MIN <= jsonObj[key] && jsonObj[key] <= INT32_MAX; in IsInt32() 79 SLOGE("The key %{public}s of jsonObj is invalid", key.c_str()); in IsInt32() 84 bool JsonUtils::IsString(const json& jsonObj, const std::string& key) in IsString() argument 86 bool res = jsonObj.contains(key) && jsonObj[key].is_string(); in IsString() 88 SLOGE("The key %{public}s of jsonObj i in IsString() 93 IsBool(const json& jsonObj, const std::string& key) IsBool() argument 106 json jsonObj = json::parse(jsonCapability, nullptr, false); GetVectorCapability() local 137 json jsonObj; SetSessionBasicInfo() local 166 json jsonObj = json::parse(sessionInfo, nullptr, false); GetSessionBasicInfo() local 209 json jsonObj; SetSessionDescriptors() local 232 json jsonObj = json::parse(sessionInfo, nullptr, false); GetSessionDescriptors() local 260 json jsonObj; SetSessionDescriptor() local 281 json jsonObj = json::parse(sessionInfo, nullptr, false); GetSessionDescriptor() local [all...] |
/foundation/resourceschedule/background_task_mgr/services/common/src/ |
H A D | bgtask_config.cpp | 45 nlohmann::json jsonObj; in LoadConfigFile() local 48 if (DelayedSingleton<DataStorageHelper>::GetInstance()->ParseJsonValueFromFile(jsonObj, absolutePath) != 0) { in LoadConfigFile() 52 ParseTransientTaskExemptedQuatoList(jsonObj); in LoadConfigFile() 53 ParseTransientTaskExemptedQuato(jsonObj); in LoadConfigFile() 56 void BgtaskConfig::ParseTransientTaskExemptedQuatoList(const nlohmann::json &jsonObj) in ParseTransientTaskExemptedQuatoList() argument 59 if (jsonObj.is_null() || jsonObj.empty()) { in ParseTransientTaskExemptedQuatoList() 60 BGTASK_LOGE("jsonObj null"); in ParseTransientTaskExemptedQuatoList() 63 if (!jsonObj.contains(TRANSIENT_ERR_DELAYED_FROZEN_LIST) || in ParseTransientTaskExemptedQuatoList() 64 !jsonObj[TRANSIENT_ERR_DELAYED_FROZEN_LIS in ParseTransientTaskExemptedQuatoList() 80 const nlohmann::json &jsonObj = nlohmann::json::parse(configData, nullptr, false); AddExemptedQuatoData() local 119 SetCloudConfigParam(const nlohmann::json &jsonObj) SetCloudConfigParam() argument 159 ParseTransientTaskExemptedQuato(const nlohmann::json &jsonObj) ParseTransientTaskExemptedQuato() argument [all...] |
/foundation/distributedhardware/distributed_input/utils/src/ |
H A D | dinput_utils_tool.cpp | 106 nlohmann::json jsonObj = nlohmann::json::parse(message, nullptr, false); in SetAnonyId() local 107 if (jsonObj.is_discarded()) { in SetAnonyId() 108 DHLOGE("jsonObj parse failed!"); in SetAnonyId() 111 if (IsString(jsonObj, DINPUT_SOFTBUS_KEY_DEVICE_ID)) { in SetAnonyId() 112 jsonObj[DINPUT_SOFTBUS_KEY_DEVICE_ID] = GetAnonyString(jsonObj[DINPUT_SOFTBUS_KEY_DEVICE_ID]); in SetAnonyId() 114 if (IsString(jsonObj, DESCRIPTOR)) { in SetAnonyId() 115 jsonObj[DESCRIPTOR] = GetAnonyString(jsonObj[DESCRIPTOR]); in SetAnonyId() 117 if (IsString(jsonObj, DINPUT_SOFTBUS_KEY_INPUT_DAT in SetAnonyId() 143 IsBoolean(const nlohmann::json &jsonObj, const std::string &key) IsBoolean() argument 148 IsString(const nlohmann::json &jsonObj, const std::string &key) IsString() argument 153 IsInt32(const nlohmann::json &jsonObj, const std::string &key) IsInt32() argument 159 IsInt64(const nlohmann::json &jsonObj, const std::string &key) IsInt64() argument 165 IsUInt16(const nlohmann::json &jsonObj, const std::string &key) IsUInt16() argument 170 IsUInt32(const nlohmann::json &jsonObj, const std::string &key) IsUInt32() argument 175 IsUInt64(const nlohmann::json &jsonObj, const std::string &key) IsUInt64() argument 180 IsArray(const nlohmann::json &jsonObj, const std::string &key) IsArray() argument [all...] |
/foundation/distributedhardware/device_manager/services/implementation/src/dependency/hichain/ |
H A D | hichain_auth_connector.cpp | 103 nlohmann::json jsonObj; in onRequest() local 106 jsonObj[FIELD_CONFIRMATION] = RequestResponse::REQUEST_REJECTED; in onRequest() 108 jsonObj[FIELD_CONFIRMATION] = RequestResponse::REQUEST_ACCEPTED; in onRequest() 112 jsonObj[FIELD_PIN_CODE] = std::to_string(pinCode); in onRequest() 113 jsonObj[FIELD_PEER_CONN_DEVICE_ID] = deviceId; in onRequest() 114 std::string jsonStr = jsonObj.dump(); in onRequest() 157 nlohmann::json jsonObj; in GenerateCredential() local 158 jsonObj["osAccountId"] = osAccountId; in GenerateCredential() 159 jsonObj["deviceId"] = localUdid; in GenerateCredential() 160 jsonObj["acquireTyp in GenerateCredential() 190 nlohmann::json jsonObj; QueryCredential() local 221 nlohmann::json jsonObj; GetCredential() local 253 nlohmann::json jsonObj; ImportCredential() local 285 nlohmann::json jsonObj; DeleteCredential() local [all...] |
H A D | hichain_connector.cpp | 145 nlohmann::json jsonObj; in CreateGroup() local 146 jsonObj[FIELD_GROUP_TYPE] = GROUP_TYPE_PEER_TO_PEER_GROUP; in CreateGroup() 147 jsonObj[FIELD_DEVICE_ID] = sLocalDeviceId; in CreateGroup() 148 jsonObj[FIELD_GROUP_NAME] = groupName; in CreateGroup() 149 jsonObj[FIELD_USER_TYPE] = 0; in CreateGroup() 150 jsonObj[FIELD_GROUP_VISIBILITY] = GROUP_VISIBILITY_PUBLIC; in CreateGroup() 151 jsonObj[FIELD_EXPIRE_TIME] = FIELD_EXPIRE_TIME_VALUE; in CreateGroup() 158 int32_t ret = deviceGroupManager_->createGroup(userId, requestId, DM_PKG_NAME, jsonObj.dump().c_str()); in CreateGroup() 180 nlohmann::json jsonObj; in IsGroupCreated() local 181 jsonObj[FIELD_GROUP_NAM in IsGroupCreated() 193 nlohmann::json jsonObj; IsRedundanceGroup() local 339 nlohmann::json jsonObj; AddMember() local 478 nlohmann::json jsonObj; onRequest() local 597 nlohmann::json jsonObj; DelMemberFromGroup() local 617 nlohmann::json jsonObj; DeleteGroup() local 637 nlohmann::json jsonObj; DeleteGroupExt() local 657 nlohmann::json jsonObj; DeleteGroup() local 671 nlohmann::json jsonObj; DeleteGroup() local 789 nlohmann::json jsonObj; CreateGroup() local 883 nlohmann::json jsonObj; ParseRemoteCredential() local 918 GetJsonStr(const nlohmann::json &jsonObj, const std::string &key) GetJsonStr() argument 927 GetJsonInt(const nlohmann::json &jsonObj, const std::string &key) GetJsonInt() argument 968 nlohmann::json jsonObj; ParseRemoteCredentialExt() local 1183 nlohmann::json jsonObj; DeleteP2PGroup() local 1222 nlohmann::json jsonObj; DeleteGroupByACL() local [all...] |
/foundation/distributedhardware/distributed_screen/common/include/ |
H A D | dscreen_json_util.h | 23 bool IsString(const nlohmann::json &jsonObj, const std::string &key); 24 bool IsUInt8(const nlohmann::json &jsonObj, const std::string &key); 25 bool IsInt32(const nlohmann::json &jsonObj, const std::string &key); 26 bool IsUInt32(const nlohmann::json &jsonObj, const std::string &key); 27 bool IsFloat(const nlohmann::json &jsonObj, const std::string &key); 28 bool IsInt64(const nlohmann::json &jsonObj, const std::string &key); 29 bool IsUInt64(const nlohmann::json &jsonObj, const std::string &key); 30 bool IsArray(const nlohmann::json &jsonObj, const std::string &key); 31 bool IsBool(const nlohmann::json &jsonObj, const std::string &key);
|
/foundation/distributedhardware/device_manager/test/unittest/ |
H A D | UTTest_auth_message_processor.cpp | 85 * 3 check ret is authMessageProcessor->CreateNegotiateMessage(jsonObj); 100 * 3 check ret is authMessageProcessor->CreateNegotiateMessage(jsonObj); 116 * 3 check ret is authMessageProcessor->CreateNegotiateMessage(jsonObj); 128 nlohmann::json jsonObj; in HWTEST_F() local 129 jsonObj[TAG_VER] = DM_ITF_VER; in HWTEST_F() 130 jsonObj[TAG_MSG_TYPE] = msgType; in HWTEST_F() 131 jsonObj[TAG_AUTH_TYPE] = authMessageProcessor->authResponseContext_->authType; in HWTEST_F() 134 authMessageProcessor->CreateNegotiateMessage(jsonObj); in HWTEST_F() 135 std::string str1 = jsonObj.dump(); in HWTEST_F() 137 authMessageProcessor->CreateNegotiateMessage(jsonObj); in HWTEST_F() 166 nlohmann::json jsonObj; HWTEST_F() local 193 nlohmann::json jsonObj; HWTEST_F() local 232 nlohmann::json jsonObj; HWTEST_F() local 256 nlohmann::json jsonObj; HWTEST_F() local 277 nlohmann::json jsonObj; HWTEST_F() local 302 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); HWTEST_F() local 703 nlohmann::json jsonObj; HWTEST_F() local 731 nlohmann::json jsonObj; HWTEST_F() local 759 nlohmann::json jsonObj; HWTEST_F() local 787 nlohmann::json jsonObj; HWTEST_F() local 815 nlohmann::json jsonObj; HWTEST_F() local 843 nlohmann::json jsonObj; HWTEST_F() local 879 nlohmann::json jsonObj; HWTEST_F() local 899 nlohmann::json jsonObj; HWTEST_F() local 918 nlohmann::json jsonObj; HWTEST_F() local 945 nlohmann::json jsonObj; HWTEST_F() local 1375 nlohmann::json jsonObj; HWTEST_F() local 1401 nlohmann::json jsonObj; HWTEST_F() local 1418 nlohmann::json jsonObj; HWTEST_F() local 1431 nlohmann::json jsonObj; HWTEST_F() local 1447 nlohmann::json jsonObj; HWTEST_F() local 1460 nlohmann::json jsonObj; HWTEST_F() local 1473 nlohmann::json jsonObj; HWTEST_F() local 1486 nlohmann::json jsonObj; HWTEST_F() local 1500 nlohmann::json jsonObj; HWTEST_F() local 1514 nlohmann::json jsonObj; HWTEST_F() local 1531 nlohmann::json jsonObj; HWTEST_F() local 1548 nlohmann::json jsonObj; HWTEST_F() local 1571 nlohmann::json jsonObj; HWTEST_F() local 1593 nlohmann::json jsonObj; HWTEST_F() local 1615 nlohmann::json jsonObj; HWTEST_F() local [all...] |
/foundation/distributedhardware/distributed_hardware_fwk/services/distributedhardwarefwkservice/src/lowlatency/ |
H A D | low_latency_listener.cpp | 51 cJSON *jsonObj = cJSON_Parse(message.c_str()); in OnMessage() local 52 if (jsonObj == NULL) { in OnMessage() 56 if (!IsUInt32(jsonObj, DH_TYPE)) { in OnMessage() 58 cJSON_Delete(jsonObj); in OnMessage() 61 if (!IsBool(jsonObj, LOW_LATENCY_ENABLE)) { in OnMessage() 63 cJSON_Delete(jsonObj); in OnMessage() 66 DHType dhType = (DHType)cJSON_GetObjectItem(jsonObj, DH_TYPE.c_str())->valuedouble; in OnMessage() 67 cJSON *isEnable = cJSON_GetObjectItem(jsonObj, LOW_LATENCY_ENABLE.c_str()); in OnMessage() 73 cJSON_Delete(jsonObj); in OnMessage()
|
/foundation/distributedhardware/device_manager/common/src/ |
H A D | dm_anonymous.cpp | 87 bool IsString(const nlohmann::json &jsonObj, const std::string &key) in IsString() argument 89 bool res = jsonObj.contains(key) && jsonObj[key].is_string() && jsonObj[key].size() <= MAX_MESSAGE_LEN; in IsString() 91 LOGE("the key %{public}s in jsonObj is invalid.", key.c_str()); in IsString() 96 bool IsInt32(const nlohmann::json &jsonObj, const std::string &key) in IsInt32() argument 98 bool res = jsonObj.contains(key) && jsonObj[key].is_number_integer() && jsonObj[key] >= INT32_MIN && in IsInt32() 99 jsonObj[ke in IsInt32() 106 IsUint32(const nlohmann::json &jsonObj, const std::string &key) IsUint32() argument 116 IsInt64(const nlohmann::json &jsonObj, const std::string &key) IsInt64() argument 126 IsArray(const nlohmann::json &jsonObj, const std::string &key) IsArray() argument 135 IsBool(const nlohmann::json &jsonObj, const std::string &key) IsBool() argument 152 nlohmann::json jsonObj; ConvertMapToJsonString() local [all...] |
/foundation/distributedhardware/device_manager/utils/src/kvadapter/ |
H A D | dm_kv_info.cpp | 25 nlohmann::json jsonObj; in ConvertDmKVValueToJson() local 26 jsonObj[UDID_HASH_KEY] = kvValue.udidHash; in ConvertDmKVValueToJson() 27 jsonObj[APP_ID_KEY] = kvValue.appID; in ConvertDmKVValueToJson() 28 jsonObj[ANOY_DEVICE_ID_KEY] = kvValue.anoyDeviceId; in ConvertDmKVValueToJson() 29 jsonObj[SALT_KEY] = kvValue.salt; in ConvertDmKVValueToJson() 30 jsonObj[LAST_MODIFY_TIME_KEY] = kvValue.lastModifyTime; in ConvertDmKVValueToJson() 31 result = jsonObj.dump(); in ConvertDmKVValueToJson()
|
/foundation/bundlemanager/app_domain_verify/frameworks/verifier/src/ |
H A D | domain_json_util.cpp | 27 json jsonObj; in Parse() local 33 jsonObj = json::parse(assetJsonsStr); in Parse() 38 if (jsonObj == nullptr || !jsonObj.is_object()) { in Parse() 43 if (jsonObj.find(ApplinkingAssetKeys::APP_LINKING) == jsonObj.end() || in Parse() 44 !jsonObj.at(ApplinkingAssetKeys::APP_LINKING).is_object()) { in Parse() 48 auto applinkingObj = jsonObj.at(ApplinkingAssetKeys::APP_LINKING); in Parse()
|
/foundation/distributedhardware/distributed_input/services/sink/sinkmanager/test/sinkmanagerunittest/ |
H A D | distributed_input_sinkmanager_test.cpp | 206 nlohmann::json jsonObj; in HWTEST_F() local 207 jsonObj[SOURCE_DEVICE_ID] = srcDevId; in HWTEST_F() 208 jsonObj[SOURCE_WINDOW_ID] = srcWinId; in HWTEST_F() 209 jsonObj[SINK_SHOW_WINDOW_ID] = sinkShowWinId; in HWTEST_F() 210 jsonObj[SINK_PROJECT_SHOW_WIDTH] = sinkShowWidth; in HWTEST_F() 211 jsonObj[SINK_PROJECT_SHOW_HEIGHT] = sinkShowHeigth; in HWTEST_F() 212 jsonObj[SINK_WINDOW_SHOW_X] = sinkShowX; in HWTEST_F() 213 jsonObj[SINK_WINDOW_SHOW_Y] = sinkShowY; in HWTEST_F() 215 int32_t ret = sinkManager_->projectWindowListener_->ParseMessage(jsonObj.dump(), in HWTEST_F() 230 nlohmann::json jsonObj; in HWTEST_F() local [all...] |
/foundation/arkui/ace_engine/frameworks/core/common/recorder/ |
H A D | event_config.cpp | 28 auto jsonObj = JsonUtil::ParseJsonString(config); in Init() local 29 if (!jsonObj || !jsonObj->IsValid() || !jsonObj->IsObject()) { in Init() 32 ParseSwitch(jsonObj); in Init() 33 auto cfgJsonArray = jsonObj->GetValue("config"); in Init() 60 void EventConfig::ParseSwitch(const std::unique_ptr<JsonValue>& jsonObj) in ParseSwitch() argument 62 enable_ = jsonObj->GetBool("enable", false); in ParseSwitch() 63 auto switchVal = jsonObj->GetValue("switch"); in ParseSwitch() 70 auto globalSwitchVal = jsonObj in ParseSwitch() [all...] |
/foundation/bundlemanager/bundle_framework/test/systemtest/common/bms/acts_bms_kit_system_test/ |
H A D | testConfigParser.h | 43 nlohmann::json jsonObj; in ParseFromFile4StressTest() local 44 jf >> jsonObj; in ParseFromFile4StressTest() local 46 const auto &jsonObjEnd = jsonObj.end(); in ParseFromFile4StressTest() 47 if (jsonObj.find(STRESS_TEST_BMS_KEY) != jsonObjEnd) { in ParseFromFile4StressTest() 48 jsonObj.at(STRESS_TEST_BMS_KEY).get_to(stlevel.BMSLevel); in ParseFromFile4StressTest()
|
/foundation/distributedhardware/distributed_hardware_fwk/utils/include/ |
H A D | dh_utils_tool.h | 50 bool IsUInt8(const cJSON* jsonObj, const std::string& key); 52 bool IsUInt16(const cJSON* jsonObj, const std::string& key); 54 bool IsInt32(const cJSON* jsonObj, const std::string& key); 56 bool IsUInt32(const cJSON* jsonObj, const std::string& key); 58 bool IsBool(const cJSON* jsonObj, const std::string& key); 60 bool IsString(const cJSON* jsonObj, const std::string& key); 62 bool IsArray(const cJSON* jsonObj, const std::string& key);
|
/foundation/distributedhardware/device_manager/services/implementation/src/authentication/ |
H A D | auth_message_processor.cpp | 43 void AuthMessageProcessor::GetJsonObj(nlohmann::json &jsonObj) in GetJsonObj() argument 49 jsonObj[TAG_VER] = DM_ITF_VER; in GetJsonObj() 50 jsonObj[TAG_MSG_TYPE] = MSG_TYPE_REQ_AUTH; in GetJsonObj() 51 jsonObj[TAG_INDEX] = 0; in GetJsonObj() 52 jsonObj[TAG_REQUESTER] = authRequestContext_->localDeviceName; in GetJsonObj() 53 jsonObj[TAG_DEVICE_ID] = authRequestContext_->deviceId; in GetJsonObj() 54 jsonObj[TAG_LOCAL_DEVICE_ID] = authRequestContext_->localDeviceId; in GetJsonObj() 55 jsonObj[TAG_LOCAL_DEVICE_TYPE] = authRequestContext_->localDeviceTypeId; in GetJsonObj() 56 jsonObj[TAG_DEVICE_TYPE] = authRequestContext_->deviceTypeId; in GetJsonObj() 57 jsonObj[TAG_AUTH_TYP in GetJsonObj() 86 nlohmann::json jsonObj; CreateAuthRequestMessage() local 112 nlohmann::json jsonObj; CreateSimpleMessage() local 586 nlohmann::json jsonObj; CreateDeviceAuthMessage() local [all...] |
/foundation/distributedhardware/device_manager/test/commonunittest/ |
H A D | UTTest_dm_anonymous.cpp | 185 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); in HWTEST_F() local 186 bool ret = IsString(jsonObj, PIN_TOKEN); in HWTEST_F() 203 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); in HWTEST_F() local 204 bool ret = IsString(jsonObj, PIN_TOKEN); in HWTEST_F() 221 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); in HWTEST_F() local 222 bool ret = IsInt32(jsonObj, TAG_AUTH_TYPE); in HWTEST_F() 239 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); in HWTEST_F() local 240 bool ret = IsInt32(jsonObj, TAG_AUTH_TYPE); in HWTEST_F() 257 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); in HWTEST_F() local 258 bool ret = IsUint32(jsonObj, TAG_AUTH_TYP in HWTEST_F() 275 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); HWTEST_F() local 293 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); HWTEST_F() local 324 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); HWTEST_F() local 344 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); HWTEST_F() local 364 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); HWTEST_F() local 384 nlohmann::json jsonObj = nlohmann::json::parse(str, nullptr, false); HWTEST_F() local 463 nlohmann::json jsonObj = nlohmann::json::parse(jsonStr, nullptr, false); HWTEST_F() local 489 nlohmann::json jsonObj = nlohmann::json::parse(jsonStr, nullptr, false); HWTEST_F() local 498 nlohmann::json jsonObj = nlohmann::json::parse(jsonStr, nullptr, false); HWTEST_F() local [all...] |
/foundation/distributedhardware/distributed_hardware_fwk/services/distributedhardwarefwkservice/src/resourcemanager/ |
H A D | version_info.cpp | 38 cJSON *jsonObj = cJSON_Parse(jsonStr.c_str()); in FromJsonString() local 39 if (jsonObj == NULL) { in FromJsonString() 43 FromJson(jsonObj, *this); in FromJsonString() 44 cJSON_Delete(jsonObj); in FromJsonString() 50 cJSON *jsonObj = cJSON_CreateObject(); in ToJsonString() local 51 if (jsonObj == NULL) { in ToJsonString() 55 ToJson(jsonObj, *this); in ToJsonString() 56 char *cjson = cJSON_PrintUnformatted(jsonObj); in ToJsonString() 58 cJSON_Delete(jsonObj); in ToJsonString() 63 cJSON_Delete(jsonObj); in ToJsonString() [all...] |
/foundation/distributedhardware/device_manager/test/softbusunittest/ |
H A D | UTTest_mine_softbus_listener.cpp | 60 nlohmann::json jsonObj; in HWTEST_F() local 61 jsonObj["findDeviceMode"] = 4; in HWTEST_F() 63 string searchJson = jsonObj.dump(); in HWTEST_F() 138 nlohmann::json jsonObj; in HWTEST_F() local 139 jsonObj["findDeviceMode"] = static_cast<char>(1); in HWTEST_F() 141 string searchJson = jsonObj.dump(); in HWTEST_F() 151 nlohmann::json jsonObj; in HWTEST_F() local 152 jsonObj["findDeviceMode"] = static_cast<char>(2); in HWTEST_F() 154 string searchJson = jsonObj.dump(); in HWTEST_F() 164 nlohmann::json jsonObj; in HWTEST_F() local 177 nlohmann::json jsonObj; HWTEST_F() local 190 nlohmann::json jsonObj; HWTEST_F() local 202 nlohmann::json jsonObj; HWTEST_F() local 215 nlohmann::json jsonObj; HWTEST_F() local 227 nlohmann::json jsonObj; HWTEST_F() local 240 nlohmann::json jsonObj; HWTEST_F() local 255 nlohmann::json jsonObj; HWTEST_F() local 272 nlohmann::json jsonObj; HWTEST_F() local 286 nlohmann::json jsonObj; HWTEST_F() local 298 nlohmann::json jsonObj; HWTEST_F() local 311 nlohmann::json jsonObj; HWTEST_F() local 326 nlohmann::json jsonObj; HWTEST_F() local 343 nlohmann::json jsonObj; HWTEST_F() local 355 nlohmann::json jsonObj; HWTEST_F() local 366 nlohmann::json jsonObj; HWTEST_F() local 378 nlohmann::json jsonObj; HWTEST_F() local 572 nlohmann::json jsonObj; HWTEST_F() local 581 nlohmann::json jsonObj; HWTEST_F() local 591 nlohmann::json jsonObj; HWTEST_F() local 601 nlohmann::json jsonObj; HWTEST_F() local [all...] |
/foundation/distributedhardware/distributed_input/utils/include/ |
H A D | dinput_utils_tool.h | 42 bool IsBoolean(const nlohmann::json &jsonObj, const std::string &key); 43 bool IsString(const nlohmann::json &jsonObj, const std::string &key); 44 bool IsInt32(const nlohmann::json &jsonObj, const std::string &key); 45 bool IsInt64(const nlohmann::json &jsonObj, const std::string &key); 46 bool IsUInt16(const nlohmann::json &jsonObj, const std::string &key); 47 bool IsUInt32(const nlohmann::json &jsonObj, const std::string &key); 48 bool IsUInt64(const nlohmann::json &jsonObj, const std::string &key); 49 bool IsArray(const nlohmann::json &jsonObj, const std::string &key);
|
/foundation/distributedhardware/device_manager/common/include/ |
H A D | dm_anonymous.h | 31 bool IsString(const nlohmann::json &jsonObj, const std::string &key); 32 bool IsInt32(const nlohmann::json &jsonObj, const std::string &key); 33 bool IsUint32(const nlohmann::json &jsonObj, const std::string &key); 34 bool IsInt64(const nlohmann::json &jsonObj, const std::string &key); 35 bool IsArray(const nlohmann::json &jsonObj, const std::string &key); 36 bool IsBool(const nlohmann::json &jsonObj, const std::string &key);
|
/foundation/distributedhardware/device_manager/services/service/src/pinholder/ |
H A D | pin_holder.cpp | 165 nlohmann::json jsonObj; in DestroyPinHolder() local 166 jsonObj[TAG_MSG_TYPE] = MSG_TYPE_DESTROY_PIN_HOLDER; in DestroyPinHolder() 167 jsonObj[TAG_PIN_TYPE] = pinType; in DestroyPinHolder() 168 jsonObj[TAG_PAYLOAD] = payload; in DestroyPinHolder() 170 std::string message = jsonObj.dump(); in DestroyPinHolder() 198 nlohmann::json jsonObj; in CreateGeneratePinHolderMsg() local 199 jsonObj[TAG_PIN_TYPE] = pinType_; in CreateGeneratePinHolderMsg() 200 jsonObj[TAG_PAYLOAD] = payload_; in CreateGeneratePinHolderMsg() 201 jsonObj[TAG_MSG_TYPE] = MSG_TYPE_CREATE_PIN_HOLDER; in CreateGeneratePinHolderMsg() 202 jsonObj[TAG_DM_VERSIO in CreateGeneratePinHolderMsg() 254 nlohmann::json jsonObj; ProcessCreateMsg() local 332 nlohmann::json jsonObj; ProcessDestroyMsg() local 367 nlohmann::json jsonObj; CloseSession() local 509 nlohmann::json jsonObj; OnSessionClosed() local 572 nlohmann::json jsonObj; NotifyPinHolderEvent() local 604 nlohmann::json jsonObj; ProcessChangeMsg() local [all...] |
/foundation/resourceschedule/resource_schedule_service/ressched_executor/common/src/ |
H A D | res_sched_exe_common_utils.cpp | 46 auto jsonObj = nlohmann::json::parse(str, nullptr, false); in StringToJson() local 47 if (jsonObj.is_discarded()) { in StringToJson() 52 if (!jsonObj.is_object()) { in StringToJson() 58 for (auto& [key, value] : jsonObj.items()) { in StringToJson()
|
/foundation/CastEngine/castengine_wifi_display/services/common/ |
H A D | kv_operator.cpp | 125 bool KvOperator::StringToJson(const std::string &str, nlohmann::json &jsonObj) in StringToJson() argument 127 jsonObj = nlohmann::json::parse(str); in StringToJson() 128 if (jsonObj.is_discarded()) { in StringToJson() 136 bool KvOperator::JsonToString(const nlohmann::json &jsonObj, std::string &str) in JsonToString() argument 138 str = jsonObj.dump(); in JsonToString() 142 bool KvOperator::QueryFromJson(const nlohmann::json &jsonObj, const std::string &key, std::string &val) in QueryFromJson() argument 144 val = jsonObj.at(key.c_str()); in QueryFromJson()
|