package cn.estsh.i3plus.pojo.model.report;

import cn.estsh.i3plus.pojo.base.enumutil.CommonEnumUtil;
import io.swagger.annotations.ApiParam;
import lombok.Data;

import java.io.Serializable;

/**
 * @Description :
 * 自定义报表数据源传输对象 ， 单纯数据传输使用并不做保存使用
 * @Reference :
 * @Author : wei.peng
 * @CreateDate : 19-12-5 下午4:02
 * @Modify:
 **/
@Data
public class BrDataSourceModel implements Serializable {

    /**
     * 默认数据源信息
     */
    public static final BrDataSourceModel DEFAULT_DATA_SOURCE = new BrDataSourceModel("默认数据源", "DEFAULT",
            CommonEnumUtil.DATA_SOURCE_TYPE.SOURCE_MARIA_DB.getValue(), null, "使用默认数据源");
    private static final long serialVersionUID = -5137576929473857749L;

    @ApiParam(value = "数据源名称")
    private String sourceName;

    @ApiParam(value = "数据源编码")
    private String sourceCode;

    @ApiParam(value = "数据源类型", name = "BlockFormEnumUtil.DATA_SOURCE_TYPE")
    private Integer sourceType;

    @ApiParam(value = "数据库名称")
    private String sourceDataBaseName;

    @ApiParam(value = "数据源描述")
    private String sourceDescription;

    public BrDataSourceModel() {
    }

    public BrDataSourceModel(String sourceName, String sourceCode, Integer sourceType, String sourceDataBaseName, String sourceDescription) {
        this.sourceName = sourceName;
        this.sourceCode = sourceCode;
        this.sourceType = sourceType;
        this.sourceDataBaseName = sourceDataBaseName;
        this.sourceDescription = sourceDescription;
    }
}
