|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.pentaho.reporting.engine.classic.core.function.AbstractExpression
org.pentaho.reporting.engine.classic.core.function.AbstractFunction
org.pentaho.reporting.engine.classic.core.modules.output.csv.CSVWriter
public class CSVWriter
The CSV Writer is the content creation function used to create the CSV content. This implementation does no layouting, the DataRow's raw data is written to the supplied writer.
Constructor Summary | |
---|---|
CSVWriter()
DefaulConstructor. |
Method Summary | |
---|---|
void |
clearInlineSubreports(SubReportProcessType inlineExecution)
|
Object |
clone()
Clones the expression. |
boolean |
createRollbackInformation()
|
OutputFunction |
deriveForPagebreak()
This method simply clones the function. |
OutputFunction |
deriveForStorage()
This method simply clones the function. |
int |
getDependencyLevel()
The dependency level defines the level of execution for this function. |
InlineSubreportMarker[] |
getInlineSubreports()
|
String |
getSeparator()
Gets the separator which is used to separate columns in a row. |
Object |
getValue()
Return a selfreference of this CSVWriter. |
Writer |
getWriter()
Returns the writer used to output the generated data. |
void |
groupFinished(ReportEvent event)
Writes the GroupFooter of the active group. |
void |
groupStarted(ReportEvent event)
Writes the GroupHeader of the current group. |
boolean |
isEnableGroupFooter()
|
boolean |
isEnableGroupHeader()
|
boolean |
isEnableItemband()
|
boolean |
isEnableReportFooter()
|
boolean |
isEnableReportHeader()
|
boolean |
isWriteDataRowNames()
Returns whether to print dataRow column names as header. |
boolean |
isWriteStateColumns()
|
void |
itemsAdvanced(ReportEvent event)
Writes the current ItemBand. |
void |
itemsFinished(ReportEvent event)
Receives notification that a group of item bands has been completed. |
void |
itemsStarted(ReportEvent event)
Receives notification that a group of item bands is about to be processed. |
void |
reportFinished(ReportEvent event)
Writes the ReportFooter. |
void |
reportStarted(ReportEvent event)
Writes the ReportHeader and (if defined) the dataRow names. |
void |
restart(ReportState state)
|
void |
setDependencyLevel(int deplevel)
Overrides the depency level. |
void |
setEnableGroupFooter(boolean enableGroupFooter)
|
void |
setEnableGroupHeader(boolean enableGroupHeader)
|
void |
setEnableItemband(boolean enableItemband)
|
void |
setEnableReportFooter(boolean enableReportFooter)
|
void |
setEnableReportHeader(boolean enableReportHeader)
|
void |
setSeparator(String separator)
Defines the separator, which is used to separate columns in a row. |
void |
setWriteDataRowNames(boolean writeDataRowNames)
Defines, whether to print column names in the first row. |
void |
setWriter(Writer w)
Defines the writer which should be used to output the generated data. |
void |
setWriteStateColumns(boolean writeStateColumns)
|
Methods inherited from class org.pentaho.reporting.engine.classic.core.function.AbstractFunction |
---|
reportDone, reportInitialized |
Methods inherited from class org.pentaho.reporting.engine.classic.core.function.AbstractExpression |
---|
getDataRow, getInstance, getName, getReportConfiguration, getResourceBundleFactory, getRuntime, isActive, isDeepTraversing, isPreserve, setActive, setName, setPreserve, setRuntime |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Methods inherited from interface org.pentaho.reporting.engine.classic.core.event.ReportListener |
---|
reportDone, reportInitialized |
Methods inherited from interface org.pentaho.reporting.engine.classic.core.function.Expression |
---|
getDataRow, getInstance, getName, getReportConfiguration, getResourceBundleFactory, getRuntime, isActive, isDeepTraversing, isPreserve, setName, setRuntime |
Constructor Detail |
---|
public CSVWriter()
Method Detail |
---|
public boolean isWriteDataRowNames()
public void setWriteDataRowNames(boolean writeDataRowNames)
writeDataRowNames
- true, if column names are printed, false otherwisepublic boolean isWriteStateColumns()
public void setWriteStateColumns(boolean writeStateColumns)
public boolean isEnableGroupFooter()
public void setEnableGroupFooter(boolean enableGroupFooter)
public boolean isEnableGroupHeader()
public void setEnableGroupHeader(boolean enableGroupHeader)
public boolean isEnableItemband()
public void setEnableItemband(boolean enableItemband)
public boolean isEnableReportFooter()
public void setEnableReportFooter(boolean enableReportFooter)
public boolean isEnableReportHeader()
public void setEnableReportHeader(boolean enableReportHeader)
public Writer getWriter()
public void setWriter(Writer w)
w
- the writerpublic void setSeparator(String separator)
separator
- the separator string, never null.
NullPointerException
- if the separator is null.
IllegalArgumentException
- if the separator is an empty string.public String getSeparator()
public void reportStarted(ReportEvent event)
reportStarted
in interface ReportListener
reportStarted
in class AbstractFunction
event
- the event.public void reportFinished(ReportEvent event)
reportFinished
in interface ReportListener
reportFinished
in class AbstractFunction
event
- the event.public void groupStarted(ReportEvent event)
groupStarted
in interface ReportListener
groupStarted
in class AbstractFunction
event
- the event.public void groupFinished(ReportEvent event)
groupFinished
in interface ReportListener
groupFinished
in class AbstractFunction
event
- the event.public void itemsStarted(ReportEvent event)
The next events will be itemsAdvanced events until the itemsFinished event is raised.
itemsStarted
in interface ReportListener
itemsStarted
in class AbstractFunction
event
- The event.public void itemsFinished(ReportEvent event)
The itemBand is finished, the report starts to close open groups.
itemsFinished
in interface ReportListener
itemsFinished
in class AbstractFunction
event
- The event.public void itemsAdvanced(ReportEvent event)
itemsAdvanced
in interface ReportListener
itemsAdvanced
in class AbstractFunction
event
- the event.public Object getValue()
getValue
in interface Expression
public int getDependencyLevel()
getDependencyLevel
in interface Expression
getDependencyLevel
in class AbstractExpression
public void setDependencyLevel(int deplevel)
setDependencyLevel
in interface Expression
setDependencyLevel
in class AbstractExpression
deplevel
- the new depency level.public OutputFunction deriveForStorage()
deriveForStorage
in interface OutputFunction
public OutputFunction deriveForPagebreak()
deriveForPagebreak
in interface OutputFunction
public Object clone() throws CloneNotSupportedException
Expressions maintain no state, cloning is done at the beginning of the report processing to disconnect the expression from any other object space.
clone
in interface Expression
clone
in class AbstractExpression
CloneNotSupportedException
- this should never happen.public InlineSubreportMarker[] getInlineSubreports()
getInlineSubreports
in interface OutputFunction
public void clearInlineSubreports(SubReportProcessType inlineExecution)
clearInlineSubreports
in interface OutputFunction
public void restart(ReportState state)
restart
in interface OutputFunction
public boolean createRollbackInformation()
createRollbackInformation
in interface OutputFunction
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |