private void Stream_GroupReceived(string json) { var obj = Json.Convert.FromJson <List <Data.Alarm> >(json); if (obj != null) { foreach (var alarm in obj) { AlarmReceived?.Invoke(alarm); } } }
protected virtual void OnAlarmReceived(string data) { AlarmReceived?.Invoke(this, data); }