net.sf.jasperreports.engine.xml
Class JRXmlWriter

java.lang.Object
  extended by net.sf.jasperreports.engine.xml.JRXmlBaseWriter
      extended by net.sf.jasperreports.engine.xml.JRXmlWriter

public class JRXmlWriter
extends JRXmlBaseWriter

Version:
$Id: JRXmlWriter.java 2006 2007-12-05 14:28:33Z teodord $
Author:
Teodor Danciu (teodord@users.sourceforge.net), Minor enhancements by Barry Klawans (bklawans@users.sourceforge.net)

Field Summary
 
Fields inherited from class net.sf.jasperreports.engine.xml.JRXmlBaseWriter
writer
 
Constructor Summary
protected JRXmlWriter(JRReport report, java.lang.String encoding)
           
 
Method Summary
protected  boolean toWriteConditionalStyles()
          Decides whether conditional styles are to be written.
 void writeAreaChart(JRChart chart)
           
 void writeAxisFormat(java.lang.String axisFormatElementName, JRFont axisLabelFont, java.awt.Color axisLabelColor, JRFont axisTickLabelFont, java.awt.Color axisTickLabelColor, java.lang.String axisTickLabelMask, java.awt.Color axisLineColor)
          Writes out the axis format block for a chart axis.
 void writeBar3DChart(JRChart chart)
           
 void writeBar3DPlot(JRBar3DPlot plot)
           
 void writeBarChart(JRChart chart)
           
 void writeBreak(JRBreak breakElement)
           
 void writeBubbleChart(JRChart chart)
           
protected  void writeBucket(JRCrosstabBucket bucket)
           
 void writeCandlestickChart(JRChart chart)
           
protected  void writeCellContents(JRCellContents contents)
           
 void writeChartTag(JRChart chart)
           
 void writeCrosstab(JRCrosstab crosstab)
           
protected  void writeCrosstabCell(JRCrosstabCell cell)
           
protected  void writeCrosstabColumnGroup(JRCrosstabColumnGroup group)
           
protected  void writeCrosstabMeasure(JRCrosstabMeasure measure)
           
protected  void writeCrosstabParameter(JRCrosstabParameter parameter)
           
protected  void writeCrosstabRowGroup(JRCrosstabRowGroup group)
           
 void writeDataRange(JRDataRange dataRange)
          Writes a data range block to the output stream.
 void writeDataset(JRDataset dataset)
           
protected  void writeDatasetContents(JRDataset dataset)
           
protected  void writeDatasetRun(JRDatasetRun datasetRun)
           
 void writeElementGroup(JRElementGroup elementGroup)
           
 void writeEllipse(JREllipse ellipse)
           
 void writeFrame(JRFrame frame)
           
 void writeHighLowChart(JRChart chart)
           
 void writeHighLowDataset(JRHighLowDataset dataset)
           
protected  void writeHyperlink(java.lang.String tagName, JRHyperlink hyperlink)
           
protected  void writeHyperlinkParameter(JRHyperlinkParameter parameter)
           
protected  void writeHyperlinkParameters(JRHyperlinkParameter[] parameters)
           
 void writeImage(JRImage image)
           
 void writeLine(JRLine line)
           
 void writeLineChart(JRChart chart)
           
 void writeMeterChart(JRChart chart)
          Writes the definition of a meter chart to the output stream.
 void writeMultiAxisChart(JRChart chart)
          Writes the definition of a multiple axis chart to the output stream.
 void writePie3DChart(JRChart chart)
           
 void writePieChart(JRChart chart)
           
 void writePieDataset(JRPieDataset dataset)
           
 void writeRectangle(JRRectangle rectangle)
           
static void writeReport(JRReport report, java.io.OutputStream outputStream, java.lang.String encoding)
           
static java.lang.String writeReport(JRReport report, java.lang.String encoding)
           
static void writeReport(JRReport report, java.lang.String destFileName, java.lang.String encoding)
           
protected  void writeReport(java.io.Writer out)
           
 void writeScatterChart(JRChart chart)
           
 void writeStackedAreaChart(JRChart chart)
           
 void writeStackedBar3DChart(JRChart chart)
           
 void writeStackedBarChart(JRChart chart)
           
 void writeStaticText(JRStaticText staticText)
           
 void writeSubreport(JRSubreport subreport)
           
protected  void writeTemplate(JRReportTemplate template)
           
protected  void writeTemplates()
           
 void writeTextField(JRTextField textField)
           
 void writeThermometerChart(JRChart chart)
          Writes the description of a thermometer chart to the output stream.
 void writeTimeSeriesChart(JRChart chart)
           
 void writeValueDataset(JRValueDataset dataset)
          Writes the description of a value dataset to the output stream.
 void writeValueDisplay(JRValueDisplay valueDisplay)
          Writes the description of how to display a value in a valueDataset.
 void writeXyAreaChart(JRChart chart)
           
 void writeXyBarChart(JRChart chart)
           
 void writeXyLineChart(JRChart chart)
           
 
Methods inherited from class net.sf.jasperreports.engine.xml.JRXmlBaseWriter
useWriter, writeBox, writeConditionalStyle, writePen, writeStyle, writeStyleReferenceAttr
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

JRXmlWriter

protected JRXmlWriter(JRReport report,
                      java.lang.String encoding)
Method Detail

writeReport

public static java.lang.String writeReport(JRReport report,
                                           java.lang.String encoding)

writeReport

public static void writeReport(JRReport report,
                               java.lang.String destFileName,
                               java.lang.String encoding)
                        throws JRException
Throws:
JRException

writeReport

public static void writeReport(JRReport report,
                               java.io.OutputStream outputStream,
                               java.lang.String encoding)
                        throws JRException
Throws:
JRException

writeReport

protected void writeReport(java.io.Writer out)
                    throws java.io.IOException
Throws:
java.io.IOException

writeTemplates

protected void writeTemplates()
                       throws java.io.IOException
Throws:
java.io.IOException

writeTemplate

protected void writeTemplate(JRReportTemplate template)
                      throws java.io.IOException
Throws:
java.io.IOException

writeElementGroup

public void writeElementGroup(JRElementGroup elementGroup)
                       throws java.io.IOException
Throws:
java.io.IOException

writeBreak

public void writeBreak(JRBreak breakElement)
                throws java.io.IOException
Throws:
java.io.IOException

writeLine

public void writeLine(JRLine line)
               throws java.io.IOException
Throws:
java.io.IOException

writeRectangle

public void writeRectangle(JRRectangle rectangle)
                    throws java.io.IOException
Throws:
java.io.IOException

writeEllipse

public void writeEllipse(JREllipse ellipse)
                  throws java.io.IOException
Throws:
java.io.IOException

writeImage

public void writeImage(JRImage image)
                throws java.io.IOException
Throws:
java.io.IOException

writeStaticText

public void writeStaticText(JRStaticText staticText)
                     throws java.io.IOException
Throws:
java.io.IOException

writeTextField

public void writeTextField(JRTextField textField)
                    throws java.io.IOException
Throws:
java.io.IOException

writeSubreport

public void writeSubreport(JRSubreport subreport)
                    throws java.io.IOException
Throws:
java.io.IOException

writePieDataset

public void writePieDataset(JRPieDataset dataset)
                     throws java.io.IOException
Throws:
java.io.IOException

writeValueDataset

public void writeValueDataset(JRValueDataset dataset)
                       throws java.io.IOException
Writes the description of a value dataset to the output stream.

Parameters:
dataset - the value dataset to persist
Throws:
java.io.IOException

writeValueDisplay

public void writeValueDisplay(JRValueDisplay valueDisplay)
                       throws java.io.IOException
Writes the description of how to display a value in a valueDataset.

Parameters:
valueDisplay - the description to save
Throws:
java.io.IOException

writeDataRange

public void writeDataRange(JRDataRange dataRange)
                    throws java.io.IOException
Writes a data range block to the output stream.

Parameters:
dataRange - the range to write
Throws:
java.io.IOException

writePieChart

public void writePieChart(JRChart chart)
                   throws java.io.IOException
Throws:
java.io.IOException

writePie3DChart

public void writePie3DChart(JRChart chart)
                     throws java.io.IOException
Throws:
java.io.IOException

writeAxisFormat

public void writeAxisFormat(java.lang.String axisFormatElementName,
                            JRFont axisLabelFont,
                            java.awt.Color axisLabelColor,
                            JRFont axisTickLabelFont,
                            java.awt.Color axisTickLabelColor,
                            java.lang.String axisTickLabelMask,
                            java.awt.Color axisLineColor)
                     throws java.io.IOException
Writes out the axis format block for a chart axis.

Parameters:
axisFormatElementName - the name of the axis format element being written
axisLabelFont - font to use for the axis label
axisLabelColor - color to use for the axis label
axisTickLabelFont - font to use for the label of each tick mark
axisTickLabelColor - color to use for the label of each tick mark
axisTickLabelMask - formatting mask to use for the label of each tick mark
axisLineColor - the color to use for the axis line and any tick marks
Throws:
java.io.IOException

writeBar3DPlot

public void writeBar3DPlot(JRBar3DPlot plot)
                    throws java.io.IOException
Throws:
java.io.IOException

writeBarChart

public void writeBarChart(JRChart chart)
                   throws java.io.IOException
Throws:
java.io.IOException

writeBar3DChart

public void writeBar3DChart(JRChart chart)
                     throws java.io.IOException
Throws:
java.io.IOException

writeBubbleChart

public void writeBubbleChart(JRChart chart)
                      throws java.io.IOException
Throws:
java.io.IOException

writeStackedBarChart

public void writeStackedBarChart(JRChart chart)
                          throws java.io.IOException
Throws:
java.io.IOException

writeStackedBar3DChart

public void writeStackedBar3DChart(JRChart chart)
                            throws java.io.IOException
Throws:
java.io.IOException

writeLineChart

public void writeLineChart(JRChart chart)
                    throws java.io.IOException
Throws:
java.io.IOException

writeTimeSeriesChart

public void writeTimeSeriesChart(JRChart chart)
                          throws java.io.IOException
Throws:
java.io.IOException

writeHighLowDataset

public void writeHighLowDataset(JRHighLowDataset dataset)
                         throws java.io.IOException
Throws:
java.io.IOException

writeHighLowChart

public void writeHighLowChart(JRChart chart)
                       throws java.io.IOException
Throws:
java.io.IOException

writeCandlestickChart

public void writeCandlestickChart(JRChart chart)
                           throws java.io.IOException
Throws:
java.io.IOException

writeAreaChart

public void writeAreaChart(JRChart chart)
                    throws java.io.IOException
Throws:
java.io.IOException

writeScatterChart

public void writeScatterChart(JRChart chart)
                       throws java.io.IOException
Throws:
java.io.IOException

writeXyAreaChart

public void writeXyAreaChart(JRChart chart)
                      throws java.io.IOException
Throws:
java.io.IOException

writeXyBarChart

public void writeXyBarChart(JRChart chart)
                     throws java.io.IOException
Throws:
java.io.IOException

writeXyLineChart

public void writeXyLineChart(JRChart chart)
                      throws java.io.IOException
Throws:
java.io.IOException

writeMeterChart

public void writeMeterChart(JRChart chart)
                     throws java.io.IOException
Writes the definition of a meter chart to the output stream.

Parameters:
chart - the meter chart to write
Throws:
java.io.IOException

writeThermometerChart

public void writeThermometerChart(JRChart chart)
                           throws java.io.IOException
Writes the description of a thermometer chart to the output stream.

Parameters:
chart - the thermometer chart to write
Throws:
java.io.IOException

writeMultiAxisChart

public void writeMultiAxisChart(JRChart chart)
                         throws java.io.IOException
Writes the definition of a multiple axis chart to the output stream.

Parameters:
chart - the multiple axis chart to write
Throws:
java.io.IOException

writeStackedAreaChart

public void writeStackedAreaChart(JRChart chart)
                           throws java.io.IOException
Throws:
java.io.IOException

writeChartTag

public void writeChartTag(JRChart chart)
                   throws java.io.IOException
Throws:
java.io.IOException

writeCrosstab

public void writeCrosstab(JRCrosstab crosstab)
                   throws java.io.IOException
Throws:
java.io.IOException

writeCrosstabRowGroup

protected void writeCrosstabRowGroup(JRCrosstabRowGroup group)
                              throws java.io.IOException
Throws:
java.io.IOException

writeCrosstabColumnGroup

protected void writeCrosstabColumnGroup(JRCrosstabColumnGroup group)
                                 throws java.io.IOException
Throws:
java.io.IOException

writeBucket

protected void writeBucket(JRCrosstabBucket bucket)
                    throws java.io.IOException
Throws:
java.io.IOException

writeCrosstabMeasure

protected void writeCrosstabMeasure(JRCrosstabMeasure measure)
                             throws java.io.IOException
Throws:
java.io.IOException

writeCrosstabCell

protected void writeCrosstabCell(JRCrosstabCell cell)
                          throws java.io.IOException
Throws:
java.io.IOException

writeCellContents

protected void writeCellContents(JRCellContents contents)
                          throws java.io.IOException
Throws:
java.io.IOException

writeCrosstabParameter

protected void writeCrosstabParameter(JRCrosstabParameter parameter)
                               throws java.io.IOException
Throws:
java.io.IOException

writeDataset

public void writeDataset(JRDataset dataset)
                  throws java.io.IOException
Throws:
java.io.IOException

writeDatasetContents

protected void writeDatasetContents(JRDataset dataset)
                             throws java.io.IOException
Throws:
java.io.IOException

writeDatasetRun

protected void writeDatasetRun(JRDatasetRun datasetRun)
                        throws java.io.IOException
Throws:
java.io.IOException

writeFrame

public void writeFrame(JRFrame frame)
                throws java.io.IOException
Throws:
java.io.IOException

writeHyperlinkParameters

protected void writeHyperlinkParameters(JRHyperlinkParameter[] parameters)
                                 throws java.io.IOException
Throws:
java.io.IOException

writeHyperlinkParameter

protected void writeHyperlinkParameter(JRHyperlinkParameter parameter)
                                throws java.io.IOException
Throws:
java.io.IOException

writeHyperlink

protected void writeHyperlink(java.lang.String tagName,
                              JRHyperlink hyperlink)
                       throws java.io.IOException
Throws:
java.io.IOException

toWriteConditionalStyles

protected boolean toWriteConditionalStyles()
Description copied from class: JRXmlBaseWriter
Decides whether conditional styles are to be written.

Specified by:
toWriteConditionalStyles in class JRXmlBaseWriter
Returns:
whether conditional styles are to be written


© 2001-2006 JasperSoft Corporation www.jaspersoft.com