private void RaiseMinorStatusUpdate(OperationsState type, ProgressUpdateMode mode) { try { _sessionEventsSubject.OnNext(new MinorSessionUpdateEventArgs(type, mode)); } catch (Exception e) { Console.WriteLine(e); } }
private void SetState(OperationsState state) { if (_viewModel.OperationsState != state) { _viewModel.OperationsState = state; _viewModel.OperationsStateDescription = FunctionalExt.ValuedSwitch <OperationsState, string>(state) .Case(OperationsState.None, "") .Case(OperationsState.TestingPaused, "Paused") .Case(OperationsState.Finished, "Finished:" + _viewModel.OperationsStateDescription) .Case(OperationsState.PreCheck, "Pre-check...") .Case(OperationsState.Mutating, "Creating mutants...") .Case(OperationsState.Pausing, "Pausing...") .Case(OperationsState.Stopping, "Stopping...") .Case(OperationsState.Error, "Error occurred.") .GetResult(); } }
public SessionEventArgs(OperationsState eventType) { _eventType = eventType; }
public TestingProgressEventArgs(OperationsState eventType) : base(eventType) { }
public MutationScoreInfoEventArgs(OperationsState eventType) : base(eventType) { }
public MinorSessionUpdateEventArgs(OperationsState eventType, ProgressUpdateMode progressUpdateMode) : base(eventType) { _progressUpdateMode = progressUpdateMode; _percentCompleted = 0; }
public MinorSessionUpdateEventArgs(OperationsState eventType, int progress = 0) : base(eventType) { _progressUpdateMode = ProgressUpdateMode.SetValue; _percentCompleted = progress; }
public MutationFinishedEventArgs(OperationsState eventType) : base(eventType) { }
private void SetState(OperationsState state) { if (_viewModel.OperationsState != state) { _viewModel.OperationsState = state; _viewModel.OperationsStateDescription = FunctionalExt.ValuedSwitch<OperationsState, string>(state) .Case(OperationsState.None, "") .Case(OperationsState.TestingPaused, "Paused") .Case(OperationsState.Finished, "Finished:" + _viewModel.OperationsStateDescription) .Case(OperationsState.PreCheck, "Pre-check...") .Case(OperationsState.Mutating, "Creating mutants...") .Case(OperationsState.Pausing, "Pausing...") .Case(OperationsState.Stopping, "Stopping...") .Case(OperationsState.Error, "Error occurred.") .GetResult(); } }