ReportRunnable report = executionContext.getRunnable( );
	protected void doRun( ) throws EngineException	{		setRunningFlag( true );		ReportRunnable report = executionContext.getRunnable( );		// using paramters		if ( !validateParameters( ) )		{			setRunningFlag( false );			throw new EngineException(					MessageConstants.INVALID_PARAMETER_EXCEPTION ); //$NON-NLS-1$		}		loadDesign( );		prepareDesign( );		startFactory( );		openReportDocument( );		try		{			writer.saveDesign( report );			writer.saveParamters( inputValues );			executionContext.openDataEngine( );			synchronized(this)			{				if (!executionContext.isCanceled( ))				{					documentBuilder = new ReportDocumentBuilder(							executionContext, writer );				}			}						if ( documentBuilder != null )			{				if ( pageHandler != null )				{					documentBuilder.setPageHandler( pageHandler );				}				IContentEmitter emitter = documentBuilder.getContentEmitter( );				ReportExecutor executor = new ReportExecutor( executionContext,						report.getReportIR( ),						emitter );//				IReportExecutor lExecutor = new LocalizedReportExecutor( executionContext,//						executor );				executionContext.setExecutor( executor );				initializeContentEmitter( emitter, executor );				documentBuilder.build( );			}									executionContext.closeDataEngine( );			writer.savePersistentObjects( executionContext.getGlobalBeans( ) );		}		catch ( Exception ex )		{			log.log( Level.SEVERE,					"An error happened while running the report. Cause:", ex ); //$NON-NLS-1$			throw new EngineException(					"Error happended while running the report", ex );		}		catch ( OutOfMemoryError err )		{			log.log( Level.SEVERE,					"An OutOfMemory error happened while running the report." ); //$NON-NLS-1$			throw err;		}		finally		{			documentBuilder = null;			closeReportDocument();			closeFactory();			setRunningFlag( false );		}	}