All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.github.dreamroute.excel.helper.annotation.Column Maven / Gradle / Ivy

There is a newer version: 2.0.4-RELEASE
Show newest version
package com.github.dreamroute.excel.helper.annotation;

import java.lang.annotation.ElementType;
import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;
import java.lang.annotation.Target;

import org.apache.poi.ss.usermodel.CellType;

/**
 * the column's properties
 *
 * @author [email protected]
 */
@Target(ElementType.FIELD)
@Retention(RetentionPolicy.RUNTIME)
public @interface Column {

    /**
     * column name, must not bu empty
     *
     * @return return column name
     */
    String name();

    /**
     * the default width of header/cell.(default: 0, means auto column width, less than 0 will be ignore, recomend 0.)
     *
     * @return column width
     */
    int width() default 0;

    /**
     * cell type, you can define it with {@link CellType} by yourself, support CellType.STRING, CellType.NUMERIC and CellType.BOOLEAN, default:
     * CellType.STRING
     *
     * @return return cellType.
     */
    CellType cellType() default CellType.STRING;

    /**
     * excle sheet's column order.
     *
     * @return return column order, in future
     */
    int order() default 0;

    /**
     * column formula
     * 
     *     A?+B?,?代表行数,从1开始
     * 
* * @return return column formula */ String formula() default ""; }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy