public OnDemandProcessingResult Execute(IRenderingExtension newRenderer)
        {
            ExecutionLogContext executionLogContext = new ExecutionLogContext(m_publicProcessingContext.JobContext);

            executionLogContext.StartProcessingTimer();
            ProcessingErrorContext processingErrorContext = new ProcessingErrorContext();
            CultureInfo            currentCulture         = Thread.CurrentThread.CurrentCulture;

            try
            {
                bool                eventInfoChanged       = false;
                bool                renderingInfoChanged   = false;
                UserProfileState    userProfileState       = UserProfileState.None;
                Hashtable           renderProperties       = PublicRenderingContext.GetRenderProperties(IsSnapshotReprocessing);
                NameValueCollection reportServerParameters = FormServerParameterCollection(PublicRenderingContext.ReportContext.RSRequestParameters.CatalogParameters);
                PrepareForExecution();
                ProcessReport(processingErrorContext, executionLogContext, ref userProfileState);
                Microsoft.ReportingServices.OnDemandReportRendering.RenderingContext odpRenderingContext = null;
                try
                {
                    Microsoft.ReportingServices.OnDemandReportRendering.Report report = PrepareROM(out odpRenderingContext);
                    executionLogContext.StartRenderingTimer();
                    renderingInfoChanged = InvokeRenderer(newRenderer, report, reportServerParameters, RenderingParameters, PublicRenderingContext.ReportContext.RSRequestParameters.BrowserCapabilities, ref renderProperties, PublicProcessingContext.CreateStreamCallback);
                    UpdateServerTotalPages(newRenderer, ref renderProperties);
                    UpdateEventInfo(odpRenderingContext, PublicRenderingContext, ref eventInfoChanged);
                }
                catch (ReportProcessing.DataCacheUnavailableException)
                {
                    throw;
                }
                catch (ReportRenderingException rex)
                {
                    ReportProcessing.HandleRenderingException(rex);
                }
                catch (RSException)
                {
                    throw;
                }
                catch (Exception ex3)
                {
                    if (AsynchronousExceptionDetection.IsStoppingException(ex3))
                    {
                        throw;
                    }
                    throw new UnhandledReportRenderingException(ex3);
                }
                finally
                {
                    FinallyBlockForProcessingAndRendering(odpRenderingContext, executionLogContext);
                }
                CleanupSuccessfulProcessing(processingErrorContext);
                return(ConstructProcessingResult(eventInfoChanged, renderProperties, processingErrorContext, userProfileState, renderingInfoChanged, executionLogContext));
            }
            catch (ReportProcessing.DataCacheUnavailableException)
            {
                throw;
            }
            catch (RSException)
            {
                CleanupForException();
                throw;
            }
            catch (Exception innerException)
            {
                CleanupForException();
                throw new ReportProcessingException(innerException, processingErrorContext.Messages);
            }
            finally
            {
                FinalCleanup();
                ReportProcessing.UpdateHostingEnvironment(processingErrorContext, PublicProcessingContext.ReportContext, executionLogContext, RunningProcessingEngine, PublicProcessingContext.JobContext);
                if (currentCulture != null)
                {
                    Thread.CurrentThread.CurrentCulture = currentCulture;
                }
            }
        }