使用 2014.1.85.4506 API 版本。只是尝试从仓库中检索文件以在工作区中打开。
我有一个带有局部变量string localPath
、string depotPath
、string clientPath
(与 相同localPath
)Repository repo
和的对象Connection con
。
因此,我的代码如下所示:
// ...
DepotPath depotSpec = new DepotPath(depoPath);
ClientPath clientSpec = new ClientPath(clientPath);
LocalPath localSpec = new LocalPath(localPath);
FileSpec fileSpec = new FileSpec(depoSpec, clientSpec, localSpec, VersionSpec.Head);
IList<FileSpec> fileSpecs = new List<FileSpec>();
fileSpecs.Add(fileSpec);
IList<FileSpec> synced = con.Client.SyncFiles(fileSpecs, null);
// ...
并且synced
总是以null
. 有什么想法吗?