类 ExportBase

java.lang.Object
org.jeecgframework.poi.excel.export.base.ExportBase
直接已知子类:
ExcelEntityParse, ExcelExportBase

public class ExportBase extends Object
导出基础处理,不设计POI,只设计对象,保证复用性
作者:
JEECG
  • 字段详细资料

  • 构造器详细资料

    • ExportBase

      public ExportBase()
  • 方法详细资料

    • getAllExcelField

      public void getAllExcelField(String[] exclusions, String targetId, Field[] fields, List<ExcelExportEntity> excelParams, Class<?> pojoClass, List<Method> getMethods) throws Exception
      获取需要导出的全部字段
      参数:
      exclusions -
      targetId - 目标ID
      fields -
      抛出:
      Exception
    • getCellOrder

      public int getCellOrder(String orderNum, String targetId)
      获取这个字段的顺序
      参数:
      orderNum -
      targetId -
      返回:
    • getCellValue

      public Object getCellValue(ExcelExportEntity entity, Object obj) throws Exception
      获取填如这个cell的值,提供一些附加功能
      参数:
      entity -
      obj -
      返回:
      抛出:
      Exception
    • getListCellValue

      public Collection<?> getListCellValue(ExcelExportEntity entity, Object obj) throws Exception
      获取集合的值
      参数:
      entity -
      obj -
      返回:
      抛出:
      Exception
    • getExcelName

      public String getExcelName(String exportName, String targetId)
      判断在这个单元格显示的名称
      参数:
      exportName -
      targetId -
      返回:
    • getFieldBySomeMethod

      public Object getFieldBySomeMethod(List<Method> list, Object t) throws Exception
      多个反射获取值
      参数:
      list -
      t -
      返回:
      抛出:
      Exception
    • getRowHeight

      public short getRowHeight(List<ExcelExportEntity> excelParams)
      根据注解获取行高
      参数:
      excelParams -
      返回:
    • isInteger

      public boolean isInteger(String value)
      判断字符串是否是整数
    • sortAllParams

      public void sortAllParams(List<ExcelExportEntity> excelParams)
      对字段根据用户设置排序
    • reConfigExcelExportParams

      public void reConfigExcelExportParams(List<ExcelExportEntity> excelParams, ExportParams exportParams)
      循环ExcelExportEntity集合 附加配置信息
      1.列排序
      2.读取图片根路径设置(如果有字段是图片类型 并且存储在本地 则设置磁盘路径获取全地址导出)
      3.多表头配置(仅限于单表 会走这个逻辑处理)
    • getValueArr

      public String[] getValueArr(String val)
      字典文本中含多个下划线横岗,取最后一个(解决空值情况)
      参数:
      val -
      返回: