package com.unis.detectionnum.server.entity;

import java.util.Date;

import javax.persistence.Column;

import org.springframework.format.annotation.DateTimeFormat;

import com.fasterxml.jackson.annotation.JsonFormat;

import lombok.Getter;
import lombok.Setter;

@Setter
@Getter
public class TaskInfoDO {
	
	/**
	 *  定时任务编号
	 */
	@Column(name = "TASK_NO", length = 12)
    private String taskNo;

	
	/**
	 *  任务名称
	 */
	@Column(name = "TASK_NAME")
    private String taskName;

	/**
	 *  开始日期 YYYY-MM-DD
	 */
	@Column(name = "START_TIME")
    @DateTimeFormat(pattern = "yyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date startTime;

	/**
	 * 结束日期
	 */
	@Column(name = "END_TIME")
    @DateTimeFormat(pattern = "yyy-MM-dd HH:mm:ss")
    @JsonFormat(pattern = "yyy-MM-dd HH:mm:ss",timezone = "GMT+8")
    private Date endTime;

	/**
	 *  执行类型 0：循环执行，1：定时执行
	 */
	@Column(name = "EXECUTE_TYPE")
    private Integer executeType = 0;

	/**
	 * 执行时间
	 */
	@Column(name = "EXECUTE_TIME")
    private Date executeTime;

	/**
	 * cron表达式
	 */
	@Column(name = "CRON_EXPR")
    private String cronExpr;

	/**
	 * 任务执行类
	 */
	@Column(name = "EXECUTE_CLASS")
    private String executeClass;
	
	/**
	 * 设备code
	 */
	@Column(name = "SB_CODE")
	private String sbCode;

}