Understanding a report item extension
Use a report item extension to add a new report item type to the BIRT framework by implementing multiple extension points. A plug-in defining an extension point typically contains an XML extension point schema definition (.exsd) file in a schema subdirectory. This schema describes the elements, attributes, and types used by the extension point in the Eclipse PDE environment.
To support adding a new report item, a report item extension provides the following extension points:
*Report item model
org.eclipse.birt.report.model.reportItemModel specifies the report item extension point.
The XML schema file, org.eclipse.birt.report.model/schema/reportItem.exsd describes this extension point.
*Report item user interface
org.eclipse.birt.report.designer.ui.reportitemUI specifies the report item extension point for the user interface in the report layout editor and report item palette. The XML schema file, org.eclipse.birt.report.designer.ui
/schema/reportitemUI.exsd, describes this extension point.
*Report item query
org.eclipse.birt.report.engine.reportitemQuery specifies the extension point for query preparation support in BIRT Report Designer and the report engine. A query preparation extension is optional. The XML schema file, org.eclipse.birt.report.engine/schema/reportitemQuery.exsd, describes this extension point.
*Report item run time
org.eclipse.birt.report.engine.reportitemGeneration specifies the extension point for instantiating, processing, and persisting a new report item at report generation time. A run-time extension is optional. The XML schema file, org.eclipse.birt.report.engine/schema/reportitemGeneration.exsd, describes this extension point.
*Report item presentation
org.eclipse.birt.report.engine.reportitemPresentation specifies the extension point for instantiating, processing, and rendering a new report item at
report presentation time. The XML schema file, org.eclipse.birt
.report.engine/schema/reportitemPresentation.exsd, describes this extension point.
*Report item UI property page adapters
org.eclipse.birt.report.designer.ui.elementAdapters specifies the extension points for the adapters for the report item property page UI. The XML schema file, org.eclipse.birt.report.designer.ui/schema/elementAdapters.exsd, describes this extension point.
*Report item emitter
org.eclipse.birt.report.engine.emitters specifies the extension point for
support of a new output format in the presentation engine. An emitter extension is optional. The XML schema file, org.eclipse.birt.report.engine
/schema/emitters.exsd, describes this extension point.
At run time, the BIRT Report Engine performs the following processing on a report item before rendering the final output:
*Query preparation
Gathers the data binding information and expressions defined for the report, passing the information to the report engine. The data engine prepares the data access strategy based on this information.
*Generation
Creates the instances of report items and fetches the data.
*Presentation
Renders the report item to a supported data primitive, such as an image, string, HTML segment, or custom data component.
*Emitter
Converts the output to a specified format, such as HTML or PDF.
This section provides an example of a custom report item extension, org.eclipse.birt.sample.reportitem.rotatedlabel.
The standard report item plug-in, chart, is a more complex example of a report item extension. The BIRT chart plug-in implements user interface and report engine extensions that support a report design using any of the bar, line, pie, scatter, stock, or other chart types.
For reference documentation for the report item API, see the Javadoc for the org.eclipse.birt.report.engine.extension package in the BIRT Programmer Reference in Eclipse help.