コード例 #1
0
 public DefaultServiceControl(
     IServiceControlConnectionProvider connection,
     IEventAggregator eventAggregator,
     ISettingsProvider settingsProvider)
 {
     _connection      = connection;
     _eventAggregator = eventAggregator;
     _settings        = settingsProvider.GetSettings <ProfilerSettings>();
 }
コード例 #2
0
 public void TestInitialize()
 {
     shell = Substitute.For<IShellViewModel>();
     serviceControl = Substitute.For<IServiceControl>();
     settingsProvider = Substitute.For<ISettingsProvider>();
     connection = Substitute.For<IServiceControlConnectionProvider>();
     container = RegisterContainer();
     storedSetting = GetReloadedSettings();
     settingsProvider.GetSettings<ProfilerSettings>().Returns(storedSetting);
     connectTo = new ServiceControlConnectionViewModel(settingsProvider, container) { Parent = shell }; //TODO: Do we need to pass the full container here?
 }
コード例 #3
0
 public EndpointExplorerViewModel(
     IEventAggregator eventAggregator,
     ISettingsProvider settingsProvider,
     IServiceControlConnectionProvider connectionProvider,
     IServiceControl serviceControl,
     INetworkOperations networkOperations)
 {
     _eventAggregator    = eventAggregator;
     _settingsProvider   = settingsProvider;
     _serviceControl     = serviceControl;
     _networkOperations  = networkOperations;
     _connectionProvider = connectionProvider;
     Items = new BindableCollection <ExplorerItem>();
 }
コード例 #4
0
 public EndpointExplorerViewModel(
     IEventAggregator eventAggregator, 
     ISettingsProvider settingsProvider,
     IServiceControlConnectionProvider connectionProvider,
     IServiceControl serviceControl,
     INetworkOperations networkOperations)
 {
     _eventAggregator = eventAggregator;
     _settingsProvider = settingsProvider;
     _serviceControl = serviceControl;
     _networkOperations = networkOperations;
     _connectionProvider = connectionProvider;
     Items = new BindableCollection<ExplorerItem>();
 }
コード例 #5
0
 public void TestInitialize()
 {
     shell            = Substitute.For <IShellViewModel>();
     serviceControl   = Substitute.For <IServiceControl>();
     settingsProvider = Substitute.For <ISettingsProvider>();
     connection       = Substitute.For <IServiceControlConnectionProvider>();
     container        = RegisterContainer();
     storedSetting    = GetReloadedSettings();
     settingsProvider.GetSettings <ProfilerSettings>().Returns(storedSetting);
     connectTo = new ServiceControlConnectionViewModel(settingsProvider, container)
     {
         Parent = shell
     };                                                                                                 //TODO: Do we need to pass the full container here?
 }