using System.Collections.Generic;

namespace MWS.Model.Dto
{

    public class FuntionTagDto
    {
        /// <summary>
        /// 功能码 x=3
        /// </summary>
        public string FuntionCode { get; set; }

        /// <summary>
        /// 变量分组
        /// </summary>
        public List<AddressData> Addresses { get; set; }
    }
    public class AddressData
    {

        /// <summary>
        /// 变量编码对应地址的集合
        /// </summary>
        public List<PositionData> Tags { get; set; }

        /// <summary>
        /// 最小的地址
        /// </summary>
        public string Min { get; set; }

        /// <summary>
        /// 最大的地址
        /// </summary>
        public string Max { get; set; }

        /// <summary>
        /// 最大值数据类型
        /// </summary>
        public short LastTagDataType { get; set; }


    }

    /// <summary>
    /// 变量对应位置相关数据
    /// </summary>
    public class PositionData
    {
        /// <summary>
        /// 变量编码
        /// </summary>
        public int Id { get; set; }

        /// <summary>
        /// 变量名称
        /// </summary>
        public string Name { get; set; }

        /// <summary>
        /// 变量对应的地址位置
        /// </summary>
        public string Position { get; set; }


        /// <summary>
        /// ModubsDataType
        /// </summary>
        public short SourceDataType { get; set; }

        /// <summary>
        /// 数据类型
        /// </summary>
        public short DataType { get; set; }

        /// <summary>
        /// 变量地址
        /// </summary>
        public string Address { get; set; }

        /// <summary>
        /// 是否取反
        /// </summary>
        public bool IsReverse { get; set; }

        /// <summary>
        /// 变量类型
        /// </summary>
        public short TagType { get; set; }

        /// <summary>
        /// 折算率
        /// </summary>
        public float Translate { get; set; }

        /// <summary>
        /// 是否需要标定
        /// </summary>
        public bool IsCalibration { get; set; }

        /// <summary>
        /// 机构
        /// </summary>
        public short MecType { get; set; }

        /// <summary>
        /// 是否报警
        /// </summary>
        public bool IsAlert { get; set; }
    }
}