package com.ruoyi.analytics.domain;

import java.util.Date;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import javax.validation.constraints.Size;

import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;

import com.fasterxml.jackson.annotation.JsonFormat;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;

/**
 * 报表实例对象 dc_report_instance
 * 
 * @author ruoyi
 * @date 2025-12-19
 */
public class ReportInstance extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 实例ID */
    private Long instanceId;

    /** 报表ID */
    @Excel(name = "报表ID")
    @NotBlank(message = "报表ID不能为空")
    @Size(max = 100, message = "报表ID长度不能超过100个字符")
    private String reportId;

    /** 报表名称 */
    @Excel(name = "报表名称")
    @NotBlank(message = "报表名称不能为空")
    @Size(max = 200, message = "报表名称长度不能超过200个字符")
    private String reportName;

    /** 报表类型 */
    @Excel(name = "报表类型")
    @NotBlank(message = "报表类型不能为空")
    @Size(max = 50, message = "报表类型长度不能超过50个字符")
    private String reportType;

    /** 生成状态 */
    @Excel(name = "生成状态")
    @NotBlank(message = "生成状态不能为空")
    @Size(max = 50, message = "生成状态长度不能超过50个字符")
    private String generateStatus;

    /** 生成时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "生成时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    @NotNull(message = "生成时间不能为空")
    private Date generateTime;

    /** 完成时间 */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Excel(name = "完成时间", width = 30, dateFormat = "yyyy-MM-dd HH:mm:ss")
    private Date completeTime;

    /** 文件路径 */
    @Excel(name = "文件路径")
    @Size(max = 500, message = "文件路径长度不能超过500个字符")
    private String filePath;

    /** 文件大小 */
    @Excel(name = "文件大小")
    private Long fileSize;

    /** 输出格式 */
    @Excel(name = "输出格式")
    @NotBlank(message = "输出格式不能为空")
    @Size(max = 50, message = "输出格式长度不能超过50个字符")
    private String outputFormat;

    /** 参数配置 */
    @Size(max = 2000, message = "参数配置长度不能超过2000个字符")
    private String parameters;

    /** 错误信息 */
    @Size(max = 1000, message = "错误信息长度不能超过1000个字符")
    private String errorMessage;

    /** 生成用户ID */
    @Excel(name = "生成用户ID")
    @NotNull(message = "生成用户ID不能为空")
    private Long userId;

    public void setInstanceId(Long instanceId) 
    {
        this.instanceId = instanceId;
    }

    public Long getInstanceId() 
    {
        return instanceId;
    }
    public void setReportId(String reportId) 
    {
        this.reportId = reportId;
    }

    public String getReportId() 
    {
        return reportId;
    }
    public void setReportName(String reportName) 
    {
        this.reportName = reportName;
    }

    public String getReportName() 
    {
        return reportName;
    }
    public void setReportType(String reportType) 
    {
        this.reportType = reportType;
    }

    public String getReportType() 
    {
        return reportType;
    }
    public void setGenerateStatus(String generateStatus) 
    {
        this.generateStatus = generateStatus;
    }

    public String getGenerateStatus() 
    {
        return generateStatus;
    }
    public void setGenerateTime(Date generateTime) 
    {
        this.generateTime = generateTime;
    }

    public Date getGenerateTime() 
    {
        return generateTime;
    }
    public void setCompleteTime(Date completeTime) 
    {
        this.completeTime = completeTime;
    }

    public Date getCompleteTime() 
    {
        return completeTime;
    }
    public void setFilePath(String filePath) 
    {
        this.filePath = filePath;
    }

    public String getFilePath() 
    {
        return filePath;
    }
    public void setFileSize(Long fileSize) 
    {
        this.fileSize = fileSize;
    }

    public Long getFileSize() 
    {
        return fileSize;
    }
    public void setOutputFormat(String outputFormat) 
    {
        this.outputFormat = outputFormat;
    }

    public String getOutputFormat() 
    {
        return outputFormat;
    }
    public void setParameters(String parameters) 
    {
        this.parameters = parameters;
    }

    public String getParameters() 
    {
        return parameters;
    }
    public void setErrorMessage(String errorMessage) 
    {
        this.errorMessage = errorMessage;
    }

    public String getErrorMessage() 
    {
        return errorMessage;
    }
    public void setUserId(Long userId) 
    {
        this.userId = userId;
    }

    public Long getUserId() 
    {
        return userId;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
            .append("instanceId", getInstanceId())
            .append("reportId", getReportId())
            .append("reportName", getReportName())
            .append("reportType", getReportType())
            .append("generateStatus", getGenerateStatus())
            .append("generateTime", getGenerateTime())
            .append("completeTime", getCompleteTime())
            .append("filePath", getFilePath())
            .append("fileSize", getFileSize())
            .append("outputFormat", getOutputFormat())
            .append("parameters", getParameters())
            .append("errorMessage", getErrorMessage())
            .append("userId", getUserId())
            .append("createTime", getCreateTime())
            .append("updateTime", getUpdateTime())
            .toString();
    }
}