private void InitAndAddProstprocessorHandler(
            ViewControlId postprocessorViewId,
            PostprocessorKind postprocessorKind
            )
        {
            IViewControlHandler handler;

            if (postprocessorViewId == ViewControlId.Correlate)
            {
                handler = new CorrelatorPostprocessorControlHandler(
                    correlationManager,
                    tempFiles,
                    shellOpen
                    );
            }
            else
            {
                handler = new LogSourcePostprocessorControlHandler(
                    postprocessorsManager,
                    postprocessorKind,
                    () =>
                    postprocessorKind == PostprocessorKind.StateInspector ? presentersFactory.GetStateInspectorVisualizer(true) :
                    postprocessorKind == PostprocessorKind.Timeline ? presentersFactory.GetTimelineVisualizer(true) :
                    postprocessorKind == PostprocessorKind.SequenceDiagram ? presentersFactory.GetSequenceDiagramVisualizer(true) :
                    postprocessorKind == PostprocessorKind.TimeSeries ? presentersFactory.GetTimeSeriesVisualizer(true) :
                    (IPostprocessorVisualizerPresenter)null,
                    shellOpen,
                    tempFiles
                    );
            }
            viewControlHandlers.Add(postprocessorViewId, handler);
        }
Exemplo n.º 2
0
        private void InitAndAddProstprocessorHandler(
            Dictionary <ViewControlId, IViewControlHandler> handlers,
            ViewControlId postprocessorViewId,
            IManager postprocessorsManager,
            IPostprocessorOutputFormFactory outputFormsFactory,
            PostprocessorKind postprocessorKind
            )
        {
            IViewControlHandler handler;

            if (postprocessorViewId == ViewControlId.Correlate)
            {
                handler = new CorrelatorPostprocessorControlHandler(
                    postprocessorsManager,
                    tempFiles,
                    shellOpen
                    );
            }
            else
            {
                handler = new LogSourcePostprocessorControlHandler(
                    postprocessorsManager,
                    postprocessorKind,
                    () => outputFormsFactory.GetPostprocessorOutputForm(postprocessorViewId),
                    shellOpen,
                    tempFiles
                    );
            }
            handlers.Add(postprocessorViewId, handler);
        }