Exemplo n.º 1
0
        protected override void OnRevertToRevision(FilePath localPath, Revision revision, IProgressMonitor monitor)
        {
            var spec      = new ItemSpec(localPath, localPath.IsDirectory ? RecursionType.Full : RecursionType.None);
            var rev       = (TFSRevision)revision;
            var request   = new GetRequest(spec, new ChangesetVersionSpec(rev.Version));
            var workspace = GetWorkspaceByLocalPath(localPath);

            if (workspace != null)
            {
                workspace.Get(request, GetOptions.None, monitor);
                cache.RefreshItem(localPath);
            }
        }