public CalculateArcDurationTwoViewModel(INavigationService navigationService, IDataService dataService, IEventAggregator eventAggregator, IUnityContainer container, IArcDuration arcDuration, ICalculatorService calculatorService, ICalculationInput calculationInput, ICalculationOutput calculationOutput)
 {
     _inModal           = true;
     _navigationService = navigationService;
     _dataService       = dataService;
     _arcDuration       = arcDuration as ArcDuration;
     _calculationInput  = calculationInput as CalculationInput;
     _calculationOutput = calculationOutput as CalculationOutput;
     _calculatorService = calculatorService;
     _container         = container;
     _eventAggregator   = eventAggregator;
     _eventAggregator.GetEvent <ArcDurationUpdated>().Subscribe(UpdateArcDuration);
     _eventAggregator.GetEvent <CalculationInputUpdated>().Subscribe(HandleCalculationInputUpdated, ThreadOption.UIThread, false, obj => obj.IsArcDurationCalculated == true);
     _eventAggregator.GetEvent <CalculationOutputUpdated>().Subscribe(HandleCalculationOutputUpdated);
 }
コード例 #2
0
 public CalculationInput(IEventAggregator eventAggregator, IValidator <CalculationInput> validator, IArcDuration arcDuration)
 {
     _eventAggregator = eventAggregator;
     _validator       = validator;
     _arcDuration     = arcDuration as ArcDuration;
 }