示例#1
0
        protected override ISimulationAnalysisPresenter PresenterFor(ISimulationAnalysis simulationAnalysis, IContainer container)
        {
            if (simulationAnalysis.IsAnImplementationOf <SimulationTimeProfileChart>())
            {
                return(container.Resolve <ISimulationTimeProfileChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <BoxWhiskerAnalysisChart>())
            {
                return(container.Resolve <IEditBoxWhiskerAnalysisChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ScatterAnalysisChart>())
            {
                return(container.Resolve <IEditScatterAnalysisChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <RangeAnalysisChart>())
            {
                return(container.Resolve <IEditRangeAnalysisChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <TimeProfileAnalysisChart>())
            {
                return(container.Resolve <IEditTimeProfileAnalysisChartPresenter>());
            }

            return(null);
        }
        public ISimulationAnalysisPresenter PresenterFor(ISimulationAnalysis simulationAnalysis)
        {
            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationTimeProfileChart>())
            {
                return(_container.Resolve <IParameterIdentificationTimeProfileChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationResidualVsTimeChart>())
            {
                return(_container.Resolve <IParameterIdentificationResidualVsTimeChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationResidualHistogram>())
            {
                return(_container.Resolve <IParameterIdentificationResidualHistogramPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationPredictedVsObservedChart>())
            {
                return(_container.Resolve <IParameterIdentificationPredictedVsObservedChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationCorrelationMatrix>())
            {
                return(_container.Resolve <IParameterIdentificationCorrelationAnalysisPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationCovarianceMatrix>())
            {
                return(_container.Resolve <IParameterIdentificationCovarianceAnalysisPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationTimeProfileConfidenceIntervalChart>())
            {
                return(_container.Resolve <IParameterIdentificationTimeProfileConfidenceIntervalChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationTimeProfilePredictionIntervalChart>())
            {
                return(_container.Resolve <IParameterIdentificationTimeProfilePredictionIntervalChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationTimeProfileVPCIntervalChart>())
            {
                return(_container.Resolve <IParameterIdentificationTimeProfileVPCIntervalChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <ParameterIdentificationTimeProfileConfidenceIntervalChart>())
            {
                return(_container.Resolve <IParameterIdentificationTimeProfileConfidenceIntervalChartPresenter>());
            }

            if (simulationAnalysis.IsAnImplementationOf <SensitivityAnalysisPKParameterAnalysis>())
            {
                return(_container.Resolve <ISensitivityAnalysisPKParameterAnalysisPresenter>());
            }


            var specificPresenter = PresenterFor(simulationAnalysis, _container);

            if (specificPresenter != null)
            {
                return(specificPresenter);
            }

            throw new ArgumentException(Error.CannotCreateChartPresenterForChart(simulationAnalysis.GetType()));
        }