Class CellFreeExcelTableWriter

java.lang.Object
jp.ecuacion.util.poi.excel.table.ExcelTable<org.apache.poi.ss.usermodel.Cell>
jp.ecuacion.util.poi.excel.table.writer.ExcelTableWriter<org.apache.poi.ss.usermodel.Cell>
jp.ecuacion.util.poi.excel.table.writer.concrete.CellFreeExcelTableWriter
All Implemented Interfaces:
IfDataTypeCellExcelTable, IfExcelTable<org.apache.poi.ss.usermodel.Cell>, IfFormatFreeExcelTable<org.apache.poi.ss.usermodel.Cell>, IfDataTypeCellExcelTableWriter, IfExcelTableWriter<org.apache.poi.ss.usermodel.Cell>

public class CellFreeExcelTableWriter extends ExcelTableWriter<org.apache.poi.ss.usermodel.Cell> implements IfFormatFreeExcelTable<org.apache.poi.ss.usermodel.Cell>, IfDataTypeCellExcelTableWriter
Reads tables with unknown number of columns, unknown whether it have a header line, unknown header labels if it has a header line.

It obtains cell values as Cell object.

The header line is not necessary. This class reads the table at the designated position and designated lines and columns.
Finish reading if all the columns are empty in one line.

  • Constructor Details

  • Method Details

    • getStringValue

      public String getStringValue(@Nullable org.apache.poi.ss.usermodel.Cell cellData)
      Description copied from interface: IfExcelTable
      Is used to get the header label string from the argument cell data.
      Specified by:
      getStringValue in interface IfDataTypeCellExcelTable
      Specified by:
      getStringValue in interface IfExcelTable<org.apache.poi.ss.usermodel.Cell>
      Parameters:
      cellData - data obtained from the cell
      Returns:
      String value obtained from the cellData
    • getHeaderData

      protected List<List<String>> getHeaderData(String templateFilePath, int tableColumnSize) throws org.apache.poi.EncryptedDocumentException, jp.ecuacion.lib.core.exception.checked.AppException, IOException
      Description copied from class: ExcelTableWriter
      Obtains header list from the file at templateFilePath.
      Specified by:
      getHeaderData in class ExcelTableWriter<org.apache.poi.ss.usermodel.Cell>
      Parameters:
      templateFilePath - nullable when the data is written to a new excel file.
      tableColumnSize - tableColumnSize
      Returns:
      the list of String, may be an empty list when templateFilePath is null.
      Throws:
      org.apache.poi.EncryptedDocumentException - EncryptedDocumentException
      jp.ecuacion.lib.core.exception.checked.AppException - AppException
      IOException - IOException