本文整理汇总了C#中Entities.Path方法的典型用法代码示例。如果您正苦于以下问题:C# Entities.Path方法的具体用法?C# Entities.Path怎么用?C# Entities.Path使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Entities
的用法示例。
在下文中一共展示了Entities.Path方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Execute
public bool Execute(string workingCopyBase,
Entities.Branch source,
Entities.Branch target,
List<Entities.RevisionRange> ranges)
{
Dictionary<string, string> settings = settingsBLL.Get();
string userName = SettingsHelper.ValidateUsername(settings);
string password = SettingsHelper.ValidatePassword(settings);
string workingCopyPath = target.Path(workingCopyBase);
using (SharpSvn.SvnClient client = BusinessLogic.VersionControl.Svn.ClientHelper.Default())
{
client.Authentication.DefaultCredentials = new System.Net.NetworkCredential(userName, password);
SharpSvn.SvnUriTarget svnSource = new SharpSvn.SvnUriTarget(source.Url);
checkoutBLL.Execute(target, workingCopyBase);
revertBLL.Execute(target, workingCopyBase);
updateBLL.Execute(target, workingCopyBase);
client.Conflict += (object sender, SharpSvn.SvnConflictEventArgs e) =>
{
this.successful = false;
};
List<Entities.RevisionRange> conflictedRanges = new List<RevisionRange>();
SharpSvn.SvnMergeArgs args = new SharpSvn.SvnMergeArgs();
foreach (var item in ranges.OrderBy(x => x.StartRevision))
{
bool success = client.Merge(workingCopyPath, svnSource, new SharpSvn.SvnRevisionRange(Convert.ToInt64(item.StartRevision), Convert.ToInt64(item.EndRevision)), args);
if (!this.successful)
{
revertBLL.Execute(target, workingCopyBase);
break;
}
}
}
return successful;
}
示例2: Execute
public void Execute(string workingCopyBase, Entities.Branch branch, string logMessage)
{
Dictionary<string, string> settings = settingsBLL.Get();
string userName = SettingsHelper.ValidateUsername(settings);
string password = SettingsHelper.ValidatePassword(settings);
string workingCopyPath = branch.Path(workingCopyBase);
using (SharpSvn.SvnClient client = BusinessLogic.VersionControl.Svn.ClientHelper.Default())
{
client.Authentication.DefaultCredentials = new System.Net.NetworkCredential(userName, password);
SharpSvn.SvnCommitArgs args = new SharpSvn.SvnCommitArgs();
args.LogMessage = logMessage;
client.Commit(workingCopyPath, args);
}
}
示例3: Execute
public void Execute(Entities.Branch branch, string workingCopyBase)
{
Dictionary<string, string> settings = settingsBLL.Get();
string userName = SettingsHelper.ValidateUsername(settings);
string password = SettingsHelper.ValidatePassword(settings);
string workingCopyPath = branch.Path(workingCopyBase);
if (!System.IO.Directory.Exists(workingCopyPath))
{
using (SharpSvn.SvnClient client = BusinessLogic.VersionControl.Svn.ClientHelper.Default())
{
client.Authentication.DefaultCredentials = new System.Net.NetworkCredential(userName, password);
SharpSvn.SvnUriTarget repo = new SharpSvn.SvnUriTarget(branch.Url);
client.CheckOut(repo, workingCopyPath);
}
}
}
示例4: Execute
public void Execute(Entities.Branch branch, string workingCopyBase)
{
Dictionary<string, string> settings = settingsBLL.Get();
string userName = SettingsHelper.ValidateUsername(settings);
string password = SettingsHelper.ValidatePassword(settings);
string workingCopyPath = branch.Path(workingCopyBase);
if (System.IO.Directory.Exists(workingCopyPath))
{
using (SharpSvn.SvnClient client = BusinessLogic.VersionControl.Svn.ClientHelper.Default())
{
client.Authentication.DefaultCredentials = new System.Net.NetworkCredential(userName, password);
SharpSvn.SvnRevertArgs args = new SharpSvn.SvnRevertArgs();
args.Depth = SharpSvn.SvnDepth.Infinity;
client.Revert(workingCopyPath, args);
}
}
}
示例5: Execute
public bool Execute(Entities.Branch branch, string workingCopyBase)
{
bool updated = false;
Dictionary<string, string> settings = settingsBLL.Get();
string userName = SettingsHelper.ValidateUsername(settings);
string password = SettingsHelper.ValidatePassword(settings);
string workingCopyPath = branch.Path(workingCopyBase);
if (System.IO.Directory.Exists(workingCopyPath))
{
using (SharpSvn.SvnClient client = BusinessLogic.VersionControl.Svn.ClientHelper.Default())
{
client.Authentication.DefaultCredentials = new System.Net.NetworkCredential(userName, password);
updated = client.Update(workingCopyPath);
}
}
return updated;
}