static public EventParams Create(string key, object val) { var param = new EventParams(); param._map.Add(key, val); return(param); }
void Broadcast(string eventId, EventParams eventParams) { if (_subscribers.ContainsKey(EVENT_BROADCAST)) { foreach (var subscriber in _subscribers[EVENT_BROADCAST]) { subscriber.OnNotified(eventId, eventParams); } } }
void Notify(string eventId, EventParams eventParams) { if (_subscribers.ContainsKey(eventId)) { foreach (var subscriber in _subscribers[eventId]) { subscriber.OnNotified(eventId, eventParams); } } }
protected void NotifyAboutEvent(string eventId, EventParams eventParams) { Notify(eventId, eventParams); Broadcast(eventId, eventParams); }