Class XlsxExport


  • public class XlsxExport
    extends Object
    • Constructor Detail

      • XlsxExport

        public XlsxExport()
    • Method Detail

      • writeXLSX

        public static void writeXLSX​(ResultSet rs,
                                     OutputStream out,
                                     boolean writeHeader,
                                     boolean useLabelIfPresent,
                                     String sheetName,
                                     DataRow AttributesRecord,
                                     SheetConfiguration sheetConfig)
                              throws Exception
        Writes the content of the given ResultSet into an output stream.
        Parameters:
        resultSet - The ResultSet to export.
        out - The output stream in which to write the ResultSet's content.
        writeHeader - The boolean value indicating whether writing the column headers or not.
        useLabelIfPresent - if the attributes record contains labels, use the label instead of the field name.
        sheetName - A custom name for the sheet
        DataRow - attributesRecord the attributes record for formatting
        Throws:
        Exception - Gets thrown in case the ResultSet could not be read or output stream can not be written