package com.xzzn.ems.domain;

import com.xzzn.common.core.domain.BaseEntity;
import org.apache.commons.lang3.builder.ToStringBuilder;
import org.apache.commons.lang3.builder.ToStringStyle;
import com.xzzn.common.annotation.Excel;

/**
 * 故障告警保护方案对象 ems_fault_protection_plan
 *
 * @author xzzn
 * @date 2025-10-24
 */
public class EmsFaultProtectionPlan extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    /** 主键 */
    private Long id;

    /** 站点id */
    @Excel(name = "站点id")
    private String siteId;

    /** 故障名称（如：总压高、放电总压过低） */
    @Excel(name = "故障名称", readConverterExp = "如=：总压高、放电总压过低")
    private String faultName;

    /** 故障等级（1级/2级/3级） */
    @Excel(name = "故障等级", readConverterExp = "1=级/2级/3级")
    private Integer faultLevel;

    /** 保护设置：点位/故障值/比较方式/释放值等 */
    @Excel(name = "保护设置：点位/故障值/比较方式/释放值等")
    private String protectionSettings;

    /** 故障延时（秒，如：3S→3） */
    @Excel(name = "故障延时", readConverterExp = "秒=，如：3S→3")
    private Long faultDelaySeconds;

    /** 保护方案：修改目标点位和值 */
    @Excel(name = "保护方案：修改目标点位和值")
    private String protectionPlan;

    /** 释放延时（秒，如：5S→5，3级可能无） */
    @Excel(name = "释放延时", readConverterExp = "秒=，如：5S→5，3级可能无")
    private Long releaseDelaySeconds;

    /** 处理方案描述（例如：报警，降功率50%运行） */
    @Excel(name = "处理方案描述", readConverterExp = "例=如：报警，降功率50%运行")
    private String description;

    /** 是否触发告警（0 - 不告警；1 - 告警） */
    @Excel(name = "是否触发告警", readConverterExp = "0=不告警；1=告警")
    private Integer isAlert;

    /** 方案是否启用 0-未启用 1-已启用 */
    @Excel(name = "方案是否启用 0-未启用 1-已启用")
    private Long status;

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

    public Long getId()
    {
        return id;
    }

    public void setSiteId(String siteId)
    {
        this.siteId = siteId;
    }

    public String getSiteId()
    {
        return siteId;
    }

    public void setFaultName(String faultName)
    {
        this.faultName = faultName;
    }

    public String getFaultName()
    {
        return faultName;
    }

    public void setFaultLevel(Integer faultLevel)
    {
        this.faultLevel = faultLevel;
    }

    public Integer getFaultLevel()
    {
        return faultLevel;
    }

    public void setProtectionSettings(String protectionSettings)
    {
        this.protectionSettings = protectionSettings;
    }

    public String getProtectionSettings()
    {
        return protectionSettings;
    }

    public void setFaultDelaySeconds(Long faultDelaySeconds)
    {
        this.faultDelaySeconds = faultDelaySeconds;
    }

    public Long getFaultDelaySeconds()
    {
        return faultDelaySeconds;
    }

    public void setProtectionPlan(String protectionPlan)
    {
        this.protectionPlan = protectionPlan;
    }

    public String getProtectionPlan()
    {
        return protectionPlan;
    }

    public void setReleaseDelaySeconds(Long releaseDelaySeconds)
    {
        this.releaseDelaySeconds = releaseDelaySeconds;
    }

    public Long getReleaseDelaySeconds()
    {
        return releaseDelaySeconds;
    }

    public void setDescription(String description)
    {
        this.description = description;
    }

    public String getDescription()
    {
        return description;
    }

    public void setIsAlert(Integer isAlert)
    {
        this.isAlert = isAlert;
    }

    public Integer getIsAlert()
    {
        return isAlert;
    }

    public void setStatus(Long status)
    {
        this.status = status;
    }

    public Long getStatus()
    {
        return status;
    }

    @Override
    public String toString() {
        return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
                .append("id", getId())
                .append("siteId", getSiteId())
                .append("faultName", getFaultName())
                .append("faultLevel", getFaultLevel())
                .append("protectionSettings", getProtectionSettings())
                .append("faultDelaySeconds", getFaultDelaySeconds())
                .append("protectionPlan", getProtectionPlan())
                .append("releaseDelaySeconds", getReleaseDelaySeconds())
                .append("description", getDescription())
                .append("isAlert", getIsAlert())
                .append("status", getStatus())
                .append("createBy", getCreateBy())
                .append("createTime", getCreateTime())
                .append("updateBy", getUpdateBy())
                .append("updateTime", getUpdateTime())
                .toString();
    }
}
