using System.Collections.Generic;
namespace Highway.Assemble.common
{
public interface ISoftInfo
{
Mode mode { get; set; }
///
/// 汇集软件配置信息
///
Collect CollectInfo { get; set; }
///
/// 设备信息列表
///
List EquipList { get; set; }
///
/// MES信息列表
///
List mesSoftList { get; set; }
///
///传感器信息列表
///
List SensorList { get; set; }
}
public class SoftInfo : ISoftInfo
{
private List m_mesSoftList = new List(20);
public List m_EquipList = new List(80);
public Mode mode { get; set; } = Mode.Triangle; //这里修改默认值
public Collect CollectInfo { get; set; }
object Equiplock = new object();
///
/// 设备信息列表
///
public List EquipList
{
get
{
lock (Equiplock)
{
return m_EquipList;
}
}
set
{
lock (Equiplock)
{
m_EquipList = value;
}
}
}
object mesSoftlock = new object();
///
///MES信息列表
///
public List mesSoftList
{
get
{
lock (mesSoftlock)
{
return m_mesSoftList;
}
}
set
{
lock (mesSoftlock)
{
m_mesSoftList = value;
}
}
}
///
///传感器信息列表
///
public List SensorList { get; set; }
}
public enum Mode
{///
/// 三角轮胎厂
///
Triangle = 0,//威海三角轮胎所用的模式未读取到数据返回NoData
///
/// 新疆昆仑
///
kltyre = 1, //新疆昆仑轮胎厂使用读取不到数据返回空数据 数据位为空
}
}