注释接口 ExcelColumn


定义导出Excel数据列的配置注解
作者:
guyadong
  • 元素详细资料

    • sort

      int sort
      导出时在excel中排序
      默认值:
      2147483647
    • columnName

      String columnName
      对象(Java Bean/Map/JSON)中的字段名.
      默认值:
      ""
    • name

      String name
      导出到Excel中的名字.为空则与columnName()相等
      默认值:
      ""
    • integralFormat

      String integralFormat
      默认整数(Integer,Long,Short)格式
      默认值:
      ""
    • dateFormat

      String dateFormat
      日期格式, 如: yyyy-MM-dd
      默认值:
      ""
    • readConverterExp

      String readConverterExp
      读取内容转表达式 (如: 0=男,1=女,2=未知,*=错误值), '*'为匹配其他未定义值的表达式
      默认值:
      ""
    • separator

      String separator
      分隔符,读取字符串组内容
      默认值:
      ","
    • scale

      int scale
      BigDecimal 精度 默认:-1(默认不开启BigDecimal格式化)
      默认值:
      -1
    • roundingMode

      int roundingMode
      BigDecimal 舍入规则 默认:BigDecimal.ROUND_HALF_EVEN
      默认值:
      6
    • height

      double height
      导出时在excel中每个列的高度 单位为字符
      默认值:
      14.0
    • width

      double width
      导出时在excel中每个列的宽 单位为字符
      默认值:
      0.0
    • suffix

      String suffix
      文字后缀,如% 90 变成90%
      默认值:
      ""
    • defaultValue

      String defaultValue
      当值为空时,字段的默认值
      默认值:
      ""
    • prompt

      String prompt
      提示信息
      默认值:
      ""
    • combo

      String[] combo
      设置只能选择不能输入的列内容.
      默认值:
      {}
    • export

      boolean export
      是否导出数据,应对需求:有时我们需要导出一份模板,这是标题需要但内容需要用户手工填写.
      默认值:
      true
    • targetAttr

      String targetAttr
      另一个类中的属性名称,支持多级获取,以小数点隔开
      默认值:
      ""
    • statistics

      boolean statistics
      是否自动统计数据,在最后追加一行统计数据总和
      默认值:
      false
    • cellType

      导出类型(0数字 1字符串)
      默认值:
      STRING
    • color

      String color
      导出字体颜色,参见IndexedColors
      默认值:
      ""
    • fillColor

      String fillColor
      单元格填充颜色,参见IndexedColors
      默认值:
      ""
    • horizontalAlign

      String horizontalAlign
      导出字段水平对齐方式,参见HorizontalAlignment
      默认值:
      ""
    • handler

      Class<?> handler
      自定义数据处理器
      默认值:
      gu.sql2java.excel.annotations.ExcelHandlerAdapter.class
    • args

      String[] args
      自定义数据处理器参数
      默认值:
      {}
    • readMethod

      String readMethod
      指定字段读取方法名
      默认值:
      ""
    • writeMethod

      String writeMethod
      指定字段写入方法名
      默认值:
      ""
    • type

      字段类型(0:导出导入;1:仅导出;2:仅导入)
      默认值:
      ALL