package org.dromara.shebei.domain.bo;

import org.dromara.shebei.domain.OpsSbMbBianliang;
import org.dromara.common.mybatis.core.domain.BaseEntity;
import org.dromara.common.core.validate.AddGroup;
import org.dromara.common.core.validate.EditGroup;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;
import lombok.EqualsAndHashCode;
import jakarta.validation.constraints.*;

/**
 * 运维-设备管理-设备模板-变量业务对象 ops_sb_mb_bianliang
 *
 * @author LionLi
 * @date 2025-10-09
 */
@Data
@EqualsAndHashCode(callSuper = true)
@AutoMapper(target = OpsSbMbBianliang.class, reverseConvertGenerate = false)
public class OpsSbMbBianliangBo extends BaseEntity {

    /**
     * id
     */
    private Long id;

    /**
     * 模板id
     */
    private Long mbId;

    /**
     * 变量名称
     */
    @NotBlank(message = "变量名称不能为空", groups = { AddGroup.class, EditGroup.class })
    private String blName;

    /**
     * 变量单位
     */
    @NotBlank(message = "变量单位不能为空", groups = { AddGroup.class, EditGroup.class })
    private String blDanwei;

    /**
     * 变量标识符
     */
    @NotBlank(message = "变量标识符不能为空", groups = { AddGroup.class, EditGroup.class })
    private String blBiaoshifu;

    /**
     * 变量类型（1、直采变量）
     */
    @NotBlank(message = "变量类型（1、直采变量）不能为空", groups = { AddGroup.class, EditGroup.class })
    private String blType;

    /**
     * 寄存器功能码
     */
    @NotBlank(message = "寄存器功能码不能为空", groups = { AddGroup.class, EditGroup.class })
    private String jicunqiGnm;

    /**
     * 寄存器地址
     */
    @NotBlank(message = "寄存器地址不能为空", groups = { AddGroup.class, EditGroup.class })
    private String jicunqiAdd;

    /**
     * 数据格式
     */
    @NotBlank(message = "数据格式不能为空", groups = { AddGroup.class, EditGroup.class })
    private String shujvGeshi;

    /**
     * 采集频率
     */
    @NotBlank(message = "采集频率不能为空", groups = { AddGroup.class, EditGroup.class })
    private String caijiPinlu;

    /**
     * 数字格式
     */
    @NotBlank(message = "数字格式不能为空", groups = { AddGroup.class, EditGroup.class })
    private String shuziGeshi;

    /**
     * 存储方式（1、变化存储，2、全部存储）
     */
    @NotBlank(message = "存储方式（1、变化存储，2、全部存储）不能为空", groups = { AddGroup.class, EditGroup.class })
    private String cunchuFangshi;

    /**
     * 读写方式（1、读写，3、只读，5、只写）
     */
    @NotBlank(message = "读写方式（1、读写，3、只读，5、只写）不能为空", groups = { AddGroup.class, EditGroup.class })
    private String duxieFangshi;


}
