com.jrefinery.report.io.ext.writer
Class ReportConfigWriter

java.lang.Object
  |
  +--com.jrefinery.report.io.ext.writer.AbstractXMLDefinitionWriter
        |
        +--com.jrefinery.report.io.ext.writer.ReportConfigWriter

public class ReportConfigWriter
extends AbstractXMLDefinitionWriter

A report configuration writer.

Author:
Thomas Morgner.

Field Summary
 
Fields inherited from class com.jrefinery.report.io.ext.writer.AbstractXMLDefinitionWriter
CLOSE, CLOSE_TAG_DECREASE, INDENT_ONLY, OPEN, OPEN_TAG_INCREASE
 
Constructor Summary
ReportConfigWriter(ReportWriter reportWriter, int indentLevel)
          A report configuration writer.
 
Method Summary
 java.lang.String lookupPageDefinition(int w, int h)
          Finds the page definition from the PageFormatFactory class that matches the specified width and height.
 void write(java.io.Writer writer)
          Writes the report configuration element.
 
Methods inherited from class com.jrefinery.report.io.ext.writer.AbstractXMLDefinitionWriter
decreaseIndent, getIndentLevel, getLineSeparator, getReport, getReportWriter, getSafeTags, increaseIndent, indent, normalize, writeCloseTag, writeTag, writeTag, writeTag
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ReportConfigWriter

public ReportConfigWriter(ReportWriter reportWriter,
                          int indentLevel)
A report configuration writer.

Parameters:
reportWriter - the report writer.
indentLevel - the current indention level.
Method Detail

write

public void write(java.io.Writer writer)
           throws java.io.IOException
Writes the report configuration element.

Specified by:
write in class AbstractXMLDefinitionWriter
Parameters:
writer - the writer.
Throws:
java.io.IOException - if there is an I/O problem.

lookupPageDefinition

public java.lang.String lookupPageDefinition(int w,
                                             int h)
Finds the page definition from the PageFormatFactory class that matches the specified width and height.

Parameters:
w - the width.
h - the height.
Returns:
The page definition name.