49 lines
973 B
C#
49 lines
973 B
C#
namespace MP.SPEC.Data
|
|
{
|
|
public class MessageService
|
|
{
|
|
#region Public Events
|
|
|
|
public event Action EA_BroadCastMsg = null!;
|
|
|
|
#endregion Public Events
|
|
|
|
#region Public Properties
|
|
public string newBCMsg
|
|
{
|
|
get => _newBCMsg;
|
|
set
|
|
{
|
|
if(_newBCMsg != value)
|
|
{
|
|
_newBCMsg = value;
|
|
reportMsg();
|
|
}
|
|
}
|
|
}
|
|
|
|
#endregion Public Properties
|
|
|
|
#region Protected Methods
|
|
|
|
protected void reportMsg()
|
|
{
|
|
if (EA_BroadCastMsg != null)
|
|
{
|
|
EA_BroadCastMsg?.Invoke();
|
|
}
|
|
}
|
|
|
|
#endregion Protected Methods
|
|
|
|
#region Private Fields
|
|
|
|
#endregion Private Fields
|
|
|
|
#region Private Properties
|
|
|
|
private string _newBCMsg { get; set; } = "";
|
|
|
|
#endregion Private Properties
|
|
}
|
|
} |