Home
last modified time | relevance | path

Searched refs:newPath (Results 1 - 25 of 85) sorted by relevance

1234

/foundation/bundlemanager/bundle_framework/interfaces/kits/js/zip/src/
H A Dfile_path.cpp127 FilePath newPath(path_); in DirName()
128 newPath.StripTrailingSeparatorsInternal(); in DirName()
131 newPath.path_.find_last_of(kSeparators, std::string::npos, kSeparatorsLength - 1); in DirName()
138 newPath.path_.resize(zero); in DirName()
141 newPath.path_.resize(one); in DirName()
142 } else if (lastSeparator == one && IsSeparator(newPath.path_[zero])) { in DirName()
145 newPath.path_.resize(two); in DirName()
148 newPath.path_.resize(lastSeparator); in DirName()
151 newPath.StripTrailingSeparatorsInternal(); in DirName()
152 if (!newPath in DirName()
[all...]
/third_party/skia/modules/pathkit/tests/
H A DtestReporter.js39 let newPath = document.createElementNS('http://www.w3.org/2000/svg', 'path');
40 newPath.setAttribute('stroke', 'black');
42 newPath.setAttribute('fill', 'orange');
43 newPath.setAttribute('fill-rule', fillRule);
45 newPath.setAttribute('fill', 'rgba(255,255,255,0.0)');
47 newPath.setAttribute('d', svgstr);
49 newSVG.appendChild(newPath);
/third_party/skia/modules/canvaskit/tests/
H A DtestReporter.js39 let newPath = document.createElementNS('http://www.w3.org/2000/svg', 'path');
40 newPath.setAttribute('stroke', 'black');
42 newPath.setAttribute('fill', 'orange');
43 newPath.setAttribute('fill-rule', fillRule);
45 newPath.setAttribute('fill', 'rgba(255,255,255,0.0)');
47 newPath.setAttribute('d', svgstr);
49 newSVG.appendChild(newPath);
/third_party/musl/libc-test/src/functionalext/supplement/unistd/
H A Drenameat.c33 char newPath[] = "/data/newrenameat.txt"; in renameat_0100() local
41 if ((newfd = creat(newPath, S_IWUSR)) < 0) { in renameat_0100()
52 if (renameat(oldfd, oldPath, newfd, newPath) == -1) { in renameat_0100()
56 newfd = open(newPath, O_RDWR); in renameat_0100()
67 remove(newPath); in renameat_0100()
/foundation/multimedia/media_library/frameworks/innerkitsimpl/test/unittest/medialibrary_helper_test/src/
H A Dmedia_file_utils_test.cpp109 string newPath = "/data/test/movefile_001_move"; in HWTEST_F() local
111 EXPECT_EQ(MediaFileUtils::MoveFile(oldPath, newPath), true); in HWTEST_F()
117 string newPath = "/data/test/movefile_002_move"; in HWTEST_F() local
119 EXPECT_EQ(MediaFileUtils::CreateFile(newPath), true); in HWTEST_F()
120 EXPECT_EQ(MediaFileUtils::MoveFile(oldPath, newPath), false); in HWTEST_F()
126 string newPath = "/data/test/movefile_003_move"; in HWTEST_F() local
127 EXPECT_EQ(MediaFileUtils::MoveFile(oldPath, newPath), false); in HWTEST_F()
168 string newPath = "/data/test/CopyByFd_002"; in HWTEST_F() local
172 EXPECT_EQ(MediaFileUtils::CreateFile(newPath), true); in HWTEST_F()
176 int32_t wfd = open(newPath in HWTEST_F()
186 string newPath = "/data/test/renamedir_001_renamed"; HWTEST_F() local
194 string newPath = ""; HWTEST_F() local
548 string newPath; HWTEST_F() local
571 string newPath = "datashare://test/Download"; HWTEST_F() local
[all...]
/foundation/filemanagement/file_api/interfaces/kits/js/src/mod_fileio/properties/
H A Dsymlink.cpp55 auto [resGetSymlinkArg, oldPath, newPath] = GetSymlinkArg(env, funcArg); in Sync()
60 if (symlink(oldPath.c_str(), newPath.c_str()) == -1) { in Sync()
76 auto [resGetSymlinkArg, oldPath, newPath] = GetSymlinkArg(env, funcArg); in Async()
81 auto cbExec = [oldPath = move(oldPath), newPath = move(newPath)](napi_env env) -> UniError { in Async()
82 int ret = symlink(oldPath.c_str(), newPath.c_str()); in Async()
H A Dlink.cpp56 auto [resGetLinkArg, oldPath, newPath] = GetLinkArg(env, funcArg); in Sync()
61 if (link(oldPath.c_str(), newPath.c_str()) == -1) { in Sync()
77 auto [resGetLinkArg, oldPath, newPath] = GetLinkArg(env, funcArg); in Async()
82 auto cbExec = [oldPath = move(oldPath), newPath = move(newPath)](napi_env env) -> UniError { in Async()
83 int ret = link(oldPath.c_str(), newPath.c_str()); in Async()
/foundation/filemanagement/file_api/interfaces/kits/js/src/mod_fs/properties/
H A Dsymlink.cpp56 auto [resGetSymlinkArg, oldPath, newPath] = GetSymlinkArg(env, funcArg); in Sync()
70 int ret = uv_fs_symlink(nullptr, symlink_req.get(), oldPath.c_str(), newPath.c_str(), 0, nullptr); in Sync()
89 auto [resGetSymlinkArg, oldPath, newPath] = GetSymlinkArg(env, funcArg); in Async()
96 auto cbExec = [oldPath = move(oldPath), newPath = move(newPath)]() -> NError { in Async()
103 int ret = uv_fs_symlink(nullptr, symlink_req.get(), oldPath.c_str(), newPath.c_str(), 0, nullptr); in Async()
/foundation/filemanagement/storage_service/services/storage_daemon/mtpfs/src/
H A Dmtpfs_mtp_device.cpp331 int MtpFsDevice::DirReName(const std::string &oldPath, const std::string &newPath) in DirReName() argument
335 const std::string tmpNewBaseName(SmtpfsBaseName(newPath)); in DirReName()
336 const std::string tmpNewDirName(SmtpfsDirName(newPath)); in DirReName()
344 LOGE("Can not move %{public}s to %{public}s", oldPath.c_str(), newPath.c_str()); in DirReName()
365 int MtpFsDevice::ReNameInner(const std::string &oldPath, const std::string &newPath) in ReNameInner() argument
369 const std::string tmpNewBaseName(SmtpfsBaseName(newPath)); in ReNameInner()
370 const std::string tmpNewDirName(SmtpfsDirName(newPath)); in ReNameInner()
399 LOGE("Could not move %{public}s to %{public}s", oldPath.c_str(), newPath.c_str()); in ReNameInner()
412 LOGE("Could not rename %{public}s to %{public}s", oldPath.c_str(), newPath.c_str()); in ReNameInner()
421 int MtpFsDevice::ReName(const std::string &oldPath, const std::string &newPath) in ReName() argument
615 FileRename(const std::string &oldPath, const std::string &newPath) FileRename() argument
[all...]
/foundation/filemanagement/app_file_service/utils/src/b_filesystem/
H A Db_file.cpp121 string newPath(resolvedPath.get()); in CopyFile()
126 newPath.append("/").append(basename(name.get())); in CopyFile()
127 UniqueFd fdTo(open(newPath.data(), O_RDWR | O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR)); in CopyFile()
180 std::string newPath = ""; in MoveFile() local
181 if (!GetRealPath(dirname(dir.get()), newPath)) { in MoveFile()
188 newPath.append("/").append(basename(name.get())); in MoveFile()
189 if (rename(oldPath.c_str(), newPath.c_str()) != 0) { in MoveFile()
196 UniqueFd fdTo(open(newPath.data(), O_RDWR | O_CREAT | O_TRUNC, S_IRUSR | S_IWUSR)); in MoveFile()
H A Db_dir.cpp98 string newPath = path; in GetDirFilesDetail() local
100 newPath += BConstants::FILE_SEPARATOR_CHAR; in GetDirFilesDetail()
102 smallFiles.insert(make_pair(newPath, 0)); in GetDirFilesDetail()
337 string newPath = path; in GetUser0DirFilesDetail() local
339 newPath += BConstants::FILE_SEPARATOR_CHAR; in GetUser0DirFilesDetail()
341 smallFiles.push_back(newPath); in GetUser0DirFilesDetail()
/foundation/filemanagement/dfs_service/services/distributedfiledaemon/src/network/softbus/
H A Dsoftbus_asset_recv_listener.cpp184 std::string newPath = oldPath; in MoveAsset() local
185 size_t pos = newPath.find(TEMP_DIR); in MoveAsset()
190 newPath.replace(pos, TEMP_DIR.length(), ""); in MoveAsset()
191 pos = newPath.find(ASSET_FLAG_SINGLE); in MoveAsset()
196 newPath.resize(pos); in MoveAsset()
198 SoftBusHandlerAsset::GetInstance().MkDirRecurse(newPath, S_IRWXU | S_IRWXG | S_IXOTH); in MoveAsset()
199 std::filesystem::rename(oldPath.c_str(), newPath.c_str()); in MoveAsset()
208 std::string newPath = oldPath; in MoveAsset() local
209 size_t pos = newPath.find(TEMP_DIR); in MoveAsset()
214 newPath in MoveAsset()
[all...]
/foundation/filemanagement/storage_service/services/storage_daemon/mtpfs/include/
H A Dmtpfs_mtp_device.h78 int DirReName(const std::string &oldPath, const std::string &newPath);
81 int ReName(const std::string &oldPath, const std::string &newPath);
88 int FileRename(const std::string &oldPath, const std::string &newPath);
107 int ReNameInner(const std::string &oldPath, const std::string &newPath);
/foundation/bundlemanager/bundle_framework/services/bundlemgr/test/mock/src/
H A Dinstalld_client.cpp89 ErrCode InstalldClient::RenameModuleDir(const std::string &oldPath, const std::string &newPath) in RenameModuleDir() argument
91 if (oldPath.empty() || newPath.empty()) { in RenameModuleDir()
96 return CallService(&IInstalld::RenameModuleDir, oldPath, newPath); in RenameModuleDir()
251 ErrCode InstalldClient::MoveFile(const std::string &oldPath, const std::string &newPath) in MoveFile() argument
253 if (oldPath.empty() || newPath.empty()) { in MoveFile()
258 return CallService(&IInstalld::MoveFile, oldPath, newPath); in MoveFile()
261 ErrCode InstalldClient::CopyFile(const std::string &oldPath, const std::string &newPath, in CopyFile() argument
264 if (oldPath.empty() || newPath.empty()) { in CopyFile()
269 return CallService(&IInstalld::CopyFile, oldPath, newPath, signatureFilePath); in CopyFile()
/foundation/multimedia/ringtone_library/test/unittest/ringtone_utils_test/src/
H A Dringtone_file_utils_test.cpp217 string newPath = "/data/local/tmp/test/movefile_001_move.ogg"; in HWTEST_F() local
219 EXPECT_EQ(RingtoneFileUtils::MoveFile(oldPath, newPath), true); in HWTEST_F()
225 string newPath = "/data/local/tmp/test/movefile_001_move.ogg"; in HWTEST_F() local
227 EXPECT_EQ(RingtoneFileUtils::CopyFileUtil(oldPath, newPath), true); in HWTEST_F()
229 RingtoneFileUtils::CopyFileUtil(filePath, newPath); in HWTEST_F()
/third_party/node/deps/npm/node_modules/@npmcli/arborist/lib/
H A Dnode.js952 const newPath = !oldFsParent ? this.path
957 if (newPath === nmPath) {
962 const pathChange = newPath !== this.path
978 this[_changePath](newPath)
1232 const newPath = resolve(parent.path, 'node_modules', this.name)
1233 const pathChange = newPath !== this.path
1247 this[_changePath](newPath)
1279 [_changePath] (newPath) {
1283 this.path = newPath
1285 const nameChange = newPath
[all...]
/third_party/node/test/parallel/
H A Dtest-fs-promises.js286 const newPath = path.resolve(tmpDir, 'baz2.js');
287 await rename(dest, newPath);
288 let stats = await stat(newPath);
293 await symlink(newPath, newLink);
300 assert.strictEqual(newPath.toLowerCase(),
302 assert.strictEqual(newPath.toLowerCase(),
339 const newPath = path.resolve(tmpDir, 'baz2.js');
341 await link(newPath, newLink);
/foundation/bundlemanager/bundle_framework/services/bundlemgr/src/
H A Dinstalld_client.cpp95 ErrCode InstalldClient::RenameModuleDir(const std::string &oldPath, const std::string &newPath) in RenameModuleDir() argument
97 if (oldPath.empty() || newPath.empty()) { in RenameModuleDir()
102 return CallService(&IInstalld::RenameModuleDir, oldPath, newPath); in RenameModuleDir()
309 ErrCode InstalldClient::MoveFile(const std::string &oldPath, const std::string &newPath) in MoveFile() argument
311 if (oldPath.empty() || newPath.empty()) { in MoveFile()
316 return CallService(&IInstalld::MoveFile, oldPath, newPath); in MoveFile()
319 ErrCode InstalldClient::CopyFile(const std::string &oldPath, const std::string &newPath, in CopyFile() argument
322 if (oldPath.empty() || newPath.empty()) { in CopyFile()
327 return CallService(&IInstalld::CopyFile, oldPath, newPath, signatureFilePath); in CopyFile()
/third_party/libphonenumber/metadata/src/main/java/com/google/i18n/phonenumbers/metadata/
H A DRangeTreeFactorizer.java181 RangeSpecification newPath = path.extendByMask(mask); in recurse()
183 factor = factor.union(RangeTree.from(newPath)); in recurse()
185 node.accept(new MergingVisitor(newPath)); in recurse()
/foundation/bundlemanager/bundle_framework/services/bundlemgr/test/unittest/bms_installd_client_test/
H A Dbms_installd_client_test.cpp38 const std::string NEW_PATH = "newPath";
311 std::string newPath = NEW_PATH; in HWTEST_F() local
312 ErrCode result = installClient_->RenameModuleDir(oldPath, newPath); in HWTEST_F()
320 * @tc.desc: Test whether RenameModuleDir is called normally.(newPath is empty)
326 std::string newPath = EMPTY_STRING; in HWTEST_F() local
327 ErrCode result = installClient_->RenameModuleDir(oldPath, newPath); in HWTEST_F()
341 std::string newPath = NEW_PATH; in HWTEST_F() local
342 ErrCode result = installClient_->RenameModuleDir(oldPath, newPath); in HWTEST_F()
343 EXPECT_EQ(result, installClient_->CallService(&IInstalld::RenameModuleDir, oldPath, newPath)); in HWTEST_F()
772 std::string newPath in HWTEST_F() local
787 std::string newPath = EMPTY_STRING; HWTEST_F() local
802 std::string newPath = NEW_PATH; HWTEST_F() local
817 std::string newPath = NEW_PATH; HWTEST_F() local
832 std::string newPath = EMPTY_STRING; HWTEST_F() local
847 std::string newPath = NEW_PATH; HWTEST_F() local
[all...]
/foundation/distributeddatamgr/relational_store/frameworks/native/rdb/src/
H A Dconnection_pool.cpp360 int ConnPool::ChangeDbFileForRestore(const std::string &newPath, const std::string &backupPath, in ChangeDbFileForRestore() argument
363 if (!writers_.IsFull() || config_.GetPath() == backupPath || newPath == backupPath) { in ChangeDbFileForRestore()
384 return RestoreByDbSqliteType(newPath, backupPath, slaveStatus); in ChangeDbFileForRestore()
387 int ConnPool::RestoreByDbSqliteType(const std::string &newPath, const std::string &backupPath, SlaveStatus &slaveStatus) in RestoreByDbSqliteType() argument
397 return RestoreMasterDb(newPath, backupPath); in RestoreByDbSqliteType()
400 int ConnPool::RestoreMasterDb(const std::string &newPath, const std::string &backupPath) in RestoreMasterDb() argument
412 if (config_.GetPath() != newPath) { in RestoreMasterDb()
413 RdbStoreConfig config(newPath); in RestoreMasterDb()
414 config.SetPath(newPath); in RestoreMasterDb()
419 if (!SqliteUtils::CopyFile(backupPath, newPath)) { in RestoreMasterDb()
[all...]
/foundation/ability/idl_tool/idl_tool_2/util/
H A Dfile.cpp246 std::string newPath = StringHelper::Replace(path, '\\', '/'); in CreatePartDir() local
248 std::string newPath = StringHelper::Replace(path, '/', '\\'); in CreatePartDir()
254 for (size_t i = 0; i < newPath.size(); i++) { in CreatePartDir()
255 char c = newPath[i]; in CreatePartDir()
/foundation/multimedia/media_library/frameworks/innerkitsimpl/media_library_helper/src/
H A Dmedia_file_utils.cpp557 bool MediaFileUtils::MoveFile(const string &oldPath, const string &newPath) in MoveFile() argument
561 if (IsFileExists(oldPath) && !IsFileExists(newPath)) { in MoveFile()
562 errRet = (rename(oldPath.c_str(), newPath.c_str()) == E_SUCCESS); in MoveFile()
568 bool MediaFileUtils::CopyFileUtil(const string &filePath, const string &newPath) in CopyFileUtil() argument
594 int32_t dest = open(newPath.c_str(), O_WRONLY | O_CREAT, CHOWN_RO_USR_GRP); in CopyFileUtil()
774 bool MediaFileUtils::RenameDir(const string &oldPath, const string &newPath) in RenameDir() argument
779 errRet = (rename(oldPath.c_str(), newPath.c_str()) == E_SUCCESS); in RenameDir()
1254 int32_t MediaFileUtils::ModifyAsset(const string &oldPath, const string &newPath) argument
1258 if (oldPath.empty() || newPath.empty()) {
1259 MEDIA_ERR_LOG("Failed to modify asset, oldPath: %{private}s or newPath
[all...]
/foundation/distributeddatamgr/relational_store/frameworks/native/rdb/include/
H A Dconnection_pool.h57 int ChangeDbFileForRestore(const std::string &newPath, const std::string &backupPath,
126 int RestoreByDbSqliteType(const std::string &newPath, const std::string &backupPath, SlaveStatus &slaveStatus);
127 int RestoreMasterDb(const std::string &newPath, const std::string &backupPath);
/foundation/multimedia/ringtone_library/services/utils/include/
H A Dringtone_file_utils.h65 EXPORT static bool MoveFile(const std::string &oldPath, const std::string &newPath);
66 EXPORT static bool CopyFileUtil(const std::string &filePath, const std::string &newPath);

Completed in 18 milliseconds

1234