Class CSVOutputGenerator
java.lang.Object
net.datenwerke.rs.base.service.reportengines.table.output.generator.TableOutputGeneratorImpl
net.datenwerke.rs.base.service.reportengines.table.output.generator.CSVOutputGenerator
- All Implemented Interfaces:
TableOutputGenerator,ReportOutputGenerator
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionCSVOutputGenerator(ConfigService configService, ReportServerService reportServerService, <any> exporterHelperProvider) -
Method Summary
Modifier and TypeMethodDescriptionvoidaddField(Object field, Column.CellFormatter formatter) Adds a new cell to the output.voidclose()Informs the generator that the data is completely processed.Returns an emptyCompiledReportobject to specify the type of report that is generated by this generator.String[]Is called upon completion to get the final report object.voidinitialize(OutputStream os, TableDefinition td, boolean withSubtotals, TableReport report, TableReport orgReport, Column.CellFormatter[] cellFormatters, ParameterSet parameters, User user, ReportExecutionConfig... configs) Initializes the generator before the first data point is provided.voidnextRow()Informs the generator that the current data row is finished and a new row is about to beginMethods inherited from class net.datenwerke.rs.base.service.reportengines.table.output.generator.TableOutputGeneratorImpl
addGroupRow, isCatchAll, preInitialize, supportsStreaming
-
Field Details
-
CONFIG_FILE
- See Also:
-
CSV_LINE_SEPARATOR_PROPERTY
- See Also:
-
CSV_SEPARATOR_PROPERTY
- See Also:
-
CSV_QUOTATION_PROPERTY
- See Also:
-
-
Constructor Details
-
CSVOutputGenerator
public CSVOutputGenerator(ConfigService configService, ReportServerService reportServerService, <any> exporterHelperProvider)
-
-
Method Details
-
addField
Description copied from interface:TableOutputGeneratorAdds a new cell to the output.- Parameters:
field-formatter-- Throws:
IOException
-
close
Description copied from interface:TableOutputGeneratorInforms the generator that the data is completely processed.- Throws:
IOException
-
getFormats
- Returns:
- The generator's format
-
getTableObject
Description copied from interface:TableOutputGeneratorIs called upon completion to get the final report object. In case an outputstream is used (seeTableOutputGenerator.initialize(OutputStream, TableDefinition, boolean, TableReport, TableReport, CellFormatter[], ParameterSet, User, ReportExecutionConfig...)theCompiledReportobject should not contain actual report data.- Returns:
- The finished report
-
initialize
public void initialize(OutputStream os, TableDefinition td, boolean withSubtotals, TableReport report, TableReport orgReport, Column.CellFormatter[] cellFormatters, ParameterSet parameters, User user, ReportExecutionConfig... configs) throws IOException Description copied from interface:TableOutputGeneratorInitializes the generator before the first data point is provided.- Specified by:
initializein interfaceTableOutputGenerator- Overrides:
initializein classTableOutputGeneratorImpl- Parameters:
os- The output stream to be used. If no output stream is provided (the object is null), then the report should be generated in memory.- Throws:
IOException
-
nextRow
Description copied from interface:TableOutputGeneratorInforms the generator that the current data row is finished and a new row is about to begin- Throws:
IOException
-
getFormatInfo
Description copied from interface:ReportOutputGeneratorReturns an emptyCompiledReportobject to specify the type of report that is generated by this generator.
-