package com.qmth.teachcloud.mark.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import com.qmth.teachcloud.mark.enums.CardSource;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import java.io.Serializable;

/**
 * <p>
 * 题卡卡格式表
 * </p>
 *
 * @author xf
 * @since 2023-09-22
 */
@TableName("scan_answer_card")
@ApiModel(value = "ScanAnswerCard对象", description = "题卡卡格式表")
public class ScanAnswerCard implements Serializable {

    private static final long serialVersionUID = 1L;

    @JsonSerialize(using = ToStringSerializer.class)
    @ApiModelProperty(value = "ID")
    @TableId(value = "id", type = IdType.INPUT)
    private Long id;

    @JsonSerialize(using = ToStringSerializer.class)
    @ApiModelProperty(value = "考试ID")
    private Long examId;

    @ApiModelProperty(value = "试卷编号")
    private String paperNumber;

    @ApiModelProperty(value = "试卷编号（交互）")
    private String coursePaperId;
    @ApiModelProperty(value = "试卷类型")
    private String paperType;

    @ApiModelProperty(value = "题卡ID")
    private Long cardId;

    @ApiModelProperty(value = "序号")
    private Integer number;
    @ApiModelProperty("卡格式文件存储路径")
    private String uri;
    @ApiModelProperty(value = "来源")
    private CardSource source;

    @ApiModelProperty(value = "文件md5")
    private String md5;

    @ApiModelProperty(value = "其他属性")
    private String parameter;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "修改时间")
    private Long updateTime;

    @ApiModelProperty(value = "是否需要适配")
    private Boolean needAdapte;

    private Integer paperCount;

    private Boolean singlePage;

    @ApiModelProperty(value = "裁切配置")
    private String sliceConfig;

    @ApiModelProperty(value = "dpi")
    private Integer dpi;

    @ApiModelProperty(value = "混扫代码")
    private String code;

    @ApiModelProperty(value = "适配后文件md5")
    private String adapteMd5;

    private String adapteUri;

    public Long getId() {
        return id;
    }

    public void setId(Long id) {
        this.id = id;
    }

    public Long getExamId() {
        return examId;
    }

    public void setExamId(Long examId) {
        this.examId = examId;
    }

    public String getPaperNumber() {
        return paperNumber;
    }

    public void setPaperNumber(String paperNumber) {
        this.paperNumber = paperNumber;
    }

    public String getPaperType() {
        return paperType;
    }

    public void setPaperType(String paperType) {
        this.paperType = paperType;
    }

    public String getCoursePaperId() {
        return coursePaperId;
    }

    public void setCoursePaperId(String coursePaperId) {
        this.coursePaperId = coursePaperId;
    }

    public Long getCardId() {
        return cardId;
    }

    public void setCardId(Long cardId) {
        this.cardId = cardId;
    }

    public Integer getNumber() {
        return number;
    }

    public void setNumber(Integer number) {
        this.number = number;
    }

    public CardSource getSource() {
        return source;
    }

    public void setSource(CardSource source) {
        this.source = source;
    }

    public String getMd5() {
        return md5;
    }

    public void setMd5(String md5) {
        this.md5 = md5;
    }

    public String getParameter() {
        return parameter;
    }

    public void setParameter(String parameter) {
        this.parameter = parameter;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Long getUpdateTime() {
        return updateTime;
    }

    public void setUpdateTime(Long updateTime) {
        this.updateTime = updateTime;
    }

    public Boolean getNeedAdapte() {
        return needAdapte;
    }

    public void setNeedAdapte(Boolean needAdapte) {
        this.needAdapte = needAdapte;
    }

    public Integer getPaperCount() {
        return paperCount;
    }

    public void setPaperCount(Integer paperCount) {
        this.paperCount = paperCount;
    }

    public Boolean getSinglePage() {
        return singlePage;
    }

    public void setSinglePage(Boolean singlePage) {
        this.singlePage = singlePage;
    }

    public String getSliceConfig() {
        return sliceConfig;
    }

    public void setSliceConfig(String sliceConfig) {
        this.sliceConfig = sliceConfig;
    }

    public Integer getDpi() {
        return dpi;
    }

    public void setDpi(Integer dpi) {
        this.dpi = dpi;
    }

    public String getCode() {
        return code;
    }

    public void setCode(String code) {
        this.code = code;
    }

    public String getAdapteMd5() {
        return adapteMd5;
    }

    public void setAdapteMd5(String adapteMd5) {
        this.adapteMd5 = adapteMd5;
    }

    public String getAdapteUri() {
        return adapteUri;
    }

    public void setAdapteUri(String adapteUri) {
        this.adapteUri = adapteUri;
    }


    public String getUri() {
        return uri;
    }

    public void setUri(String uri) {
        this.uri = uri;
    }

    @Override
    public String toString() {
        return "ScanAnswerCard{" +
                "examId=" + examId +
                ", paperNumber=" + paperNumber +
                ", coursePaperId=" + coursePaperId +
                ", number=" + number +
                ", source=" + source.name() +
                ", md5=" + md5 +
                ", parameter=" + parameter +
                ", remark=" + remark +
                ", updateTime=" + updateTime +
                ", needAdapte=" + needAdapte +
                ", paperCount=" + paperCount +
                ", singlePage=" + singlePage +
                ", sliceConfig=" + sliceConfig +
                ", dpi=" + dpi +
                ", code=" + code +
                ", adapteMd5=" + adapteMd5 +
                ", adapteUri=" + adapteUri +
                "}";
    }
}
