You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
|
|
namespace ZJ_BYD.Untils
|
|
|
|
|
{
|
|
|
|
|
public class MyEventHandler
|
|
|
|
|
{
|
|
|
|
|
#region 初始化
|
|
|
|
|
private string log = "-1";
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 值变化委托
|
|
|
|
|
/// </summary>
|
|
|
|
|
/// <param name="newValue"></param>
|
|
|
|
|
/// <param name="stationCode"></param>
|
|
|
|
|
public delegate void LogChangedEventHandler(object newValue, string stationCode);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 只有Key改变,Value还未改变
|
|
|
|
|
/// </summary>
|
|
|
|
|
public event LogChangedEventHandler LogChanged;
|
|
|
|
|
|
|
|
|
|
public string StationCode { get; set; }
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 获得或设置编号
|
|
|
|
|
/// </summary>
|
|
|
|
|
public string Log
|
|
|
|
|
{
|
|
|
|
|
get { return log; }
|
|
|
|
|
set
|
|
|
|
|
{
|
|
|
|
|
log = value;
|
|
|
|
|
if (LogChanged != null)
|
|
|
|
|
{
|
|
|
|
|
LogChanged(log, StationCode);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
#endregion
|
|
|
|
|
}
|
|
|
|
|
}
|