package com.example.demo.model;

import java.time.LocalDateTime;

/**
 * 任务草案实体模型。
 * <p>
 * 表示基于事件评估后生成的作战任务草案，
 * 准备下发至任务规划引擎进行详细规划。
 * </p>
 */
public class TaskDraft {

    /** 任务草案唯一标识 */
    private String draftId;

    /** 关联的事件ID */
    private String eventId;

    /** 使用的模板ID */
    private String templateId;

    /** 任务草案标题 */
    private String title;

    /** 任务草案内容（JSON格式） */
    private String content;

    /** 目标价值评分 */
    private double targetValueScore;

    /** 发送状态：0-未发送, 1-已发送, 2-发送失败 */
    private int sendStatus;

    /** 发送重试次数 */
    private int retryCount;

    /** 创建时间 */
    private LocalDateTime createTime;

    /** 最后发送时间 */
    private LocalDateTime lastSendTime;

    public TaskDraft() {
    }

    public TaskDraft(String draftId, String eventId, String templateId, String title,
                     String content, double targetValueScore) {
        this.draftId = draftId;
        this.eventId = eventId;
        this.templateId = templateId;
        this.title = title;
        this.content = content;
        this.targetValueScore = targetValueScore;
        this.sendStatus = 0;
        this.retryCount = 0;
        this.createTime = LocalDateTime.now();
    }

    public String getDraftId() {
        return draftId;
    }

    public void setDraftId(String draftId) {
        this.draftId = draftId;
    }

    public String getEventId() {
        return eventId;
    }

    public void setEventId(String eventId) {
        this.eventId = eventId;
    }

    public String getTemplateId() {
        return templateId;
    }

    public void setTemplateId(String templateId) {
        this.templateId = templateId;
    }

    public String getTitle() {
        return title;
    }

    public void setTitle(String title) {
        this.title = title;
    }

    public String getContent() {
        return content;
    }

    public void setContent(String content) {
        this.content = content;
    }

    public double getTargetValueScore() {
        return targetValueScore;
    }

    public void setTargetValueScore(double targetValueScore) {
        this.targetValueScore = targetValueScore;
    }

    public int getSendStatus() {
        return sendStatus;
    }

    public void setSendStatus(int sendStatus) {
        this.sendStatus = sendStatus;
    }

    public int getRetryCount() {
        return retryCount;
    }

    public void setRetryCount(int retryCount) {
        this.retryCount = retryCount;
    }

    public LocalDateTime getCreateTime() {
        return createTime;
    }

    public void setCreateTime(LocalDateTime createTime) {
        this.createTime = createTime;
    }

    public LocalDateTime getLastSendTime() {
        return lastSendTime;
    }

    public void setLastSendTime(LocalDateTime lastSendTime) {
        this.lastSendTime = lastSendTime;
    }
}
