dc/Common/SimulatorInfo.cs
13118993771@163.com 5e9d0f1e2d EAP
2022-04-01 17:03:54 +08:00

44 lines
1.6 KiB
C#

using Glorysoft.SECS.EQP.Common;
using System;
using System.Collections;
namespace Glorysoft.SECS.EQP
{
public class SimulatorInfo
{
#region
public delegate void PropertyChangedEventHandler();
public event PropertyChangedEventHandler PropertyChanged;
protected virtual void OnPropertyChanged()
{
PropertyChanged?.Invoke();
}
#endregion
private static readonly Lazy<SimulatorInfo> LazyInstance = new Lazy<SimulatorInfo>(() => new SimulatorInfo());
private SimulatorInfo()
{
}
public static SimulatorInfo Instance => LazyInstance.Value;
public SECSContext Context { get; set; }
private bool _isConnected = false;
public bool IsConnected { get { return _isConnected; } set { if (_isConnected != value) { _isConnected = value; OnPropertyChanged(); } } }
private string _showInfo;
public string ShowInfo { get { return _showInfo; } set { if (_showInfo != value) { _showInfo = value; if (!string.IsNullOrWhiteSpace(value)) OnPropertyChanged(); } } }
private string _recipeList;
public string RecipeList { get { return _recipeList; } set { if (_recipeList != value) { _recipeList = value; if (!string.IsNullOrWhiteSpace(value)) OnPropertyChanged(); } } }
private string _workFLowFlag;
public string WorkFLowFlag { get { return _workFLowFlag; } set { if (_workFLowFlag != value) { _workFLowFlag = value; if (!string.IsNullOrWhiteSpace(value)) OnPropertyChanged(); } } }
public ScenarioCollection Scenarios { get; set; }
}
}