类 CSVReader

java.lang.Object
gu.sql2java.excel.BaseExcelReader<org.apache.commons.csv.CSVRecord>
gu.sql2java.excel.CSVReader
所有已实现的接口:
IExcelReader

public class CSVReader extends BaseExcelReader<org.apache.commons.csv.CSVRecord>
CSV文件导入
从以下版本开始:
3.29.0
作者:
guyadong
  • 构造器详细资料

  • 方法详细资料

    • read

      public void read(InputStream inputStream, Charset charset, String format) throws IOException
      从类复制的说明: BaseExcelReader
      InputStream将导入数据记录, 子类必须重写此方法
      指定者:
      read 在接口中 IExcelReader
      覆盖:
      read 在类中 BaseExcelReader<org.apache.commons.csv.CSVRecord>
      参数:
      charset - 数据编码为null使用默认值
      format - 文件格式,即文件后缀: .xls,xlxs,.cxv
      抛出:
      IOException
    • getCellAsString

      protected String getCellAsString(org.apache.commons.csv.CSVRecord row, int idx)
      从类复制的说明: BaseExcelReader
      从单元格读取数据转为String, 子类必须重写此方法
      覆盖:
      getCellAsString 在类中 BaseExcelReader<org.apache.commons.csv.CSVRecord>
    • isEmptyCell

      protected boolean isEmptyCell(org.apache.commons.csv.CSVRecord row, int idx)
      从类复制的说明: BaseExcelReader
      行由idx指定单元为空返回true,否则返回false, 子类必须重写此方法
      覆盖:
      isEmptyCell 在类中 BaseExcelReader<org.apache.commons.csv.CSVRecord>
    • indexsOfRow

      protected List<Integer> indexsOfRow(org.apache.commons.csv.CSVRecord row)
      从类复制的说明: BaseExcelReader
      返回列的索引范围列表, 子类必须重写此方法
      覆盖:
      indexsOfRow 在类中 BaseExcelReader<org.apache.commons.csv.CSVRecord>