/ohos5.0/foundation/bundlemanager/bundle_framework_lite/services/bundlemgr_lite/bundle_daemon/src/ |
H A D | bundle_daemon_handler.cpp | 41 int32_t BundleDaemonHandler::ExtractHap(const char *hapPath, const char *codePath) in ExtractHap() argument 55 if (!IsValideCodePath(codePath)) { in ExtractHap() 58 if (!BundleFileUtils::RemoveFile(codePath)) { in ExtractHap() 62 std::string codeDir = std::string(codePath); in ExtractHap() 156 int32_t BundleDaemonHandler::RemoveInstallDirectory(const char *codePath, const char *dataPath, boo… in RemoveInstallDirectory() argument 158 bool result = IsValideCodePath(codePath) && BundleFileUtils::RemoveFile(codePath); in RemoveInstallDirectory() 259 bool BundleDaemonHandler::IsValideCodePath(const char *codePath) in IsValideCodePath() argument 261 if (codePath == nullptr) { in IsValideCodePath() 264 return BundleFileUtils::IsValidPath(STORAGE + HAP_CODE_PATH, codePath) || in IsValideCodePath() 265 BundleFileUtils::IsValidPath(SDCARD + HAP_CODE_PATH, codePath); in IsValideCodePath()
|
H A D | bundle_daemon.cpp | 169 std::string codePath = ""; in ExtractHapInvoke() local 170 int32_t ret = ObtainStringFromIpc(req, hapPath, codePath); in ExtractHapInvoke() 174 return BundleDaemon::GetInstance().handler_.ExtractHap(hapPath.c_str(), codePath.c_str()); in ExtractHapInvoke() 252 std::string codePath = ""; in RemoveInstallDirectoryInvoke() local 254 int32_t ret = ObtainStringFromIpc(req, codePath, dataPath); in RemoveInstallDirectoryInvoke() 260 …return BundleDaemon::GetInstance().handler_.RemoveInstallDirectory(codePath.c_str(), dataPath.c_st… in RemoveInstallDirectoryInvoke()
|
/ohos5.0/foundation/ability/ability_runtime/test/unittest/frameworks_kits_appkit_native_test/ |
H A D | application_env_impl_test.cpp | 69 applicationInfo.codePath = "/codePath"; 110 std::string codePath(GetSrcPath()); 113 EXPECT_EQ(codePath, "/codePath"); 129 applicationInfo.codePath = "/codePath"; 132 std::string codePath(GetSrcPath()); 135 EXPECT_EQ(codePath, "/codePath");
|
H A D | context_deal_test.cpp | 129 std::string codePath = "CodePath"; variable 130 info->codePath = codePath; 144 std::string codePath = "/data/app/el1/bundle/public"; variable 145 info->codePath = codePath; 296 std::string codePath = "CodePath"; variable 297 info->codePath = codePath; 300 EXPECT_STREQ(context_->GetAbilityInfo()->codePath.c_str(), codePath.c_str());
|
/ohos5.0/foundation/bundlemanager/bundle_framework_lite/services/bundlemgr_lite/src/ |
H A D | bundle_info_creator.cpp | 48 size_t index = std::string(info->codePath).find_last_of(PATH_SEPARATOR); in SaveBundleInfo() 55 installDirPath = std::string(info->codePath).substr(0, index); in SaveBundleInfo() 124 std::string codePath = installDirPath + PATH_SEPARATOR + bundleProfile.bundleName; in SetBundleInfo() local 126 if (codePath.size() > PATH_LENGTH || dataPath.size() > PATH_LENGTH) { in SetBundleInfo() 133 …std::string iconPath = codePath + PATH_SEPARATOR + bundleProfile.moduleInfo.moduleName + PATH_SEPA… in SetBundleInfo() 154 !BundleInfoUtils::SetBundleInfoCodePath(bundleInfo, codePath.c_str()) || in SetBundleInfo() 158 … (bundleProfile.numOfAbility != 0 && !SetAbilityInfos(bundleProfile, codePath, bundleInfo))) { in SetBundleInfo() 213 …BundleInfoCreator::SetAbilityInfos(const BundleProfile &bundleProfile, const std::string &codePath, in SetAbilityInfos() argument 233 if (!SetAbilityInfo(bundleProfile, codePath, bundleInfo, i)) { in SetAbilityInfos() 240 … BundleInfoCreator::SetAbilityInfo(const BundleProfile &bundleProfile, const std::string &codePath, in SetAbilityInfo() argument [all …]
|
H A D | bundle_manager_service.cpp | 448 char *codePath = nullptr; in ReloadEntireBundleInfo() local 467 AdapterFree(codePath); in ReloadEntireBundleInfo() 472 ReloadBundleInfo(codePath, appId, bundleName, isSystemApp); in ReloadEntireBundleInfo() 475 AdapterFree(codePath); in ReloadEntireBundleInfo() 482 AdapterFree(codePath); in ReloadEntireBundleInfo() 487 ReloadBundleInfo(codePath, appId, bundleName, isSystemApp); in ReloadEntireBundleInfo() 489 AdapterFree(codePath); in ReloadEntireBundleInfo() 505 DIR *dir = opendir(codePath); in ReloadBundleInfo() 637 char *codePath = installedInfo->codePath; in GetBundleSize() local 638 uint32_t codeBundleSize = BundleUtil::GetFileFolderSize(codePath); in GetBundleSize() [all …]
|
H A D | bundle_installer.cpp | 134 ….bundleName = nullptr, .codePath = nullptr, .appId = nullptr, .versionCode = -1, .uid = INVALID_UI… in Install() 221 …std::string codePath = std::string(bundleInfo->codePath) + PATH_SEPARATOR + bundleInfo->moduleInfo… in ProcessBundleInstall() local 222 installRecord.codePath = bundleInfo->codePath; in ProcessBundleInstall() 224 std::string tmpCodePath = codePath + randStr; in ProcessBundleInstall() 230 …errorCode = HandleFileAndBackUpRecord(codePath.c_str(), randStr, installRecord, isUpdate, hapType); in ProcessBundleInstall() 345 uint8_t BundleInstaller::HandleFileAndBackUpRecord(const char *codePath, const char *randStr, Insta… in HandleFileAndBackUpRecord() argument 348 if (codePath == nullptr || randStr == nullptr) { in HandleFileAndBackUpRecord() 360 std::string tmpPath = std::string(codePath) + randStr; in HandleFileAndBackUpRecord() 361 if (BundleDaemonClient::GetInstance().RenameFile(tmpPath.c_str(), codePath) != EC_SUCCESS) { in HandleFileAndBackUpRecord() 450 bundleInfo->codePath, bundleInfo->dataPath, installParam.keepData) != EC_SUCCESS) { in Uninstall() [all …]
|
H A D | gt_bundle_manager_service.cpp | 265 char *codePath = installedInfo->codePath; in GetBundleSize() local 266 uint32_t codeBundleSize = BundleUtil::GetFileFolderSize(codePath); in GetBundleSize() 730 char *codePath = nullptr; in ReloadEntireBundleInfo() local 751 AdapterFree(codePath); in ReloadEntireBundleInfo() 757 AdapterFree(codePath); in ReloadEntireBundleInfo() 766 AdapterFree(codePath); in ReloadEntireBundleInfo() 772 TransformJsToBcWhenRestart(codePath, bundleName); in ReloadEntireBundleInfo() 774 bool ret = ReloadBundleInfo(codePath, appId, isSystemApp); in ReloadEntireBundleInfo() 779 AdapterFree(codePath); in ReloadEntireBundleInfo() 921 if (codePath == nullptr) { in TransformJsToBcWhenRestart() [all …]
|
H A D | gt_bundle_installer.cpp | 178 .codePath = nullptr, in Install() 261 installRecord.codePath = bundleInfo->codePath; in ProcessBundleInstall() 276 char *tmpCodePathComp[] = {installRecord.codePath, const_cast<char *>(randStr)}; in ProcessBundleInstall() 330 const_cast<char *>(bundleInfo->codePath), const_cast<char *>(ASSETS), in MoveRawFileToDataPath() 458 if (!BundleUtil::RenameDir(tmpPath, record.codePath)) { in HandleFileAndBackUpRecord() 490 uint8_t GtBundleInstaller::TransformJsToBc(const char *codePath, InstallRecord &record) in TransformJsToBc() argument 492 if (codePath == nullptr) { in TransformJsToBc() 496 char *jsPathComp[] = {const_cast<char *>(codePath), const_cast<char *>(ASSET_JS_PATH)}; in TransformJsToBc() 503 … char *newJsPathComp[] = {const_cast<char *>(codePath), const_cast<char *>(NEW_ASSET_JS_PATH)}; in TransformJsToBc() 532 …uint8_t errorCode = GtBundleParser::ConvertResInfoToBundleInfo(bundleInfo->codePath, labelId, icon… in UpdateBundleInfo() [all …]
|
H A D | bundle_daemon_client.cpp | 231 int32_t BundleDaemonClient::ExtractHap(const char *hapFile, const char *codePath) in RegisterCallback() argument 236 if (hapFile == nullptr || codePath == nullptr) { in RegisterCallback() 241 return CallClientInvoke(EXTRACT_HAP, hapFile, codePath); in RegisterCallback() 364 int32_t BundleDaemonClient::RemoveInstallDirectory(const char *codePath, const char *dataPath, bool… in RegisterCallback() argument 369 if (codePath == nullptr || dataPath == nullptr) { in RegisterCallback() 374 return CallClientInvoke(REMOVE_INSTALL_DIRECTORY, codePath, dataPath, keepData); in RegisterCallback()
|
H A D | bundle_util.cpp | 443 bool BundleUtil::CheckBundleJsonIsValid(const char *bundleName, char **codePath, char **appId, int3… in CheckBundleJsonIsValid() argument 445 if (bundleName == nullptr || codePath == nullptr || appId == nullptr) { in CheckBundleJsonIsValid() 476 *codePath = Utils::Strdup(item->valuestring); in CheckBundleJsonIsValid() 477 if (*codePath == nullptr) { in CheckBundleJsonIsValid() 484 if (!IsDir(*codePath)) { in CheckBundleJsonIsValid() 491 if (!EndWith(*codePath, bundleName)) { in CheckBundleJsonIsValid() 611 (cJSON_AddStringToObject(root, JSON_SUB_KEY_CODEPATH, installRecord.codePath) == nullptr)) { in ConvertInstallRecordToJson()
|
/ohos5.0/foundation/ability/ability_runtime/frameworks/native/runtime/ |
H A D | js_worker.h | 38 …panda::panda_file::StringPacProtect codePath = panda::panda_file::StringPacProtect(workerInfo_->co… in AssetHelper() local 39 if (!(codePath.GetOriginString()).empty() && (codePath.GetOriginString()).back() != '/') { in AssetHelper() 40 (workerInfo_->codePath).Append('/'); in AssetHelper()
|
/ohos5.0/foundation/bundlemanager/bundle_framework_lite/services/bundlemgr_lite/bundle_daemon/include/ |
H A D | bundle_daemon_handler.h | 27 int32_t ExtractHap(const char *hapPath, const char *codePath); 34 int32_t RemoveInstallDirectory(const char *codePath, const char *dataPath, bool keepData); 36 bool IsValideCodePath(const char *codePath); 37 bool IsValideDataPath(const char *codePath);
|
/ohos5.0/foundation/bundlemanager/bundle_framework_lite/frameworks/bundle_lite/src/ |
H A D | bundle_info_utils.cpp | 55 SetBundleInfoCodePath(des, src.codePath); in CopyBundleInfo() 96 des->codePath = src.codePath; in CopyBundleInfoNoReplication() 186 bool BundleInfoUtils::SetBundleInfoCodePath(BundleInfo *bundleInfo, const char *codePath) in SetBundleInfoCodePath() argument 188 if (bundleInfo == nullptr || codePath == nullptr) { in SetBundleInfoCodePath() 192 AdapterFree(bundleInfo->codePath); in SetBundleInfoCodePath() 193 bundleInfo->codePath = Utils::Strdup(codePath); in SetBundleInfoCodePath() 194 return bundleInfo->codePath != nullptr; in SetBundleInfoCodePath()
|
/ohos5.0/foundation/window/window_manager/window_scene/session/host/src/ |
H A D | ability_info_manager.cpp | 62 applicationInfoMap_[bundleName] = abilityInfo.applicationInfo.codePath; in IsAnco() 66 abilityInfo.applicationInfo.codePath.c_str()); in IsAnco() 67 … isAnco = abilityInfo.applicationInfo.codePath == std::to_string(CollaboratorType::RESERVE_TYPE) || in IsAnco() 68 … abilityInfo.applicationInfo.codePath == std::to_string(CollaboratorType::OTHERS_TYPE); in IsAnco()
|
/ohos5.0/foundation/bundlemanager/bundle_framework/test/benchmarktest/application_info_test/ |
H A D | application_info_test.cpp | 39 info.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForReadFromParcel() 68 info.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForReadMetaDataFromParcel() 97 info.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForMarshalling() 125 info.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForUnmarshalling()
|
/ohos5.0/foundation/bundlemanager/bundle_framework/test/benchmarktest/extension_ability_info_test/ |
H A D | extension_ability_info_test.cpp | 48 info.applicationInfo.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForReadFromParcel() 86 info.applicationInfo.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForMarshalling() 123 info.applicationInfo.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForUnmarshalling()
|
/ohos5.0/foundation/bundlemanager/bundle_framework/test/benchmarktest/bundle_info_test/ |
H A D | bundle_info_test.cpp | 49 info.applicationInfo.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForReadFromParcel() 88 info.applicationInfo.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForMarshalling() 126 info.applicationInfo.codePath = "/data/app/el1/budle/public/com.ohos.contactsdataability"; in BenchmarkTestForUnmarshalling()
|
/ohos5.0/foundation/bundlemanager/bundle_framework_lite/services/bundlemgr_lite/include/ |
H A D | bundle_info_creator.h | 37 static bool SetAbilityInfos(const BundleProfile &bundleProfile, const std::string &codePath, 39 static bool SetAbilityInfo(const BundleProfile &bundleProfile, const std::string &codePath,
|
H A D | bundle_daemon_client.h | 36 int32_t ExtractHap(const char *hapFile, const char *codePath); 43 int32_t RemoveInstallDirectory(const char *codePath, const char *dataPath, bool keepData);
|
/ohos5.0/foundation/ability/ability_runtime/test/unittest/file_path_utils_test/ |
H A D | file_path_utils_test.cpp | 580 const std::string& codePath = bundleName; variable 583 bool newJsModulePath = MakeFilePath(codePath, modulePath, fileName); 595 const std::string& codePath = "codePath"; variable 598 bool newJsModulePath = MakeFilePath(codePath, modulePath, fileName); 610 const std::string& codePath = "../codePath"; variable 613 bool newJsModulePath = MakeFilePath(codePath, modulePath, fileName);
|
/ohos5.0/foundation/filemanagement/app_file_service/services/backup_sa/src/module_external/ |
H A D | bms_adapter.cpp | 353 if (installedBundle.applicationInfo.codePath == HMOS_HAP_CODE_PATH || in GetBundleInfosForIncremental() 354 installedBundle.applicationInfo.codePath == LINUX_HAP_CODE_PATH) { in GetBundleInfosForIncremental() 396 if (installedBundle.applicationInfo.codePath == HMOS_HAP_CODE_PATH || in GetFullBundleInfos() 397 installedBundle.applicationInfo.codePath == LINUX_HAP_CODE_PATH) { in GetFullBundleInfos() 434 if (installedBundle.applicationInfo.codePath == HMOS_HAP_CODE_PATH || in GetExtName() 435 installedBundle.applicationInfo.codePath == LINUX_HAP_CODE_PATH) { in GetExtName() 515 if (installedBundle.applicationInfo.codePath == HMOS_HAP_CODE_PATH || in GetCurBundleExtenionInfo() 516 installedBundle.applicationInfo.codePath == LINUX_HAP_CODE_PATH) { in GetCurBundleExtenionInfo()
|
/ohos5.0/foundation/ability/ability_runtime/frameworks/native/appkit/app/ |
H A D | context_container.cpp | 287 bundleInfo.name.c_str(), bundleInfo.applicationInfo.codePath.c_str()); in InitResourceManager() 297 if (bundleInfo.applicationInfo.codePath == std::to_string(TYPE_RESERVE)) { in InitResourceManager() 299 } else if (bundleInfo.applicationInfo.codePath == std::to_string(TYPE_OTHERS)) { in InitResourceManager() 304 if (bundleInfo.applicationInfo.codePath == std::to_string(TYPE_RESERVE) || in InitResourceManager() 305 bundleInfo.applicationInfo.codePath == std::to_string(TYPE_OTHERS)) { in InitResourceManager()
|
/ohos5.0/docs/zh-cn/application-dev/faqs/ |
H A D | faqs-bundle-management.md | 100 this.uiAbilityContext.abilityInfo.applicationInfo.codePath 106 2. 使用bundleInfo.appInfo.codePath获取应用源文件路径。 111 this.sourcePath = bundleInfo.appInfo.codePath;
|
/ohos5.0/foundation/ability/ability_runtime/test/unittest/runtime_test/ |
H A D | js_worker_test.cpp | 77 workerInfo->codePath = panda::panda_file::StringPacProtect("/data/test/codePath"); 104 workerInfo->codePath = panda::panda_file::StringPacProtect("/data/test/codePath");
|