本文整理汇总了C#中MonoDevelop.VersionControl.Revision类的典型用法代码示例。如果您正苦于以下问题:C# Revision类的具体用法?C# Revision怎么用?C# Revision使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。
Revision类属于MonoDevelop.VersionControl命名空间,在下文中一共展示了Revision类的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: RevertRevisions
private static bool RevertRevisions (Repository vc, string path, Revision revision, bool test, bool toRevision)
{
try {
if (test) {
return (vc.CanRevert (path));
}
string question = GettextCatalog.GetString (
"Are you sure you want to revert the selected resources to the revision specified (all local changes will be discarded)?");
if (!toRevision)
question = GettextCatalog.GetString (
"Are you sure you want to revert the changes from the revision selected on these resources?");
if (MessageService.AskQuestion (question,
GettextCatalog.GetString ("Note: The reversion will occur in your working copy, so you will still need to perform a commit to complete it."),
AlertButton.Cancel, AlertButton.Revert) != AlertButton.Revert)
return false;
new RevertWorker(vc, path, revision, toRevision).Start();
return true;
}
catch (Exception ex) {
if (test)
LoggingService.LogError (ex.ToString ());
else
MessageService.ShowException (ex, GettextCatalog.GetString ("Version control command failed."));
return false;
}
}
示例2: VersionInfo
public VersionInfo (FilePath localPath, string repositoryPath, bool isDirectory, VersionStatus status, Revision revision, VersionStatus remoteStatus, Revision remoteRevision)
{
this.localPath = localPath;
this.repositoryPath = repositoryPath;
this.isDirectory = isDirectory;
this.status = status;
this.revision = revision;
this.remoteStatus = remoteStatus;
this.remoteRevision = remoteRevision;
}
示例3: RevertToRevision
public static bool RevertToRevision (Repository vc, string path, Revision revision, bool test)
{
return RevertRevisions (vc, path, revision, test, true);
}
示例4: GetTextAtRevision
public override string GetTextAtRevision(FilePath repositoryPath, Revision revision)
{
throw new NotImplementedException();
}
示例5: Checkout
public override void Checkout(FilePath targetLocalPath, Revision rev, bool recurse, IProgressMonitor monitor)
{
throw new NotImplementedException();
}
示例6: Checkout
public override void Checkout (FilePath path, Revision rev, bool recurse, IProgressMonitor monitor)
{
}
示例7: GetTextAtRevision
public override string GetTextAtRevision (FilePath repositoryPath, Revision revision)
{
return null;
}
示例8: Annotation
public Annotation (Revision revision, string author, DateTime date)
{
this.Revision = revision;
this.Author = author;
this.Date = date;
}
示例9: GetAnnotations
/// <summary>
/// Retrieves annotations for a given path in the repository.
/// </summary>
/// <param name="repositoryPath">
/// A <see cref="FilePath"/>
/// </param>
/// <param name="since">
/// A <see cref="Revision"/>
/// </param>
/// <returns>
/// A <see cref="Annotation"/> corresponding to each line
/// of the file to which repositoryPath points.
/// </returns>
public virtual Annotation [] GetAnnotations (FilePath repositoryPath, Revision since)
{
return new Annotation[0];
}
示例10: GetRevisionChanges
/// <summary>
/// Returns the list of changes done in the given revision
/// </summary>
/// <param name='revision'>
/// A revision
/// </param>
public RevisionPath[] GetRevisionChanges (Revision revision)
{
return OnGetRevisionChanges (revision);
}
示例11: GetTextAtRevision
public abstract string GetTextAtRevision (FilePath repositoryPath, Revision revision);
示例12: RevertToRevision
public abstract void RevertToRevision (FilePath localPath, Revision revision, IProgressMonitor monitor);
示例13: Checkout
public abstract void Checkout (FilePath targetLocalPath, Revision rev, bool recurse, IProgressMonitor monitor);
示例14: GetHistory
// Returns the revision history of a file
public abstract Revision[] GetHistory (FilePath localFile, Revision since);
示例15: RevertWorker
public RevertWorker(Repository vc, string path, Revision revision, bool toRevision) {
this.vc = vc;
this.path = path;
this.revision = revision;
this.toRevision = toRevision;
}