public Domain.TimedEvent DisableEvent(Enums.TimedEvent eventType) { if (_events.TryGetValue(eventType, out var evnt)) { evnt.Disable(); _events.AddOrUpdate(eventType, evnt, (key, oldValue) => evnt); return(evnt); } else { var err = $"Failed to disable event {eventType}"; Log.Error(new Exception(err), err); return(null); } }
public Domain.TimedEvent UpdateEvent(Enums.TimedEvent eventType, Domain.TimedEvent evnt) { _events.AddOrUpdate(eventType, evnt, (key, oldValue) => evnt); return(evnt); }
public Domain.TimedEvent GetEvent(Enums.TimedEvent eventType) { return(_events[eventType]); }