public class ReportEngine extends java.lang.Object implements IReportEngine
org.eclipes.birt.report.engine.api.ReportRunner| Modifier and Type | Field and Description |
|---|---|
protected IReportEngine |
engine
the report engine.
|
protected static java.util.logging.Logger |
logger
the logger
|
| Constructor and Description |
|---|
ReportEngine(EngineConfig config)
Constructor.
|
| Modifier and Type | Method and Description |
|---|---|
void |
changeLogLevel(java.util.logging.Level newLevel)
Change the log level to newLevel
|
IDataExtractionTask |
createDataExtractionTask(IReportDocument reportDocument)
creates a task that allows data extraction from a report document
|
IDatasetPreviewTask |
createDatasetPreviewTask() |
IEngineTask |
createEngineTask(java.lang.String taskName)
create an engine task
|
IGetParameterDefinitionTask |
createGetParameterDefinitionTask(IReportRunnable reportRunnable)
creates an engine task for obtaining report parameter definitions
|
IGetParameterDefinitionTask |
createGetParameterDefinitionTask(IRunnable reportRunnable)
creates an engine task for obtaining report parameter definitions
|
IRenderTask |
createRenderTask(IReportDocument reportDocument)
creates a task that renders the report to a specific output format.
|
IRenderTask |
createRenderTask(IReportDocument reportDocument,
IReportRunnable reportRunnable)
create a task that renders the report to a specific output format.
|
IRunAndRenderTask |
createRunAndRenderTask(IReportRunnable reportRunnable)
creates an engine task for running and rendering report directly to
output format
|
IRunTask |
createRunTask(IReportRunnable reportRunnable)
creates a task to run a report to generate a report document
|
void |
destroy()
shuts down the report engine
|
EngineConfig |
getConfig()
returns the engine configuration object
|
DataExtractionFormatInfo[] |
getDataExtractionFormatInfo()
Returns data extraction extension information.
|
EmitterInfo[] |
getEmitterInfo()
Return all the emitter information which BIRT Engine can load.
|
java.util.logging.Logger |
getLogger()
get the logger used by report engine
|
java.lang.String |
getMIMEType(java.lang.String format)
the MIME type for the specific formatted supported by the extension.
|
java.lang.Object |
getRootScope()
get the root scope used by the engine
|
java.lang.String[] |
getSupportedFormats()
returns all supported output formats through BIRT engine emitter
extensions
|
java.lang.String |
getVersion()
get the BIRT version
|
IDocumentWriter |
openDocumentWriter(IArchiveFile file)
creates a document writer that can write this archive file
|
IReportRunnable |
openReportDesign(ReportDesignHandle designHandle)
opens a report designHandle and creates a report design runnable.
|
IReportRunnable |
openReportDesign(java.lang.String designName)
opens a report design file and creates a report design runnable.
|
IReportRunnable |
openReportDesign(java.lang.String name,
java.io.InputStream designStream)
opens a report design stream and creates a report design runnable.
|
IReportRunnable |
openReportDesign(java.lang.String name,
java.io.InputStream designStream,
IResourceLocator locator)
opens a report design stream and creates a report design runnable.
|
IReportRunnable |
openReportDesign(java.lang.String designName,
IResourceLocator locator)
opens a report design file and creates a report design runnable.
|
IReportDocument |
openReportDocument(java.lang.String fileName)
opens a report document and returns an IReportDocument object, from which
further information can be retrieved.
|
IReportDocument |
openReportDocument(java.lang.String systemId,
IDocArchiveReader reader,
java.util.Map options)
opens a report document and returns an IReportDocument object, from which
further information can be retrieved.
|
IReportDocument |
openReportDocument(java.lang.String fileName,
IResourceLocator locator)
opens a report document and returns an IReportDocument object, from which
further information can be retrieved.
|
IReportDocument |
openReportDocument(java.lang.String systemId,
java.lang.String fileName)
opens a report document and returns an IReportDocument object, from which
further information can be retrieved.
|
IReportDocument |
openReportDocument(java.lang.String systemId,
java.lang.String fileName,
IResourceLocator locator)
opens a report document and returns an IReportDocument object, from which
further information can be retrieved.
|
void |
setLogger(java.util.logging.Logger logger)
set the logger used by report engine.
|
void |
shutdown()
Deprecated.
|
protected static java.util.logging.Logger logger
protected IReportEngine engine
public ReportEngine(EngineConfig config)
config - an engine configuration object used to configure the enginepublic java.lang.Object getRootScope()
getRootScope in interface IReportEnginepublic void changeLogLevel(java.util.logging.Level newLevel)
changeLogLevel in interface IReportEnginenewLevel - -
new log levelpublic EngineConfig getConfig()
getConfig in interface IReportEnginepublic IReportRunnable openReportDesign(java.lang.String designName) throws EngineException
openReportDesign in interface IReportEnginedesignName - the full path of the report design fileEngineException - throwed when the input file does not exist, or the file is
invalidpublic IReportRunnable openReportDesign(ReportDesignHandle designHandle) throws EngineException
openReportDesign in interface IReportEnginedesignHandle - EngineExceptionpublic IReportRunnable openReportDesign(java.lang.String name, java.io.InputStream designStream) throws EngineException
openReportDesign in interface IReportEnginename - system id of the report designdesignStream - input stream of the report designEngineException - throwed when the input stream is null, or the stream does not
yield a valid report designpublic IRunAndRenderTask createRunAndRenderTask(IReportRunnable reportRunnable)
createRunAndRenderTask in interface IReportEnginereportRunnable - the runnable report design objectpublic IGetParameterDefinitionTask createGetParameterDefinitionTask(IRunnable reportRunnable)
createGetParameterDefinitionTask in interface IReportEnginereportRunnable - the runnable report design objectpublic IGetParameterDefinitionTask createGetParameterDefinitionTask(IReportRunnable reportRunnable)
createGetParameterDefinitionTask in interface IReportEnginereportRunnable - the runnable report design objectpublic java.lang.String[] getSupportedFormats()
getSupportedFormats in interface IReportEnginepublic EmitterInfo[] getEmitterInfo()
getEmitterInfo in interface IReportEnginepublic java.lang.String getMIMEType(java.lang.String format)
getMIMEType in interface IReportEngineformat - the output formatextensionID - the extension ID, which could be null if only one plugin
supports the output formatpublic void destroy()
destroy in interface IReportEnginepublic IRunTask createRunTask(IReportRunnable reportRunnable)
createRunTask in interface IReportEnginereportRunnable - the runnable report design objectpublic IRenderTask createRenderTask(IReportDocument reportDocument)
createRenderTask in interface IReportEnginereportDocument - a handle to an IReportDocument objectpublic IReportDocument openReportDocument(java.lang.String fileName) throws EngineException
openReportDocument in interface IReportEnginefileName - the report document name. report document is an archive in
BIRT.EngineException - throwed when the report document archive does not exist, or
the file is not a valud report documentpublic IDataExtractionTask createDataExtractionTask(IReportDocument reportDocument)
createDataExtractionTask in interface IReportEnginereportDocument - a handle to an IReportDocument objectpublic void shutdown()
shutdown in interface IReportEnginepublic IReportDocument openReportDocument(java.lang.String systemId, java.lang.String fileName) throws EngineException
openReportDocument in interface IReportEnginesystemId - the system id the opend document. It is used to access the resources with
relative path in the report document. If it is NULL, a saved one is used.fileName - the report document name. report document is an archive in
BIRT.EngineException - throwed when the report document archive does not exist, or
the file is not a valid report documentpublic IReportRunnable openReportDesign(java.lang.String designName, IResourceLocator locator) throws EngineException
openReportDesign in interface IReportEnginedesignName - the full path of the report design filelocator - the resource locator used to locate files referenced in the designEngineException - throwed when the input file does not exist, or the file is
invalidpublic IReportRunnable openReportDesign(java.lang.String name, java.io.InputStream designStream, IResourceLocator locator) throws EngineException
openReportDesign in interface IReportEnginename - system id of the report designdesignStream - input stream of the report designlocator - the resource locator used to locate files referenced in the designEngineException - throwed when the input stream is null, or the stream does not
yield a valid report designpublic IReportDocument openReportDocument(java.lang.String fileName, IResourceLocator locator) throws EngineException
openReportDocument in interface IReportEnginefileName - the report document name. report document is an archive in
BIRT.locator - the resource locator used to locate files referenced in the designEngineException - throwed when the report document archive does not exist, or
the file is not a valud report documentpublic IReportDocument openReportDocument(java.lang.String systemId, java.lang.String fileName, IResourceLocator locator) throws EngineException
openReportDocument in interface IReportEnginesystemId - the system id the opend document. It is used to access the resources with
relative path in the report document. If it is NULL, a saved one is used.fileName - the report document name. report document is an archive in
BIRT.locator - the resource locator used to locate files referenced in the designEngineException - throwed when the report document archive does not exist, or
the file is not a valud report documentpublic IReportDocument openReportDocument(java.lang.String systemId, IDocArchiveReader reader, java.util.Map options) throws EngineException
openReportDocument in interface IReportEnginesystemId - the system id the opend document. It is used to access the resources with
relative path in the report document. If it is NULL, a saved one is used.reader - a report archive for readingoptions - Map defines the options used to parse the design file.EngineException - throwed when the report document archive does not exist, or
the file is not a valid report documentpublic java.util.logging.Logger getLogger()
getLogger in interface IReportEnginepublic void setLogger(java.util.logging.Logger logger)
setLogger in interface IReportEnginelogger - public IRenderTask createRenderTask(IReportDocument reportDocument, IReportRunnable reportRunnable)
createRenderTask in interface IReportEnginereportDocument - a handle to an IReportDocument objectreportRunnable - the runnable report design objectpublic DataExtractionFormatInfo[] getDataExtractionFormatInfo()
getDataExtractionFormatInfo in interface IReportEnginepublic IDocumentWriter openDocumentWriter(IArchiveFile file) throws EngineException
openDocumentWriter in interface IReportEnginefile - the archive fileEngineExceptionpublic java.lang.String getVersion()
getVersion in interface IReportEnginepublic IEngineTask createEngineTask(java.lang.String taskName) throws EngineException
IReportEnginecreateEngineTask in interface IReportEnginetaskName - the extension name to identify a taskEngineExceptionpublic IDatasetPreviewTask createDatasetPreviewTask() throws EngineException
createDatasetPreviewTask in interface IReportEngineEngineExceptionCopyright © 2014 OpenText Corp. All rights reserved.