package com.example.demo.model;

import io.swagger.v3.oas.annotations.media.Schema;

/**
 * 数据同步记录实体。
 */
@Schema(description = "数据同步记录实体")
public class SyncRecord {

    @Schema(description = "同步ID")
    private Long id;

    @Schema(description = "源系统")
    private String sourceSystem;

    @Schema(description = "目标系统")
    private String targetSystem;

    @Schema(description = "同步类型：full-全量，incremental-增量，realTime-实时，timed-定时")
    private String syncType;

    @Schema(description = "同步时间")
    private String syncTime;

    @Schema(description = "状态：success-成功，fail-失败，running-进行中")
    private String status;

    @Schema(description = "数据条数")
    private Integer dataCount;

    @Schema(description = "错误信息")
    private String errorMessage;

    public SyncRecord() {
    }

    public SyncRecord(Long id, String sourceSystem, String targetSystem, String syncType,
                      String syncTime, String status, Integer dataCount, String errorMessage) {
        this.id = id;
        this.sourceSystem = sourceSystem;
        this.targetSystem = targetSystem;
        this.syncType = syncType;
        this.syncTime = syncTime;
        this.status = status;
        this.dataCount = dataCount;
        this.errorMessage = errorMessage;
    }

    public Long getId() { return id; }
    public void setId(Long id) { this.id = id; }
    public String getSourceSystem() { return sourceSystem; }
    public void setSourceSystem(String sourceSystem) { this.sourceSystem = sourceSystem; }
    public String getTargetSystem() { return targetSystem; }
    public void setTargetSystem(String targetSystem) { this.targetSystem = targetSystem; }
    public String getSyncType() { return syncType; }
    public void setSyncType(String syncType) { this.syncType = syncType; }
    public String getSyncTime() { return syncTime; }
    public void setSyncTime(String syncTime) { this.syncTime = syncTime; }
    public String getStatus() { return status; }
    public void setStatus(String status) { this.status = status; }
    public Integer getDataCount() { return dataCount; }
    public void setDataCount(Integer dataCount) { this.dataCount = dataCount; }
    public String getErrorMessage() { return errorMessage; }
    public void setErrorMessage(String errorMessage) { this.errorMessage = errorMessage; }
}
