public class JROdtExporter extends JRAbstractExporter<OdtReportConfiguration,OdtExporterConfiguration,OutputStreamExporterOutput,JROdtExporterContext>
.odt
is the
file extension used for the word processing documents in the Open Document Format, and such
files can be obtained in JasperReports using the
JROdtExporter
class.
Currently, there are the following special configurations that can be applied to an ODT
exporter instance (see DocxReportConfiguration
) to customize
its behavior:
isFlexibleRowHeight()
exporter configuration flag, or its corresponding exporter hint called
net.sf.jasperreports.export.odt.flexible.row.height
.isIgnoreHyperlink()
exporter configuration flag, or its corresponding exporter hint called
net.sf.jasperreports.export.odt.ignore.hyperlink
OdtReportConfiguration
Modifier and Type | Class and Description |
---|---|
protected class |
JROdtExporter.ExporterContext |
protected class |
JROdtExporter.OdtDocumentBuilder |
JRAbstractExporter.BaseExporterContext, JRAbstractExporter.PageRange
Modifier and Type | Field and Description |
---|---|
protected Color |
backcolor |
protected LinkedList<Color> |
backcolorStack |
protected Map<Integer,String> |
columnStyles |
protected DocumentBuilder |
documentBuilder |
protected String |
invalidCharReplacement |
protected ExporterNature |
nature |
static String |
ODT_EXPORTER_KEY
The exporter key, as used in
GenericElementHandlerEnviroment.getElementHandler(JRGenericElementType, String) . |
protected static String |
ODT_EXPORTER_PROPERTIES_PREFIX |
protected int |
pageFormatIndex |
protected int |
pageIndex |
static String |
PROPERTY_IGNORE_HYPERLINK
Deprecated.
Replaced by
OdtReportConfiguration.PROPERTY_IGNORE_HYPERLINK . |
protected int |
reportIndex |
protected Map<Integer,String> |
rowStyles |
protected boolean |
startPage |
protected StyleCache |
styleCache |
protected int |
tableIndex |
protected WriterHelper |
tempBodyWriter |
protected WriterHelper |
tempStyleWriter |
allSelector, crtCompositeConfiguration, crtCompositeItemConfiguration, crtItem, dateFormatCache, EXCEPTION_MESSAGE_KEY_END_PAGE_INDEX_OUT_OF_RANGE, EXCEPTION_MESSAGE_KEY_INVALID_IMAGE_NAME, EXCEPTION_MESSAGE_KEY_INVALID_ZOOM_RATIO, EXCEPTION_MESSAGE_KEY_MIXED_CALLS_NOT_ALLOWED, EXCEPTION_MESSAGE_KEY_OUTPUT_WRITER_ERROR, EXCEPTION_MESSAGE_KEY_PAGE_INDEX_OUT_OF_RANGE, EXCEPTION_MESSAGE_KEY_START_PAGE_INDEX_OUT_OF_RANGE, exporterConfiguration, exporterContext, exporterInput, exporterOutput, filter, fontUtil, itemConfiguration, jasperPrint, jasperReportsContext, noBackcolorSelector, noneSelector, numberFormatCache, parameters, propertiesUtil, PROPERTY_DEFAULT_FILTER_FACTORY, PROPERTY_SUFFIX_DEFAULT_FILTER_FACTORY, rendererUtil, styledTextUtil, textValueClasses
Constructor and Description |
---|
JROdtExporter() |
JROdtExporter(JasperReportsContext jasperReportsContext) |
createFilter, defaultParseNumber, ensureInput, ensureJasperReportsContext, getBooleanCellValue, getCurrentConfiguration, getCurrentItemConfiguration, getCurrentJasperPrint, getCustomHandler, getDateCellValue, getDateFormat, getExporterContext, getExporterInput, getExporterOutput, getHyperlinkProducer, getJasperReportsContext, getLocale, getNumberCellValue, getNumberFormat, getOffsetX, getOffsetY, getPageRange, getParameter, getParameters, getPropertiesUtil, getRendererUtil, getReportContext, getStyledText, getStyledText, getTextFormatFactoryClass, getTextLocale, getTextTimeZone, getTextValue, getTextValueString, insideFrame, reset, resetClassLoader, resetExportContext, restoreElementOffsets, setClassLoader, setConfiguration, setConfiguration, setCurrentExporterInputItem, setExporterInput, setExporterOutput, setFrameElementsOffset, setJasperPrint, setJasperReportsContext, setOffset, setOffset, setParameter, setParameters, setReportContext
public static final String ODT_EXPORTER_KEY
GenericElementHandlerEnviroment.getElementHandler(JRGenericElementType, String)
.protected static final String ODT_EXPORTER_PROPERTIES_PREFIX
public static final String PROPERTY_IGNORE_HYPERLINK
OdtReportConfiguration.PROPERTY_IGNORE_HYPERLINK
.protected WriterHelper tempBodyWriter
protected WriterHelper tempStyleWriter
protected int reportIndex
protected int pageFormatIndex
protected int pageIndex
protected int tableIndex
protected boolean startPage
protected String invalidCharReplacement
protected LinkedList<Color> backcolorStack
protected Color backcolor
protected DocumentBuilder documentBuilder
protected StyleCache styleCache
protected ExporterNature nature
public JROdtExporter()
JROdtExporter(JasperReportsContext)
public JROdtExporter(JasperReportsContext jasperReportsContext)
protected Class<OdtExporterConfiguration> getConfigurationInterface()
protected Class<OdtReportConfiguration> getItemConfigurationInterface()
protected void ensureOutput()
public void exportReport() throws JRException
Exporter
exportReport
in interface Exporter<ExporterInput,OdtReportConfiguration,OdtExporterConfiguration,OutputStreamExporterOutput>
exportReport
in class JRAbstractExporter<OdtReportConfiguration,OdtExporterConfiguration,OutputStreamExporterOutput,JROdtExporterContext>
JRException
protected void initExport()
protected void initReport()
protected void exportReportToOasisZip(OutputStream os) throws JRException, IOException
JRException
IOException
protected void exportPage(JRPrintPage page) throws JRException, IOException
JRException
IOException
protected void exportGrid(JRGridLayout gridLayout, JRPrintElementIndex frameIndex) throws IOException, JRException
IOException
JRException
protected void exportFrame(TableBuilder tableBuilder, JRPrintFrame frame, JRExporterGridCell gridCell) throws IOException, JRException
IOException
JRException
protected void setBackcolor(Color color)
protected void restoreBackcolor()
protected void exportRectangle(TableBuilder tableBuilder, JRPrintRectangle rectangle, JRExporterGridCell gridCell)
protected void exportLine(TableBuilder tableBuilder, JRPrintLine line, JRExporterGridCell gridCell)
protected void exportEllipse(TableBuilder tableBuilder, JRPrintEllipse ellipse, JRExporterGridCell gridCell)
public void exportText(TableBuilder tableBuilder, JRPrintText text, JRExporterGridCell gridCell)
public void exportImage(TableBuilder tableBuilder, JRPrintImage image, JRExporterGridCell gridCell) throws JRException
JRException
protected void insertPageAnchor(TableBuilder tableBuilder)
protected void exportGenericElement(TableBuilder tableBuilder, JRGenericPrintElement element, JRExporterGridCell gridCell) throws IOException, JRException
IOException
JRException
public String getExporterKey()
public String getExporterPropertiesPrefix()
JRAbstractExporter
getExporterPropertiesPrefix
in class JRAbstractExporter<OdtReportConfiguration,OdtExporterConfiguration,OutputStreamExporterOutput,JROdtExporterContext>
Copyright © 2017. All rights reserved.