internal SaveConfigurationCommandFactory(IConfigurationViewModelMapper mapper, ISettingsService settingsService, ISettings settings)
 {
     Ensure.NotNull(mapper, "mapper");
     Ensure.NotNull(settingsService, "settingsService");
     Ensure.NotNull(settings, "settings");
     this.mapper          = mapper;
     this.settingsService = settingsService;
     this.settings        = settings;
 }
예제 #2
0
 public ImportConfigurationCommand(ConfigurationViewModel viewModel, ISettingsFactory settingsFactory, IConfigurationViewModelMapper mapper)
 {
     Ensure.NotNull(viewModel, "viewModel");
     Ensure.NotNull(settingsFactory, "settingFactory");
     Ensure.NotNull(mapper, "mapper");
     this.viewModel       = viewModel;
     this.settingsFactory = settingsFactory;
     this.mapper          = mapper;
 }
        internal ConfigurationViewModel(IFactory <SaveConfigurationCommand, ConfigurationViewModel> saveCommandFactory, ISettingsFactory settingsFactory, IConfigurationViewModelMapper mapper, INavigator navigator, TroubleshootViewModel troubleshooting)
        {
            Troubleshooting = troubleshooting;

            string version = Assembly.GetExecutingAssembly().GetCustomAttribute <AssemblyInformationalVersionAttribute>().InformationalVersion;

            Version = String.Format("v{0}", version);

            saveCommand = saveCommandFactory.Create(this);
            EditAdditionalApplicationCommand   = new EditAdditionalApplicationCommand(this, navigator);
            RemoveAdditionalApplicationCommand = new RemoveAdditionalApplicationCommand(this);
            CreateAdditionalApplicationCommand = new CreateAdditionalApplicationCommand(this, navigator);

            Import = new ImportConfigurationCommand(this, settingsFactory, mapper);
            SaveAs = new SaveAsConfigurationCommand(this, settingsFactory, mapper);
        }