public SelectTargetBranchWindow(string originalName, IEnumerable <Branch> targets, string teamProject, ITfsClientRepository tfs) { this.teamProject = teamProject; this.tfs = tfs; this.InitializeComponent(); this.viewmodel = new TargetBranchViewModel(originalName, targets); this.DataContext = this.viewmodel; }
public SelectTargetBranchWindow(string originalName, IEnumerable<Branch> targets, string teamProject, ITfsClientRepository tfs) { this.teamProject = teamProject; this.tfs = tfs; this.InitializeComponent(); this.viewmodel = new TargetBranchViewModel(originalName, targets); this.DataContext = this.viewmodel; }
public BuildManagerViewModel(Window owner, ITfsClientRepository repository, IMainView view, IEnumerable <IBuildController> controllers, IEnumerable <TeamProject> teamProjects, ITfsContext context) { this.owner = owner; this.repository = repository; this.view = view; this.context = context; this.BuildDefinitions = new ObservableCollection <BuildDefinitionViewModel>(); this.Builds = new ObservableCollection <BuildViewModel>(); this.DeleteCommand = new DelegateCommand(this.OnDelete); this.OpenDropFolderCommand = new DelegateCommand(this.OnOpenDropfolder); this.RetainIndefinitelyCommand = new DelegateCommand(this.OnRetainIndefinitely); this.SetBuildQualityCommand = new DelegateCommand(this.OnSetBuildQuality); this.BuildNotesCommand = new DelegateCommand(this.OnBuildNotes); this.DeleteBuildCommand = new DelegateCommand(this.OnDeleteBuild); this.ShowDetailsCommand = new DelegateCommand(this.OnShowDetails); this.ShowQueuedDetailsCommand = new DelegateCommand(this.OnShowQueuedDetails); this.StopBuildCommand = new DelegateCommand(this.OnStopBuild); this.ChangeBuildTemplateCommand = new DelegateCommand(this.OnChangeBuildTemplate); this.SetDefaultBuildTemplateCommand = new DelegateCommand(this.OnSetDefaultBuildTemplate, this.OnCanSetDefaultBuildTemplate); this.AddBuildProcessTemplateCommand = new DelegateCommand(this.OnAddBuildProcessTemplate); this.RemoveBuildProcessTemplateCommand = new DelegateCommand(this.OnRemoveBuildProcessTemplate); this.EnableCommand = new DelegateCommand(this.OnEnable, this.OnCanEnable); this.DisableCommand = new DelegateCommand(this.OnDisable, this.OnCanDisable); this.SetRetentionPoliciesCommand = new DelegateCommand(this.OnSetRetentionsPolicies); this.ChangeBuildControllerCommand = new DelegateCommand(this.OnChangeBuildController); this.ChangeDefaultDropLocationCommand = new DelegateCommand(this.OnChangeDefaultDropLocation); this.ChangeTriggerCommand = new DelegateCommand(this.OnChangeTrigger); this.CloneBuildsCommand = new DelegateCommand(this.OnCloneBuilds, this.OnCanCloneBuilds); this.QueueBuildsCommand = new DelegateCommand(this.OnQueueBuilds, this.OnCanQueueBuilds); this.EditBuildDefinitionCommand = new DelegateCommand(this.OnEditBuildDefinition, this.OnCanEditBuildDefinition); this.GenerateBuildResourcesCommand = new DelegateCommand(this.OnGenerateBuildResources); this.Controllers = new ObservableCollection <string>(controllers.Select(c => c.Name)); this.RefreshCurrentView = new DelegateCommand(this.OnRefreshCurrentView); this.Controllers.Insert(0, AllItem); this.TeamProjects = new ObservableCollection <string>(teamProjects.Select(tp => tp.Name)); this.TeamProjects.Insert(0, AllItem); this.SelectedBuildFilter = BuildFilter.Queued; this.includeDisabledBuildDefinitions = false; this.BuildViews = new ObservableCollection <BuildViewItem> { new BuildViewItem { Name = "Build Definitions", Value = BuildView.BuildDefinitions }, new BuildViewItem { Name = "Builds", Value = BuildView.Builds }, new BuildViewItem { Name = "Build Process Templates", Value = BuildView.BuildProcessTemplates } }; this.DateFilters = new DateFilterCollection(); this.SelectedBuildView = BuildView.BuildDefinitions; this.selectedBuildDateFilter = DateFilter.Today; this.BuildProcessTemplatess = new ObservableCollection <BuildTemplateViewModel>(); }
public abstract void OnRemove(ITfsClientRepository repository);
public void InitializeRepository(ITfsClientRepository rep) { this.repository = rep; }
public override void OnRemove(ITfsClientRepository repository) { repository.RemoveBuildAgent(this.Agent); }
public override void OnEnable(ITfsClientRepository repository) { repository.EnableAgent(this.Agent); }
public override void OnRemove(ITfsClientRepository repository) { repository.RemoveBuildController(this.Controller); }
public override void OnDisable(ITfsClientRepository repository) { repository.DisableController(this.Controller); }
public override void OnDisable(ITfsClientRepository repository) { repository.DisableAgent(this.Agent); }
public abstract void OnDisable(ITfsClientRepository repository);
public override void OnEnable(ITfsClientRepository repository) { repository.EnableController(this.Controller); }
public BuildManagerViewModel(Window owner, ITfsClientRepository repository, IMainView view, IEnumerable<IBuildController> controllers, IEnumerable<string> teamProjects, ITfsContext context) { this.owner = owner; this.repository = repository; this.view = view; this.context = context; this.BuildDefinitions = new ObservableCollection<BuildDefinitionViewModel>(); this.Builds = new ObservableCollection<BuildViewModel>(); this.BuildResources = new ObservableCollection<BuildResourceViewModel>(); this.CleanDropsCommands = new DelegateCommand(this.OnCleanDrops); this.DeleteCommand = new DelegateCommand(this.OnDelete); this.OpenDropFolderCommand = new DelegateCommand(this.OnOpenDropfolder); this.RetainIndefinitelyCommand = new DelegateCommand(this.OnRetainIndefinitely); this.SetBuildQualityCommand = new DelegateCommand(this.OnSetBuildQuality); this.BuildNotesCommand = new DelegateCommand(this.OnBuildNotes); this.DeleteBuildCommand = new DelegateCommand(this.OnDeleteBuild); this.ShowDetailsCommand = new DelegateCommand(this.OnShowDetails); this.RetryCommand = new DelegateCommand(this.OnRetry); this.ViewBuildLogsCommand = new DelegateCommand(this.OnViewBuildLogs); this.ShowQueuedDetailsCommand = new DelegateCommand(this.OnShowQueuedDetails); this.StopBuildCommand = new DelegateCommand(this.OnStopBuild); this.DisabledQueuedDefinitionCommand = new DelegateCommand(this.OnDisabledQueuedDefinition); this.PauseQueuedDefinitionCommand = new DelegateCommand(this.OnPauseQueuedDefinition); this.ResumeBuildCommand = new DelegateCommand(this.OnResumeBuild); this.ChangeBuildTemplateCommand = new DelegateCommand(this.OnChangeBuildTemplate); this.SetDefaultBuildTemplateCommand = new DelegateCommand(this.OnSetDefaultBuildTemplate, this.OnCanSetDefaultBuildTemplate); this.AddBuildProcessTemplateCommand = new DelegateCommand(this.OnAddBuildProcessTemplate); this.RemoveBuildProcessTemplateCommand = new DelegateCommand(this.OnRemoveBuildProcessTemplate); this.EditControllerCommand = new DelegateCommand(this.OnEditController); this.EnableBuildResourceCommand = new DelegateCommand(this.OnEnableBuildResource); this.DisableBuildResourceCommand = new DelegateCommand(this.OnDisableBuildResource); this.RemoveCommand = new DelegateCommand(this.OnRemove); this.EnableCommand = new DelegateCommand(this.OnEnable); this.DisableCommand = new DelegateCommand(this.OnDisable); this.PauseCommand = new DelegateCommand(this.OnPause); this.SetRetentionPoliciesCommand = new DelegateCommand(this.OnSetRetentionsPolicies); this.ChangeBuildControllerCommand = new DelegateCommand(this.OnChangeBuildController); this.ChangeDefaultDropLocationCommand = new DelegateCommand(this.OnChangeDefaultDropLocation); this.ChangeOutputLocationAsConfiguredCommand = new DelegateCommand(this.OnChangeOutputLocationAsConfiguredCommand); this.ChangeOutputLocationPerProjectCommand = new DelegateCommand(this.OnChangeOutputLocationPerProjectCommand); this.ChangeOutputLocationSingleFolderCommand = new DelegateCommand(this.OnChangeOutputLocationSingleFolderCommand); this.ChangeTriggerCommand = new DelegateCommand(this.OnChangeTrigger); this.ExportDefinitionCommand = new DelegateCommand(this.OnExportBuildDefinition); this.CloneBuildsCommand = new DelegateCommand(this.OnCloneBuilds, this.OnCanCloneBuilds); this.CloneGitBuildsCommand = new DelegateCommand(this.OnCloneGitBuilds, this.OnCanCloneBuilds); this.CloneBuildToProjectCommand = new DelegateCommand(this.OnCloneBuildToProject, this.OnCanCloneBuilds); this.RemapWorkspacesCommand = new DelegateCommand(this.OnRemapWorkspaces, this.OnCanRemapWorkspaces); this.QueueBuildsCommand = new DelegateCommand(this.OnQueueBuilds, this.OnCanQueueBuilds); this.QueueHighBuildsCommand = new DelegateCommand(this.OnQueueHighBuilds, this.OnCanQueueBuilds); this.EditBuildDefinitionCommand = new DelegateCommand(this.OnEditBuildDefinition, this.OnCanEditBuildDefinition); this.GenerateBuildResourcesCommand = new DelegateCommand(this.OnGenerateBuildResources); this.Controllers = new ObservableCollection<string>(controllers.Select(c => c.Name)); this.Controllers.Sort(); this.RefreshCurrentView = new DelegateCommand(this.OnRefreshCurrentView); this.ImportBuildDefinition = new DelegateCommand(this.OnImportBuildDefinition); this.Controllers.Insert(0, AllItem); this.TeamProjects = new ObservableCollection<string>(teamProjects.Select(tp => tp)); this.TeamProjects.Sort(); this.TeamProjects.Insert(0, AllItem); this.SelectedBuildFilter = BuildFilter.Queued; this.includeDisabledBuildDefinitions = false; this.BuildViews = new ObservableCollection<BuildViewItem> { new BuildViewItem { Name = "Build Definitions", Value = BuildView.BuildDefinitions }, new BuildViewItem { Name = "Builds", Value = BuildView.Builds }, new BuildViewItem { Name = "Build Process Templates", Value = BuildView.BuildProcessTemplates }, new BuildViewItem { Name = "Build Resources", Value = BuildView.BuildResources } }; this.DateFilters = new DateFilterCollection(); this.SelectedBuildView = BuildView.BuildDefinitions; this.selectedBuildDateFilter = DateFilter.Today; this.BuildProcessTemplatess = new ObservableCollection<BuildTemplateViewModel>(); }
public abstract void OnEnable(ITfsClientRepository repository);