/developtools/packing_tool/packing_tool/frameworks/src/json/ |
H A D | module_json_utils.cpp | 50 std::string fileContent; in GetStageHapVerifyInfo() local 57 if (!ZipUtils::GetFileContentFromZip(hapFilePath, MODULE_JSON, fileContent)) { in GetStageHapVerifyInfo() 66 hapVerifyInfo.SetProfileStr(fileContent); in GetStageHapVerifyInfo() 70 if (!moduleJson.ParseFromString(fileContent)) { in GetStageHapVerifyInfo() 83 std::string fileContent; in GetFaHapVerifyInfo() local 89 if (!ZipUtils::GetFileContentFromZip(hapFilePath, CONFIG_JSON, fileContent)) { in GetFaHapVerifyInfo() 94 if (!moduleJson.ParseFromString(fileContent)) { in GetFaHapVerifyInfo() 102 hapVerifyInfo.SetProfileStr(fileContent); in GetFaHapVerifyInfo()
|
H A D | json_utils.cpp | 59 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in JsonFromFile() 61 return PtJson::Parse(fileContent); in JsonFromFile()
|
H A D | patch_json.cpp | 63 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in ParseFromFile() 65 root_ = PtJson::Parse(fileContent); in ParseFromFile()
|
H A D | pack_info.cpp | 69 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in ParseFromFile() 71 root_ = PtJson::Parse(fileContent); in ParseFromFile()
|
H A D | module_json.cpp | 114 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in ParseFromFile() 116 root_ = PtJson::Parse(fileContent); in ParseFromFile()
|
/developtools/profiler/device/base/test/unittest/ |
H A D | common_test.cpp | 31 bool WriteFile(const std::string& filePath, const std::string& fileContent)
in WriteFile() argument 40 size_t len = fwrite(const_cast<char*>(fileContent.c_str()), 1, fileContent.length(), file);
in WriteFile() 134 std::string fileContent = "Hello world";
in HWTEST_F() local 135 EXPECT_TRUE(WriteFile(fileName, fileContent));
in HWTEST_F() 166 EXPECT_TRUE(readContent == fileContent);
in HWTEST_F() 182 std::string fileContent = "Hello world";
in HWTEST_F() local 183 EXPECT_FALSE(WriteFile(fileName, fileContent));
in HWTEST_F()
|
/developtools/packing_tool/adapter/ohos/ |
H A D | HapZipInfo.java | 107 * @param fileContent Indicates the file content of json file. 109 public void pushResourceMap(String fileName, String fileContent) { in pushResourceMap() argument 110 if (fileName == null || fileContent == null) { in pushResourceMap() 113 resourcemMap.put(fileName, fileContent); in pushResourceMap()
|
H A D | FileUtils.java | 443 String fileContent = getFileStringFromZip(filePath, zipFile); in getProfileJson() 444 resourceMap.put(fileName, fileContent); in getProfileJson()
|
H A D | Uncompress.java | 1407 String fileContent = FileUtils.getFileStringFromZip(filePath, zipFile); in getProfileJson() 1408 resourceMap.put(fileName, fileContent); in getProfileJson() 1474 String fileContent = readStringFromInputStream(zipIn, bufferedReader); in unZipModuleHapFileFromInputStream() 1475 hapZipInfo.pushResourceMap(fileName, fileContent); in unZipModuleHapFileFromInputStream()
|
H A D | JsonUtil.java | 1193 String fileContent = profileJsons.get(pageFile); in parseModulePages() 1194 if (fileContent != null) { in parseModulePages() 1195 JSONObject pageObj = JSONObject.parseObject(fileContent); in parseModulePages()
|
/developtools/packing_tool/packing_tool/frameworks/test/unittest/app_packager_test/mock/ |
H A D | mock_module_json_utils.cpp | 77 std::string fileContent; in GetStageHapVerifyInfo() local 84 if (!ZipUtils::GetFileContentFromZip(hapFilePath, MODULE_JSON, fileContent)) { in GetStageHapVerifyInfo() 93 hapVerifyInfo.SetProfileStr(fileContent); in GetStageHapVerifyInfo() 97 if (!moduleJson.ParseFromString(fileContent)) { in GetStageHapVerifyInfo() 122 std::string fileContent; in GetFaHapVerifyInfo() local 128 if (!ZipUtils::GetFileContentFromZip(hapFilePath, CONFIG_JSON, fileContent)) { in GetFaHapVerifyInfo() 133 if (!moduleJson.ParseFromString(fileContent)) { in GetFaHapVerifyInfo() 141 hapVerifyInfo.SetProfileStr(fileContent); in GetFaHapVerifyInfo()
|
/developtools/packing_tool/packing_tool/frameworks/src/ |
H A D | zip_utils.cpp | 168 std::string& fileContent) in GetFileContentFromZip() 200 fileContent = ""; in GetFileContentFromZip() 212 fileContent += std::string(buffer); in GetFileContentFromZip() 219 bool ZipUtils::GetUnzipCurrentFileContent(unzFile& unzipFile, std::string& fileContent) in GetUnzipCurrentFileContent() argument 230 fileContent = ""; in GetUnzipCurrentFileContent() 241 fileContent += std::string(buffer); in GetUnzipCurrentFileContent() 256 std::string fileContent; in AddToResourceMap() local 257 if (!GetUnzipCurrentFileContent(unzipFile, fileContent)) { in AddToResourceMap() 261 resourceMap.emplace(fileName, fileContent); in AddToResourceMap() 167 GetFileContentFromZip(const std::string& zipFilePath, const std::string& filename, std::string& fileContent) GetFileContentFromZip() argument
|
H A D | fast_app_packager.cpp | 322 std::string fileContent; in GetModuleJsonContentFromPath() local 323 if (!ZipUtils::GetFileContentFromZip(path, Constants::MODULE_JSON, fileContent)) { in GetModuleJsonContentFromPath() 327 return fileContent; in GetModuleJsonContentFromPath() 460 std::string fileContent; in GetPackInfoContentFromPath() local 461 if (!ZipUtils::GetFileContentFromZip(path, Constants::PACK_INFO, fileContent)) { in GetPackInfoContentFromPath() 465 return fileContent; in GetPackInfoContentFromPath()
|
H A D | utils.cpp | 61 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in GetFileContent() 63 return fileContent; in GetFileContent()
|
/developtools/packing_tool/packing_tool/frameworks/include/ |
H A D | zip_utils.h | 44 std::string& fileContent); 49 static bool GetUnzipCurrentFileContent(unzFile& unzipFile, std::string& fileContent);
|
/developtools/packing_tool/packing_tool/frameworks/test/unittest/zip_utils_test/ |
H A D | zip_utils_test.cpp | 212 std::string fileContent; in HWTEST_F() local 217 EXPECT_TRUE(zipUtils.GetFileContentFromZip(zipPath, FILE_NAME, fileContent)); in HWTEST_F() 218 EXPECT_TRUE(!fileContent.empty()); in HWTEST_F() 234 std::string fileContent; in HWTEST_F() local 240 EXPECT_TRUE(zipUtils.GetUnzipCurrentFileContent(unzipFile, fileContent)); in HWTEST_F() 241 EXPECT_TRUE(!fileContent.empty()); in HWTEST_F()
|
/developtools/ace_js2bundle/ace-loader/test/lite/ |
H A D | test.js | 30 const fileContent = fs.readFileSync(filePath, "utf-8"); 31 const fileString = fileContent.toString();
|
/developtools/ace_js2bundle/ace-loader/test/card/ |
H A D | test.js | 30 const fileContent = fs.readFileSync(filePath, "utf-8"); 31 const fileString = fileContent.toString();
|
/developtools/ace_js2bundle/ace-loader/test/rich/ |
H A D | test.js | 27 const fileContent = fs.readFileSync(filePath, 'utf-8'); 28 const fileString = fileContent.toString();
|
/developtools/profiler/device/base/include/ |
H A D | common.h | 42 bool ReadFile(const std::string& filePath, const std::vector<std::string>& validPaths, std::string& fileContent);
|
/developtools/packing_tool/packing_tool/frameworks/test/unittest/multiapp_packager_test/ |
H A D | multiapp_packager_test.cpp | 682 std::string fileContent((std::istreambuf_iterator<char>(freader)), std::istreambuf_iterator<char>()); in HWTEST_F() 683 EXPECT_EQ(fileContent, ""); in HWTEST_F() 708 std::string fileContent((std::istreambuf_iterator<char>(freader)), std::istreambuf_iterator<char>()); in HWTEST_F() 709 EXPECT_EQ(fileContent, ""); in HWTEST_F() 734 std::string fileContent((std::istreambuf_iterator<char>(freader)), std::istreambuf_iterator<char>()); in HWTEST_F() 735 EXPECT_EQ(fileContent, content); in HWTEST_F()
|
/developtools/profiler/device/base/src/ |
H A D | common.cpp | 589 bool ReadFile(const std::string &filePath, const std::vector<std::string>& validPaths, std::string& fileContent) in ReadFile() argument 603 fileContent = content; in ReadFile()
|