private void _updateAlgorithmsInTechnique(Technique value) { if (TechniqueAlgorithms != null) { TechniqueAlgorithms.Clear(); } else { TechniqueAlgorithms = new ObservableCollection <AlgorithmViewModel>(); } if (value != null) { IUnityContainer c = GlobalContainer.Instance.Container; IPipelineManager manager = c.Resolve <IPipelineManager>(); var restoredPipeline = manager.RestorePipeline(value.xml); if (TechniqueAlgorithms != null) { TechniqueAlgorithms.Clear(); } foreach (var process in restoredPipeline) { if (process != null) { AlgorithmViewModel algVM = new AlgorithmViewModel(process); algVM.IsRemovable = false; TechniqueAlgorithms.Add(algVM); } } } }
private void ProgressToStep3(object obj) { OverallFrame.Content = BaseViewModel._PostProcessingViewModel; BaseViewModel._LoadNewDsStep3ViewModel.ListOfFiles.Clear(); this.ListOfFiles.ForEach(BaseViewModel._LoadNewDsStep3ViewModel.ListOfFiles.Add); BaseViewModel._LoadNewDsStep3ViewModel.PipelineAlgorithms.Clear(); TechniqueAlgorithms.ForEach(_addAlgorithmToStep3); if (ChosenTechnique != null) { BaseViewModel._LoadNewDsStep3ViewModel.PipelineName = ChosenTechnique.Name; } }
private void _updateAlgorithmsInTechnique() { TechniqueAlgorithms.Clear(); IUnityContainer c = GlobalContainer.Instance.Container; IPipelineManager manager = c.Resolve <IPipelineManager>(); if (SelectedProcesses != null) { foreach (var process in SelectedProcesses) { TechniqueAlgorithms.Add(process); } } }
private void _updateAlgorithmsInTechnique(Technique value) { TechniqueAlgorithms.Clear(); if (value != null) { IUnityContainer c = GlobalContainer.Instance.Container; IPipelineManager manager = c.Resolve <IPipelineManager>(); var restoredPipeline = manager.RestorePipeline(value.xml); TechniqueAlgorithms.Clear(); foreach (var process in restoredPipeline) { TechniqueAlgorithms.Add(new AlgorithmViewModel(process)); } } }
private bool _canProgressToStep3(object obj) { return(TechniqueAlgorithms.Any()); }