Пример #1
0
 protected override void Context()
 {
     _simulationPersistableUpdater = A.Fake <ISimulationPersistableUpdater>();
     sut              = new OutputSelectionUpdater(_simulationPersistableUpdater);
     _mappedOutputs   = new List <QuantitySelection>();
     _simulation      = A.Fake <IModelCoreSimulation>();
     _outputSelection = new OutputSelections();
     _simulation.SimulationSettings.OutputSelections = _outputSelection;
 }
Пример #2
0
 public SimulationBatch(ISimModelBatch simModelBatch,
                        ISimulationResultsCreator simulationResultsCreator,
                        ISimulationPersistableUpdater simulationPersistableUpdater
                        )
 {
     _simModelBatch                = simModelBatch;
     _simulationResultsCreator     = simulationResultsCreator;
     _simulationPersistableUpdater = simulationPersistableUpdater;
 }
Пример #3
0
 protected override void Context()
 {
     _simModelManager             = A.Fake <ISimModelManager>();
     _simulationPersitableUpdater = A.Fake <ISimulationPersistableUpdater>();
     _populationRunner            = A.Fake <IPopulationRunner>();
     _populationTask           = A.Fake <IPopulationTask>();
     _progressManager          = A.Fake <IProgressManager>();
     _simulationResultsCreator = new SimulationResultsCreator();
     sut = new SimulationRunner(_simModelManager, _populationRunner, _simulationResultsCreator, _simulationPersitableUpdater, _populationTask,
                                _progressManager);
 }
Пример #4
0
 public SimulationRunner(
     ISimulationEngineFactory simulationEngineFactory,
     ILazyLoadTask lazyLoadTask,
     IEntityValidationTask entityValidationTask,
     ISimulationPersistableUpdater simulationPersistableUpdater)
 {
     _simulationEngineFactory      = simulationEngineFactory;
     _lazyLoadTask                 = lazyLoadTask;
     _entityValidationTask         = entityValidationTask;
     _simulationPersistableUpdater = simulationPersistableUpdater;
 }
 public OutputSelectionsPresenter(IOutputSelectionsView view, IQuantitySelectionPresenter quantitySelectionPresenter,
                                  ISimulationPersistableUpdater simulationPersistableUpdater)
     : base(view)
 {
     _quantitySelectionPresenter   = quantitySelectionPresenter;
     _simulationPersistableUpdater = simulationPersistableUpdater;
     _quantitySelectionPresenter.AutomaticallyHideEmptyColumns = true;
     _quantitySelectionPresenter.StatusChanged += (o, e) => refreshView();
     _view.AddSettingsView(_quantitySelectionPresenter.BaseView);
     _quantitySelectionPresenter.Description = AppConstants.Captions.SimulationSettingsDescription.FormatForDescription();
     AddSubPresenters(_quantitySelectionPresenter);
 }
Пример #6
0
 public SimulationModelCreator(IBuildConfigurationTask buildConfigurationTask, IModelConstructor modelConstructor, IParameterIdUpdater parameterIdUpdater,
                               IEntityPathResolver entityPathResolver, IExpressionContainersRetriever expressionContainersRetriever,
                               ISimulationSettingsFactory simulationSettingsFactory, ISimulationPersistableUpdater simulationPersistableUpdater)
 {
     _buildConfigurationTask        = buildConfigurationTask;
     _modelConstructor              = modelConstructor;
     _parameterIdUpdater            = parameterIdUpdater;
     _entityPathResolver            = entityPathResolver;
     _expressionContainersRetriever = expressionContainersRetriever;
     _simulationSettingsFactory     = simulationSettingsFactory;
     _simulationPersistableUpdater  = simulationPersistableUpdater;
 }
Пример #7
0
        protected override void Context()
        {
            _eventPublisher = A.Fake <IEventPublisher>();
            _sensitivityAnalysisVariationDataCreator = A.Fake <ISensitivityAnalysisVariationDataCreator>();
            _populationRunner             = A.Fake <IPopulationRunner>();
            _modelCoreSimulationMapper    = A.Fake <ISimulationToModelCoreSimulationMapper>();
            _runResultCalculator          = A.Fake <ISensitivityAnalysisRunResultCalculator>();
            _simulationPersistableUpdater = A.Fake <ISimulationPersistableUpdater>();
            sut = new SensitivityAnalysisEngine(_eventPublisher, _sensitivityAnalysisVariationDataCreator, _populationRunner, _modelCoreSimulationMapper, _runResultCalculator, _simulationPersistableUpdater);

            _sensitivityAnalysis = A.Fake <SensitivityAnalysis>();
            _modelCoreSimulation = A.Fake <IModelCoreSimulation>();
            A.CallTo(() => _modelCoreSimulationMapper.MapFrom(_sensitivityAnalysis.Simulation, true)).Returns(_modelCoreSimulation);
        }
Пример #8
0
 public SensitivityAnalysisEngine(IEventPublisher eventPublisher, ISensitivyAnalysisVariationDataCreator sensitivyAnalysisVariationDataCreator,
                                  IPopulationRunner populationRunner, ICoreUserSettings userSettings, ISimulationToModelCoreSimulationMapper modelCoreSimulationMapper,
                                  ISensitivityAnalysisRunResultCalculator runResultCalculator, ISimulationPersistableUpdater simulationPersistableUpdater)
 {
     _eventPublisher = eventPublisher;
     _sensitivyAnalysisVariationDataCreator = sensitivyAnalysisVariationDataCreator;
     _populationRunner                     = populationRunner;
     _userSettings                         = userSettings;
     _modelCoreSimulationMapper            = modelCoreSimulationMapper;
     _runResultCalculator                  = runResultCalculator;
     _simulationPersistableUpdater         = simulationPersistableUpdater;
     _populationRunner.Terminated         += terminated;
     _populationRunner.SimulationProgress += simulationProgress;
 }
Пример #9
0
 public IndividualSimulationEngine(ISimModelManager simModelManager, IProgressManager progressManager,
                                   ISimulationResultsSynchronizer simulationResultsSynchronizer,
                                   IEventPublisher eventPublisher, IExceptionManager exceptionManager,
                                   ISimulationToModelCoreSimulationMapper modelCoreSimulationMapper, ISimulationPersistableUpdater simulationPersistableUpdater)
 {
     _simModelManager = simModelManager;
     _progressManager = progressManager;
     _simulationResultsSynchronizer = simulationResultsSynchronizer;
     _eventPublisher               = eventPublisher;
     _exceptionManager             = exceptionManager;
     _modelCoreSimulationMapper    = modelCoreSimulationMapper;
     _simulationPersistableUpdater = simulationPersistableUpdater;
     _simModelManager.Terminated  += terminated;
 }
Пример #10
0
 public SimulationRunner(
     ISimModelManager simModelManager,
     IPopulationRunner populationRunner,
     ISimulationResultsCreator simulationResultsCreator,
     ISimulationPersistableUpdater simulationPersistableUpdater,
     IPopulationTask populationTask,
     IProgressManager progressManager)
 {
     _simModelManager              = simModelManager;
     _populationRunner             = populationRunner;
     _simulationResultsCreator     = simulationResultsCreator;
     _simulationPersistableUpdater = simulationPersistableUpdater;
     _populationTask  = populationTask;
     _progressManager = progressManager;
 }
Пример #11
0
 public PopulationSimulationEngine(IPopulationRunner populationRunner, IProgressManager progressManager,
                                   IEventPublisher eventPublisher, IExceptionManager exceptionManager,
                                   ISimulationResultsSynchronizer simulationResultsSynchronizer, IPopulationExportTask populationExporter,
                                   ISimulationToModelCoreSimulationMapper modelCoreSimulationMapper, ISimulationPersistableUpdater simulationPersistableUpdater, ICoreUserSettings userSettings,
                                   IPopulationSimulationAnalysisSynchronizer populationSimulationAnalysisSynchronizer)
 {
     _populationRunner = populationRunner;
     _progressManager  = progressManager;
     _eventPublisher   = eventPublisher;
     _exceptionManager = exceptionManager;
     _simulationResultsSynchronizer = simulationResultsSynchronizer;
     _populationExporter            = populationExporter;
     _modelCoreSimulationMapper     = modelCoreSimulationMapper;
     _simulationPersistableUpdater  = simulationPersistableUpdater;
     _userSettings = userSettings;
     _populationSimulationAnalysisSynchronizer = populationSimulationAnalysisSynchronizer;
     _populationRunner.Terminated         += terminated;
     _populationRunner.SimulationProgress += simulationProgress;
 }
Пример #12
0
 public OutputSelectionUpdater(ISimulationPersistableUpdater simulationPersistableUpdater)
 {
     _simulationPersistableUpdater = simulationPersistableUpdater;
 }
Пример #13
0
 public PopulationSimulationSettingsPresenter(IPopulationSimulationSettingsView view, IQuantitySelectionPresenter quantitySelectionPresenter, ISimulationPersistableUpdater simulationPersistableUpdater, IPKSimProjectRetriever projectRetriever, IDialogCreator dialogCreator, IUserSettings userSettings)
     : base(view, quantitySelectionPresenter, simulationPersistableUpdater, projectRetriever, dialogCreator, userSettings)
 {
 }