package com.usky.rule.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import java.io.Serializable;
import java.time.LocalDateTime;

@ApiModel
public class RuleEngineLogVO implements Serializable {
    private static final long serialVersionUID = -90128267903557833L;
    @ApiModelProperty("自增ID")
    private Long id;
    @ApiModelProperty("项目ID")
    private Long projectId;
    @ApiModelProperty("规则引擎ID")
    private Long ruleEngineId;
    @ApiModelProperty("规则名称")
    private String ruleEngineName;
    @ApiModelProperty("自动触发 0：否 1：是")
    private Byte autoTrigger;
    @ApiModelProperty("触发类型 device/space/cron")
    private String triggerType;
    @ApiModelProperty("执行动作 deviceControl/alarmEvent/workOrder")
    private String action;
    @ApiModelProperty("日志数据")
    private String detail;
    @ApiModelProperty("日志内容")
    private String content;
    @JsonFormat(
            pattern = "yyyy-MM-dd HH:mm:ss"
    )
    @ApiModelProperty("执行时间")
    private LocalDateTime time;
    @ApiModelProperty("更新人")
    private Long updatedBy;
    @ApiModelProperty("记录更新时间")
    private String updateTime;
    @ApiModelProperty("创建人")
    private Long createdBy;
    @ApiModelProperty("记录创建时间")
    private String createTime;

    public static RuleEngineLogVOBuilder builder() {
        return new RuleEngineLogVOBuilder();
    }

    public Long getId() {
        return this.id;
    }

    public Long getProjectId() {
        return this.projectId;
    }

    public Long getRuleEngineId() {
        return this.ruleEngineId;
    }

    public String getRuleEngineName() {
        return this.ruleEngineName;
    }

    public Byte getAutoTrigger() {
        return this.autoTrigger;
    }

    public String getTriggerType() {
        return this.triggerType;
    }

    public String getAction() {
        return this.action;
    }

    public String getDetail() {
        return this.detail;
    }

    public String getContent() {
        return this.content;
    }

    public LocalDateTime getTime() {
        return this.time;
    }

    public Long getUpdatedBy() {
        return this.updatedBy;
    }

    public String getUpdateTime() {
        return this.updateTime;
    }

    public Long getCreatedBy() {
        return this.createdBy;
    }

    public String getCreateTime() {
        return this.createTime;
    }

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

    public void setProjectId(final Long projectId) {
        this.projectId = projectId;
    }

    public void setRuleEngineId(final Long ruleEngineId) {
        this.ruleEngineId = ruleEngineId;
    }

    public void setRuleEngineName(final String ruleEngineName) {
        this.ruleEngineName = ruleEngineName;
    }

    public void setAutoTrigger(final Byte autoTrigger) {
        this.autoTrigger = autoTrigger;
    }

    public void setTriggerType(final String triggerType) {
        this.triggerType = triggerType;
    }

    public void setAction(final String action) {
        this.action = action;
    }

    public void setDetail(final String detail) {
        this.detail = detail;
    }

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

    @JsonFormat(
            pattern = "yyyy-MM-dd HH:mm:ss"
    )
    public void setTime(final LocalDateTime time) {
        this.time = time;
    }

    public void setUpdatedBy(final Long updatedBy) {
        this.updatedBy = updatedBy;
    }

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

    public void setCreatedBy(final Long createdBy) {
        this.createdBy = createdBy;
    }

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

    public boolean equals(final Object o) {
        if (o == this) {
            return true;
        } else if (!(o instanceof RuleEngineLogVO)) {
            return false;
        } else {
            RuleEngineLogVO other = (RuleEngineLogVO)o;
            if (!other.canEqual(this)) {
                return false;
            } else {
                Object this$id = this.getId();
                Object other$id = other.getId();
                if (this$id == null) {
                    if (other$id != null) {
                        return false;
                    }
                } else if (!this$id.equals(other$id)) {
                    return false;
                }

                Object this$projectId = this.getProjectId();
                Object other$projectId = other.getProjectId();
                if (this$projectId == null) {
                    if (other$projectId != null) {
                        return false;
                    }
                } else if (!this$projectId.equals(other$projectId)) {
                    return false;
                }

                Object this$ruleEngineId = this.getRuleEngineId();
                Object other$ruleEngineId = other.getRuleEngineId();
                if (this$ruleEngineId == null) {
                    if (other$ruleEngineId != null) {
                        return false;
                    }
                } else if (!this$ruleEngineId.equals(other$ruleEngineId)) {
                    return false;
                }

                Object this$autoTrigger = this.getAutoTrigger();
                Object other$autoTrigger = other.getAutoTrigger();
                if (this$autoTrigger == null) {
                    if (other$autoTrigger != null) {
                        return false;
                    }
                } else if (!this$autoTrigger.equals(other$autoTrigger)) {
                    return false;
                }

                Object this$updatedBy = this.getUpdatedBy();
                Object other$updatedBy = other.getUpdatedBy();
                if (this$updatedBy == null) {
                    if (other$updatedBy != null) {
                        return false;
                    }
                } else if (!this$updatedBy.equals(other$updatedBy)) {
                    return false;
                }

                Object this$createdBy = this.getCreatedBy();
                Object other$createdBy = other.getCreatedBy();
                if (this$createdBy == null) {
                    if (other$createdBy != null) {
                        return false;
                    }
                } else if (!this$createdBy.equals(other$createdBy)) {
                    return false;
                }

                Object this$ruleEngineName = this.getRuleEngineName();
                Object other$ruleEngineName = other.getRuleEngineName();
                if (this$ruleEngineName == null) {
                    if (other$ruleEngineName != null) {
                        return false;
                    }
                } else if (!this$ruleEngineName.equals(other$ruleEngineName)) {
                    return false;
                }

                Object this$triggerType = this.getTriggerType();
                Object other$triggerType = other.getTriggerType();
                if (this$triggerType == null) {
                    if (other$triggerType != null) {
                        return false;
                    }
                } else if (!this$triggerType.equals(other$triggerType)) {
                    return false;
                }

                Object this$action = this.getAction();
                Object other$action = other.getAction();
                if (this$action == null) {
                    if (other$action != null) {
                        return false;
                    }
                } else if (!this$action.equals(other$action)) {
                    return false;
                }

                Object this$detail = this.getDetail();
                Object other$detail = other.getDetail();
                if (this$detail == null) {
                    if (other$detail != null) {
                        return false;
                    }
                } else if (!this$detail.equals(other$detail)) {
                    return false;
                }

                Object this$content = this.getContent();
                Object other$content = other.getContent();
                if (this$content == null) {
                    if (other$content != null) {
                        return false;
                    }
                } else if (!this$content.equals(other$content)) {
                    return false;
                }

                Object this$time = this.getTime();
                Object other$time = other.getTime();
                if (this$time == null) {
                    if (other$time != null) {
                        return false;
                    }
                } else if (!this$time.equals(other$time)) {
                    return false;
                }

                Object this$updateTime = this.getUpdateTime();
                Object other$updateTime = other.getUpdateTime();
                if (this$updateTime == null) {
                    if (other$updateTime != null) {
                        return false;
                    }
                } else if (!this$updateTime.equals(other$updateTime)) {
                    return false;
                }

                Object this$createTime = this.getCreateTime();
                Object other$createTime = other.getCreateTime();
                if (this$createTime == null) {
                    if (other$createTime != null) {
                        return false;
                    }
                } else if (!this$createTime.equals(other$createTime)) {
                    return false;
                }

                return true;
            }
        }
    }

    protected boolean canEqual(final Object other) {
        return other instanceof RuleEngineLogVO;
    }

    public int hashCode() {
        int PRIME = 59;
        int result = 1;
        Object $id = this.getId();
        result = result * 59 + ($id == null ? 43 : $id.hashCode());
        Object $projectId = this.getProjectId();
        result = result * 59 + ($projectId == null ? 43 : $projectId.hashCode());
        Object $ruleEngineId = this.getRuleEngineId();
        result = result * 59 + ($ruleEngineId == null ? 43 : $ruleEngineId.hashCode());
        Object $autoTrigger = this.getAutoTrigger();
        result = result * 59 + ($autoTrigger == null ? 43 : $autoTrigger.hashCode());
        Object $updatedBy = this.getUpdatedBy();
        result = result * 59 + ($updatedBy == null ? 43 : $updatedBy.hashCode());
        Object $createdBy = this.getCreatedBy();
        result = result * 59 + ($createdBy == null ? 43 : $createdBy.hashCode());
        Object $ruleEngineName = this.getRuleEngineName();
        result = result * 59 + ($ruleEngineName == null ? 43 : $ruleEngineName.hashCode());
        Object $triggerType = this.getTriggerType();
        result = result * 59 + ($triggerType == null ? 43 : $triggerType.hashCode());
        Object $action = this.getAction();
        result = result * 59 + ($action == null ? 43 : $action.hashCode());
        Object $detail = this.getDetail();
        result = result * 59 + ($detail == null ? 43 : $detail.hashCode());
        Object $content = this.getContent();
        result = result * 59 + ($content == null ? 43 : $content.hashCode());
        Object $time = this.getTime();
        result = result * 59 + ($time == null ? 43 : $time.hashCode());
        Object $updateTime = this.getUpdateTime();
        result = result * 59 + ($updateTime == null ? 43 : $updateTime.hashCode());
        Object $createTime = this.getCreateTime();
        result = result * 59 + ($createTime == null ? 43 : $createTime.hashCode());
        return result;
    }

    public String toString() {
        return "RuleEngineLogVO(id=" + this.getId() + ", projectId=" + this.getProjectId() + ", ruleEngineId=" + this.getRuleEngineId() + ", ruleEngineName=" + this.getRuleEngineName() + ", autoTrigger=" + this.getAutoTrigger() + ", triggerType=" + this.getTriggerType() + ", action=" + this.getAction() + ", detail=" + this.getDetail() + ", content=" + this.getContent() + ", time=" + this.getTime() + ", updatedBy=" + this.getUpdatedBy() + ", updateTime=" + this.getUpdateTime() + ", createdBy=" + this.getCreatedBy() + ", createTime=" + this.getCreateTime() + ")";
    }

    public RuleEngineLogVO(final Long id, final Long projectId, final Long ruleEngineId, final String ruleEngineName, final Byte autoTrigger, final String triggerType, final String action, final String detail, final String content, final LocalDateTime time, final Long updatedBy, final String updateTime, final Long createdBy, final String createTime) {
        this.id = id;
        this.projectId = projectId;
        this.ruleEngineId = ruleEngineId;
        this.ruleEngineName = ruleEngineName;
        this.autoTrigger = autoTrigger;
        this.triggerType = triggerType;
        this.action = action;
        this.detail = detail;
        this.content = content;
        this.time = time;
        this.updatedBy = updatedBy;
        this.updateTime = updateTime;
        this.createdBy = createdBy;
        this.createTime = createTime;
    }

    public RuleEngineLogVO() {
    }

    public static class RuleEngineLogVOBuilder {
        private Long id;
        private Long projectId;
        private Long ruleEngineId;
        private String ruleEngineName;
        private Byte autoTrigger;
        private String triggerType;
        private String action;
        private String detail;
        private String content;
        private LocalDateTime time;
        private Long updatedBy;
        private String updateTime;
        private Long createdBy;
        private String createTime;

        RuleEngineLogVOBuilder() {
        }

        public RuleEngineLogVOBuilder id(final Long id) {
            this.id = id;
            return this;
        }

        public RuleEngineLogVOBuilder projectId(final Long projectId) {
            this.projectId = projectId;
            return this;
        }

        public RuleEngineLogVOBuilder ruleEngineId(final Long ruleEngineId) {
            this.ruleEngineId = ruleEngineId;
            return this;
        }

        public RuleEngineLogVOBuilder ruleEngineName(final String ruleEngineName) {
            this.ruleEngineName = ruleEngineName;
            return this;
        }

        public RuleEngineLogVOBuilder autoTrigger(final Byte autoTrigger) {
            this.autoTrigger = autoTrigger;
            return this;
        }

        public RuleEngineLogVOBuilder triggerType(final String triggerType) {
            this.triggerType = triggerType;
            return this;
        }

        public RuleEngineLogVOBuilder action(final String action) {
            this.action = action;
            return this;
        }

        public RuleEngineLogVOBuilder detail(final String detail) {
            this.detail = detail;
            return this;
        }

        public RuleEngineLogVOBuilder content(final String content) {
            this.content = content;
            return this;
        }

        @JsonFormat(
                pattern = "yyyy-MM-dd HH:mm:ss"
        )
        public RuleEngineLogVOBuilder time(final LocalDateTime time) {
            this.time = time;
            return this;
        }

        public RuleEngineLogVOBuilder updatedBy(final Long updatedBy) {
            this.updatedBy = updatedBy;
            return this;
        }

        public RuleEngineLogVOBuilder updateTime(final String updateTime) {
            this.updateTime = updateTime;
            return this;
        }

        public RuleEngineLogVOBuilder createdBy(final Long createdBy) {
            this.createdBy = createdBy;
            return this;
        }

        public RuleEngineLogVOBuilder createTime(final String createTime) {
            this.createTime = createTime;
            return this;
        }

        public RuleEngineLogVO build() {
            return new RuleEngineLogVO(this.id, this.projectId, this.ruleEngineId, this.ruleEngineName, this.autoTrigger, this.triggerType, this.action, this.detail, this.content, this.time, this.updatedBy, this.updateTime, this.createdBy, this.createTime);
        }

        public String toString() {
            return "RuleEngineLogVO.RuleEngineLogVOBuilder(id=" + this.id + ", projectId=" + this.projectId + ", ruleEngineId=" + this.ruleEngineId + ", ruleEngineName=" + this.ruleEngineName + ", autoTrigger=" + this.autoTrigger + ", triggerType=" + this.triggerType + ", action=" + this.action + ", detail=" + this.detail + ", content=" + this.content + ", time=" + this.time + ", updatedBy=" + this.updatedBy + ", updateTime=" + this.updateTime + ", createdBy=" + this.createdBy + ", createTime=" + this.createTime + ")";
        }
    }
}
