public ReportBindingSource(ShadowMaker bigShadow, AsyncExceptionHandler exceptionHandler, ProjectManager manager) { this.aex = exceptionHandler; this.bigShadow = bigShadow; this.manager = manager; List = new ObservableCollection <ModelControl>(); AreCountersGlobalVisible = false; AreTrTimesGlobalVisible = false; }
public Analyst(ProjectManager clerk, ShadowMaker shadowMaker, AsyncExceptionHandler exceptionHandler) { this.aex = exceptionHandler; this.shadowMaker = shadowMaker; this.clerk = clerk; this.Host = new ReportBindingSource(shadowMaker, exceptionHandler, clerk); //this.Host.DrawModel += new EventHandler<EventArgs<UserControl, bool>>(Host_DrawModel); this.Host.DrawPoints += new EventHandler<EventArgs<UserControl>>(Host_DrawPoints); this.Host.DrawCounters += new EventHandler<EventArgs<UserControl>>(Host_DrawCounters); this.Host.GenerateCountersReport += new EventHandler<EventArgs<DataTableEx, Dispatcher>>(Host_GenerateCountersReport); this.Host.GenerateTrTimesReport += new EventHandler<EventArgs<DataTableEx, Dispatcher>>(Host_GenerateTrTimesReport); this.Host.DrawSections += new EventHandler<EventArgs<UserControl>>(Host_DrawSections); this.Host.DrawTrTimes += new EventHandler<EventArgs<UserControl>>(Host_DrawTrTimes); }
private AsyncExceptionHandler CreateExceptionHandler() { exceptionHandler = new AsyncExceptionHandler(this.Dispatcher); exceptionHandler.Exception += (sender, e) => { var exception = e.Value; string ownMessage = string.Empty; switch (exception.Message) { case "Aggregation for Data Collection not possible!": ownMessage = "This error means that no single parameter is selected for Data Collection evaluation.\n" + "To fix this error go to \"Data Collection - Configuration\" window\n" + "[Evaluation -> Files -> Data collection -> Configuration -> Configuration]\n" + "end select at least one parameter to evaluation"; break; } var result = MessageBox.Show(this, "An error occured. The following information might help you decide to try to continue your work or not." + "\n\nOriginal exception: " + exception.Message + (string.IsNullOrWhiteSpace(ownMessage) ? string.Empty : "\n\nRemark: " + ownMessage) + "\n\nPress [Yes] to try again or [No] to try to continue." , exception.GetType().ToString(), MessageBoxButton.YesNo, MessageBoxImage.Error); e.Param.Value = (result == MessageBoxResult.Yes); }; return exceptionHandler; }
public ProjectManager(Dispatcher disp, AsyncExceptionHandler exceptionHandler) { this.aex = exceptionHandler; this.defaultContext = disp; }
public Experimenter(string modelName, ProjectManager manager, AsyncExceptionHandler exceptionHandler) { this.aex = exceptionHandler; this.modelName = modelName; this.manager = manager; }