/foundation/bundlemanager/bundle_framework/services/bundlemgr/src/ |
H A D | bundle_parser.cpp | 64 bool BundleParser::ReadFileIntoJson(const std::string &filePath, nlohmann::json &jsonBuf) in ReadFileIntoJson() argument 90 jsonBuf = nlohmann::json::parse(in, nullptr, false); in ReadFileIntoJson() 92 if (jsonBuf.is_discarded()) { in ReadFileIntoJson() 223 nlohmann::json jsonBuf; in ParsePreInstallConfig() local 224 if (!ReadFileIntoJson(configFile, jsonBuf)) { in ParsePreInstallConfig() 230 return preBundleProfile.TransformTo(jsonBuf, scanInfos); in ParsePreInstallConfig() 238 nlohmann::json jsonBuf; in ParsePreUnInstallConfig() local 239 if (!ReadFileIntoJson(configFile, jsonBuf)) { in ParsePreUnInstallConfig() 245 return preBundleProfile.TransformTo(jsonBuf, uninstallList); in ParsePreUnInstallConfig() 252 nlohmann::json jsonBuf; in ParsePreInstallAbilityConfig() local 266 nlohmann::json jsonBuf; ParseDefaultPermission() local 279 nlohmann::json jsonBuf; ParseExtTypeConfig() local 317 nlohmann::json jsonBuf = nlohmann::json::parse(jsonString, nullptr, false); ParseRouterArray() local [all...] |
H A D | pre_bundle_profile.cpp | 54 const nlohmann::json &jsonBuf, in TransformTo() 57 APP_LOGI_NOFUNC("transform jsonBuf to PreScanInfos"); in TransformTo() 58 if (jsonBuf.is_discarded()) { in TransformTo() 63 if (jsonBuf.find(INSTALL_LIST) == jsonBuf.end()) { in TransformTo() 67 auto arrays = jsonBuf.at(INSTALL_LIST); in TransformTo() 124 const nlohmann::json &jsonBuf, in TransformTo() 127 APP_LOGD("transform jsonBuf to bundleNames"); in TransformTo() 128 if (jsonBuf.is_discarded()) { in TransformTo() 133 const auto &jsonObjectEnd = jsonBuf in TransformTo() 53 TransformTo( const nlohmann::json &jsonBuf, std::set<PreScanInfo> &scanInfos) const TransformTo() argument 123 TransformTo( const nlohmann::json &jsonBuf, std::set<std::string> &uninstallList) const TransformTo() argument 166 TransformTo( const nlohmann::json &jsonBuf, std::set<PreBundleConfigInfo> &preBundleConfigInfos) const TransformTo() argument 374 TransformJsonToExtensionTypeList( const nlohmann::json &jsonBuf, std::set<std::string> &extensionTypeList) const TransformJsonToExtensionTypeList() argument [all...] |
/foundation/ability/ability_runtime/services/abilitymgr/src/rdb/ |
H A D | parser_util.cpp | 58 nlohmann::json jsonBuf; in ParsePreInstallAbilityConfig() local 59 if (!ReadFileIntoJson(filePath, jsonBuf)) { in ParsePreInstallAbilityConfig() 63 if (jsonBuf.is_discarded()) { in ParsePreInstallAbilityConfig() 67 FilterInfoFromJson(jsonBuf, list); in ParsePreInstallAbilityConfig() 71 nlohmann::json &jsonBuf, std::vector<std::tuple<std::string, std::string, std::string>> &list) in FilterInfoFromJson() 73 if (jsonBuf.is_discarded()) { in FilterInfoFromJson() 78 if (jsonBuf.find(INSTALL_LIST) == jsonBuf.end()) { in FilterInfoFromJson() 83 auto arrays = jsonBuf.at(INSTALL_LIST); in FilterInfoFromJson() 147 bool ParserUtil::ReadFileIntoJson(const std::string &filePath, nlohmann::json &jsonBuf) in ReadFileIntoJson() argument 70 FilterInfoFromJson( nlohmann::json &jsonBuf, std::vector<std::tuple<std::string, std::string, std::string>> &list) FilterInfoFromJson() argument [all...] |
/foundation/multimodalinput/input/tools/event_inject/test/ |
H A D | processing_keyboard_device_test.cpp | 52 std::string jsonBuf = ReadJsonFile(path); in HWTEST_F() local 53 if (jsonBuf.empty()) { in HWTEST_F() 57 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F() 83 std::string jsonBuf = ReadJsonFile(path); in HWTEST_F() local 84 if (jsonBuf.empty()) { in HWTEST_F() 88 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F()
|
H A D | processing_joystick_device_test.cpp | 43 std::string jsonBuf = ReadJsonFile(path); in CheckTransformJson() local 44 if (jsonBuf.empty()) { in CheckTransformJson() 48 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in CheckTransformJson() 66 std::string jsonBuf = ReadJsonFile(path); in CheckJoyStickJson() local 67 if (jsonBuf.empty()) { in CheckJoyStickJson() 71 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in CheckJoyStickJson()
|
H A D | processing_game_pad_device_test.cpp | 41 std::string jsonBuf = ReadJsonFile(path); in CheckGamePadJson() local 42 if (jsonBuf.empty()) { in CheckGamePadJson() 46 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in CheckGamePadJson() 74 std::string jsonBuf = ReadJsonFile(path); in HWTEST_F() local 75 if (jsonBuf.empty()) { in HWTEST_F() 79 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F()
|
H A D | processing_pen_device_test.cpp | 42 std::string jsonBuf = ReadJsonFile(path); in CheckJsonData() local 43 if (jsonBuf.empty()) { in CheckJsonData() 47 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in CheckJsonData() 75 std::string jsonBuf = ReadJsonFile(path); in HWTEST_F() local 76 if (jsonBuf.empty()) { in HWTEST_F() 80 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F()
|
H A D | processing_mouse_device_test.cpp | 52 std::string jsonBuf = ReadJsonFile(path); in HWTEST_F() local 53 if (jsonBuf.empty()) { in HWTEST_F() 57 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F()
|
H A D | processing_pad_device_test.cpp | 51 std::string jsonBuf = ReadJsonFile(path); in HWTEST_F() local 52 if (jsonBuf.empty()) { in HWTEST_F() 56 auto ret = manageInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F()
|
H A D | get_device_object_test.cpp | 52 std::string jsonBuf = ReadJsonFile(path); in HWTEST_F() local 53 if (jsonBuf.empty()) { in HWTEST_F() 57 auto ret = openInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F()
|
H A D | manage_inject_device_test.cpp | 95 std::string jsonBuf = ReadJsonFile(filePath); in HWTEST_F() local 96 if (jsonBuf.empty()) { in HWTEST_F() 100 auto ret = openInjectDevice.TransformJsonData(DataInit(jsonBuf, false)); in HWTEST_F()
|
/foundation/bundlemanager/bundle_framework/services/bundlemgr/include/ |
H A D | pre_bundle_profile.h | 30 * @brief Transform the jsonBuf to scanInfos. 31 * @param jsonBuf Indicates the jsonBuf. 36 const nlohmann::json &jsonBuf, 39 * @brief Transform the jsonBuf to bundleNames. 40 * @param jsonBuf Indicates the jsonBuf. 45 const nlohmann::json &jsonBuf, 48 * @brief Transform the jsonBuf to preBundleConfigInfos. 49 * @param jsonBuf Indicate [all...] |
/foundation/ability/ability_runtime/services/common/src/ |
H A D | json_utils.cpp | 27 bool JsonUtils::LoadConfiguration(const std::string& path, nlohmann::json& jsonBuf, in LoadConfiguration() argument 32 if (!ReadFileInfoJson(configPath, jsonBuf)) { in LoadConfiguration() 48 bool JsonUtils::ReadFileInfoJson(const std::string &filePath, nlohmann::json &jsonBuf) in ReadFileInfoJson() argument 85 jsonBuf = nlohmann::json::parse(in, nullptr, false); in ReadFileInfoJson() 87 if (jsonBuf.is_discarded()) { in ReadFileInfoJson()
|
/foundation/arkui/ace_engine/interfaces/inner_api/drawable_descriptor/ |
H A D | drawable_descriptor.h | 96 LayeredDrawableDescriptor(std::unique_ptr<uint8_t[]> jsonBuf, size_t len, in LayeredDrawableDescriptor() argument 98 : jsonBuf_(std::move(jsonBuf)), len_(len) in LayeredDrawableDescriptor() 103 LayeredDrawableDescriptor(std::unique_ptr<uint8_t[]> jsonBuf, size_t len, in LayeredDrawableDescriptor() argument 106 : jsonBuf_(std::move(jsonBuf)), len_(len), maskPath_(std::move(path)), iconType_(iconType), density_(density) in LayeredDrawableDescriptor() 111 LayeredDrawableDescriptor(std::unique_ptr<uint8_t[]> jsonBuf, size_t len, in LayeredDrawableDescriptor() argument 115 : jsonBuf_(std::move(jsonBuf)), len_(len), maskPath_(std::move(path)), iconType_(iconType) in LayeredDrawableDescriptor() 238 std::unique_ptr<uint8_t[]> jsonBuf; in Create() local 239 state = resourceMgr->GetDrawableInfoById(id, type, len, jsonBuf, density); in Create() 249 return std::make_unique<LayeredDrawableDescriptor>(std::move(jsonBuf), len, resourceMgr); in Create() 256 return std::make_unique<DrawableDescriptor>(std::move(jsonBuf), le in Create() 269 std::unique_ptr<uint8_t[]> jsonBuf; Create() local 300 std::unique_ptr<uint8_t[]> jsonBuf; Create() local 336 std::unique_ptr<uint8_t[]> jsonBuf; Create() local 369 std::unique_ptr<uint8_t[]> jsonBuf; Create() local [all...] |
/foundation/bundlemanager/bundle_framework/interfaces/inner_api/bundlemgr_extension/src/ |
H A D | bms_extension_profile.cpp | 39 nlohmann::json jsonBuf; in ParseBmsExtension() local 40 if (!ReadFileIntoJson(jsonPath, jsonBuf)) { in ParseBmsExtension() 44 return TransformTo(jsonBuf, bmsExtension); in ParseBmsExtension() 47 bool BmsExtensionProfile::ReadFileIntoJson(const std::string &filePath, nlohmann::json &jsonBuf) const in ReadFileIntoJson() 73 jsonBuf = nlohmann::json::parse(in, nullptr, false); in ReadFileIntoJson() 75 if (jsonBuf.is_discarded()) { in ReadFileIntoJson()
|
/foundation/arkui/ace_engine/test/unittest/interfaces/ |
H A D | drawable_descriptor_test.cpp | 70 std::unique_ptr<uint8_t[]> jsonBuf; in HWTEST_F() local 73 auto layeredDrawableDescriptor = Napi::LayeredDrawableDescriptor(std::move(jsonBuf), len, std::move(resourceMgr)); in HWTEST_F() 138 std::unique_ptr<uint8_t[]> jsonBuf; in HWTEST_F() local 142 auto layeredDrawableDescriptor = Napi::LayeredDrawableDescriptor(std::move(jsonBuf), len, std::move(resourceMgr)); in HWTEST_F() 164 std::unique_ptr<uint8_t[]> jsonBuf; in HWTEST_F() local 201 std::unique_ptr<uint8_t[]> jsonBuf; in HWTEST_F() local 208 std::move(jsonBuf), len, std::move(resourceMgr), path, iconType, density); in HWTEST_F() 229 std::unique_ptr<uint8_t[]> jsonBuf; in HWTEST_F() local 236 Napi::LayeredDrawableDescriptor(std::move(jsonBuf), len, std::move(resourceMgr), path, iconType, density); in HWTEST_F() 279 std::unique_ptr<uint8_t[]> jsonBuf; in HWTEST_F() local 586 const char* jsonBuf = "{\\"background\\":\\"background\\"}"; HWTEST_F() local 602 const char* jsonBuf = "{\\"foreground\\": \\"foreground\\"}"; HWTEST_F() local [all...] |
/foundation/ability/ability_runtime/services/abilitymgr/src/ |
H A D | extension_config.cpp | 53 nlohmann::json jsonBuf; in LoadExtensionConfiguration() local 54 if (!ReadFileInfoJson(GetExtensionConfigPath().c_str(), jsonBuf)) { in LoadExtensionConfiguration() 59 LoadExtensionConfig(jsonBuf); in LoadExtensionConfiguration() 179 bool ExtensionConfig::ReadFileInfoJson(const std::string &filePath, nlohmann::json &jsonBuf) in ReadFileInfoJson() argument 205 jsonBuf = nlohmann::json::parse(in, nullptr, false); in ReadFileInfoJson() 207 if (jsonBuf.is_discarded()) { in ReadFileInfoJson()
|
/foundation/ability/ability_runtime/services/common/include/ |
H A D | json_utils.h | 35 bool LoadConfiguration(const std::string& path, nlohmann::json& jsonBuf, const std::string& defaultPath = ""); 39 bool ReadFileInfoJson(const std::string &filePath, nlohmann::json &jsonBuf);
|
/foundation/ability/ability_runtime/services/abilitymgr/include/rdb/ |
H A D | parser_util.h | 35 bool ReadFileIntoJson(const std::string &filePath, nlohmann::json &jsonBuf); 37 nlohmann::json &jsonBuf, std::vector<std::tuple<std::string, std::string, std::string>> &list);
|
/foundation/ability/ability_runtime/test/fuzztest/abilitymgrrdbparserutil_fuzzer/ |
H A D | abilitymgrrdbparserutil_fuzzer.cpp | 75 nlohmann::json jsonBuf; in DoSomethingInterestingWithMyAPI() local 76 instance.ReadFileIntoJson(jsonStr, jsonBuf); in DoSomethingInterestingWithMyAPI() 77 instance.FilterInfoFromJson(jsonBuf, list); in DoSomethingInterestingWithMyAPI()
|
/foundation/bundlemanager/bundle_framework/services/bundlemgr/src/bundle_resource/ |
H A D | bundle_resource_parser.cpp | 348 std::unique_ptr<uint8_t[]> jsonBuf; in ParseIconResourceByResourceManager() local 349 Global::Resource::RState state = resourceManager->GetDrawableInfoById(resourceInfo.iconId_, type, len, jsonBuf, 0); in ParseIconResourceByResourceManager() 359 resourceInfo.foreground_[index] = jsonBuf[index]; in ParseIconResourceByResourceManager() 363 return bundleResourceImageInfo.ConvertToBase64(std::move(jsonBuf), len, resourceInfo.icon_); in ParseIconResourceByResourceManager() 373 std::string(reinterpret_cast<char*>(jsonBuf.get()), len), 0, resourceInfo); in ParseIconResourceByResourceManager() 377 resourceInfo.foreground_[index] = jsonBuf[index]; in ParseIconResourceByResourceManager() 427 std::unique_ptr<uint8_t[]> jsonBuf; in GetMediaDataById() local 428 Global::Resource::RState state = resourceManager->GetDrawableInfoById(iconId, type, len, jsonBuf, density); in GetMediaDataById() 435 data[index] = jsonBuf[index]; in GetMediaDataById()
|
/foundation/bundlemanager/bundle_framework/interfaces/inner_api/bundlemgr_extension/include/ |
H A D | bms_extension_profile.h | 32 bool ReadFileIntoJson(const std::string &filePath, nlohmann::json &jsonBuf) const;
|
/foundation/ability/ability_runtime/services/abilitymgr/src/deeplink_reserve/ |
H A D | deeplink_reserve_config.cpp | 62 nlohmann::json jsonBuf; in LoadConfiguration() local 63 if (!ReadFileInfoJson(configPath, jsonBuf)) { in LoadConfiguration() 66 if (!LoadReservedUriList(jsonBuf)) { in LoadConfiguration() 252 bool DeepLinkReserveConfig::ReadFileInfoJson(const std::string &filePath, nlohmann::json &jsonBuf) in ReadFileInfoJson() argument 289 jsonBuf = nlohmann::json::parse(in, nullptr, false); in ReadFileInfoJson() 291 if (jsonBuf.is_discarded()) { in ReadFileInfoJson()
|
/foundation/bundlemanager/bundle_framework/interfaces/kits/js/bundle_resource/ |
H A D | bundle_resource_drawable_utils.cpp | 71 std::unique_ptr<uint8_t[]> jsonBuf; in ConvertToDrawableDescriptor() local 81 std::make_unique<Ace::Napi::LayeredDrawableDescriptor>(std::move(jsonBuf), 0, resourceManager_, themeMask, 1, in ConvertToDrawableDescriptor()
|
/foundation/multimodalinput/input/tools/event_inject/src/ |
H A D | injection_event_dispatch.cpp | 79 std::string jsonBuf = ReadJsonFile(injectArgvs_.at(JSON_FILE_PATH_INDEX)); in OnJson() local 80 if (jsonBuf.empty()) { in OnJson() 90 return manageInjectDevice_.TransformJsonData(DataInit(jsonBuf, logStatus)); in OnJson()
|