Home
last modified time | relevance | path

Searched refs:fileContent (Results 1 - 22 of 22) sorted by relevance

/developtools/packing_tool/packing_tool/frameworks/src/json/
H A Dmodule_json_utils.cpp50 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 Djson_utils.cpp59 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in JsonFromFile()
61 return PtJson::Parse(fileContent); in JsonFromFile()
H A Dpatch_json.cpp63 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in ParseFromFile()
65 root_ = PtJson::Parse(fileContent); in ParseFromFile()
H A Dpack_info.cpp69 std::string fileContent((std::istreambuf_iterator<char>(inFile)), std::istreambuf_iterator<char>()); in ParseFromFile()
71 root_ = PtJson::Parse(fileContent); in ParseFromFile()
H A Dmodule_json.cpp114 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 Dcommon_test.cpp31 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 DHapZipInfo.java107 * @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 DFileUtils.java443 String fileContent = getFileStringFromZip(filePath, zipFile); in getProfileJson()
444 resourceMap.put(fileName, fileContent); in getProfileJson()
H A DUncompress.java1407 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 DJsonUtil.java1193 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 Dmock_module_json_utils.cpp77 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 Dzip_utils.cpp168 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 Dfast_app_packager.cpp322 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 Dutils.cpp61 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 Dzip_utils.h44 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 Dzip_utils_test.cpp212 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 Dtest.js30 const fileContent = fs.readFileSync(filePath, "utf-8");
31 const fileString = fileContent.toString();
/developtools/ace_js2bundle/ace-loader/test/card/
H A Dtest.js30 const fileContent = fs.readFileSync(filePath, "utf-8");
31 const fileString = fileContent.toString();
/developtools/ace_js2bundle/ace-loader/test/rich/
H A Dtest.js27 const fileContent = fs.readFileSync(filePath, 'utf-8');
28 const fileString = fileContent.toString();
/developtools/profiler/device/base/include/
H A Dcommon.h42 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 Dmultiapp_packager_test.cpp682 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 Dcommon.cpp589 bool ReadFile(const std::string &filePath, const std::vector<std::string>& validPaths, std::string& fileContent) in ReadFile() argument
603 fileContent = content; in ReadFile()

Completed in 20 milliseconds