DeleteFile() public method

public DeleteFile ( FilePath localPath, bool force, MonoDevelop.Core.ProgressMonitor monitor, bool keepLocal = true ) : void
localPath FilePath
force bool
monitor MonoDevelop.Core.ProgressMonitor
keepLocal bool
return void
Ejemplo n.º 1
0
        public override void MoveFile(FilePath source, FilePath dest)
        {
            ProgressMonitor monitor = new ProgressMonitor();

            Repository srcRepo = GetRepository(source);
            Repository dstRepo = GetRepository(dest);

            if (dstRepo != null && dstRepo.CanMoveFilesFrom(srcRepo, source, dest))
            {
                srcRepo.MoveFile(source, dest, true, monitor);
            }
            else
            {
                CopyFile(source, dest, true);
                srcRepo.DeleteFile(source, true, monitor, false);
            }
        }
        public override void MoveFile(string source, string dest)
        {
            IProgressMonitor monitor = new NullProgressMonitor();

            Repository srcRepo = GetRepository(source);
            Repository dstRepo = GetRepository(dest);

            if (dstRepo.CanMoveFilesFrom(srcRepo, source, dest))
            {
                srcRepo.MoveFile(source, dest, true, monitor);
            }
            else
            {
                CopyFile(source, dest, true);
                srcRepo.DeleteFile(source, true, monitor);
            }
        }
Ejemplo n.º 3
0
        public override void DeleteFile(FilePath file)
        {
            Repository repo = GetRepository(file);

            repo.DeleteFile(file, true, new ProgressMonitor(), false);
        }
        public override void DeleteFile(string file)
        {
            Repository repo = GetRepository(file);

            repo.DeleteFile(file, true, new NullProgressMonitor());
        }