# Emitters that Support Report Rendering

###### Identifier:

org.eclipse.birt.report.engine.emitters

###### Since:

2.2.0

###### Description:

This extension point allows new output formats to be supported in presentation engine. The plugin registry uses this extension point registration to discover all supported output formats.

###### Configuration Markup:

<!ELEMENT extension (emitter+)>

<!ATTLIST extension

point CDATA #REQUIRED

id CDATA #IMPLIED

name CDATA #IMPLIED

>

root element for the emitters extension

- point - a fully qualified identifier of the target extension point
- id - an optional identifier of the extension instance
- name - an optional name of the extension instance

<!ELEMENT emitter (reportItem*)>

<!ATTLIST emitter

id CDATA #IMPLIED

class CDATA #REQUIRED

format CDATA #REQUIRED

icon CDATA #IMPLIED

mimeType CDATA #REQUIRED

supportedImageFormats CDATA #IMPLIED

pagination (no-pagination|page-break-pagination|paper-size-pagination)

outputDisplayNone (true | false)

isHidden (true | false)

needOutputResultSet (true | false)

>

an emitter that exports one or more output formats

- id - an optional identifier of the emitter extension
- class - the java class that implements the `IContentEmitter` interface
- format - The output format that the emitter supports
- icon - The icon path of the emitter
- mimeType - The MIME type for the supported output format
- supportedImageFormats - The supported image formats
- pagination - Pagination of output.
  When "page-break-pagination" is set, pagination is based on page break configuration.It is the default value of pagination.
  When "no-pagination" is set, content in the report is output as they are in one page.
  When "paper-size-pagination" is set, pagination is created based on contents size.
- outputDisplayNone -
- isHidden - Used to determine whether format is shown in UI
- needOutputResultSet - Represents if the emitter needs to output query result set.

<!ELEMENT reportItem EMPTY>

<!ATTLIST reportItem

name CDATA #REQUIRED

class CDATA #REQUIRED

id CDATA #IMPLIED

>

allows a developer to define emitter for a report item. Used mainly for extended item, but can also be used for standard report items.

- name - the name of the report item that the emitterClass supports. For example, "chart" for chart extension item
- class - the emitter class that supports this type of report item for a specific format
- id - an optional identifier of the report item emitter extension

###### Examples:

The following is a sample usage of the emitterSet extension point:

    <extension
     point="org.eclipse.birt.report.engine.emitterSet"
     name = "Engine Emitters">
     <emitter
      format="HTML"
      id="org.eclipse.birt.report.engine.emitter.html"
      class="org.eclipse.birt.report.engine.emitter.html.HTMLReportEmitter">
      <reportItem name="chart"
       id="org.eclipse.birt.report.engine.emitter.chart.html"
       class="org.eclipse.birt.report.engine.emitter.html.HTMLChartEmitter">
      </reportItem>
     </emitter>
     <emitter
      format="FO"
      mimeType="text/html"
      pagination="no-page"
      id="org.eclipse.birt.report.engine.emitter.fo"
      class="org.eclipse.birt.report.engine.emitter.html.FOReportEmitter">
      <reportItem name="chart"
         id="org.eclipse.birt.report.engine.emitter.chart.fo"
       Class="org.eclipse.birt.report.engine.emitter.html.FOChartEmitter"/>
     </emitter>
     <emitter
      mimeType="application/pdf"
      id="org.eclipse.birt.report.engine.emitter.pdf"
      class="org.eclipse.birt.report.engine.emitter.html.FOPReportEmitter">
      <reportItem name="chart"
       id="org.eclipse.birt.report.engine.emitter.chart.pdf"
       emitterClass="org.eclipse.birt.report.engine.emitter.html.FOChartEmitter"/>
      </emitter>
    </extension>

Notice that in this example, the same class is used for both PDF and FO format. BIRT currently uses FO to generate both FO and PDF output.

###### API Information:

The value of the class attribute for the emitter element must be the fully qualified name of a class that implement `org.eclipse.birt.engine.emitter.IContentEmitter`.

The value of the emitterClass attribute for the reportItem element must be a fully qualified name of a class that implements `org.eclipse.birt.engine.extension.IReportItemEmitter`.

###### Supplied Implementation:

`org.eclipse.birt.report.engine.emitter.html.HTMLReportEmitter` ---- An HTML emitter that supports report rendering to HTML format. `org.eclipse.birt.report.engine.layout.impl.ReportLayoutEngine` ---- An emitter that supports report rendering to PDF format.

Copyright (c) 2005 Actuate Corporation. All rights reserved. This program and the accompanying materials are made available under the terms of the Eclipse Public License v1.0 which accompanies this distribution, and is available at http://www.eclipse.org/legal/epl-v10.html
Contributors: Actuate Corporation - initial API and implementation