private void RemoveNamedEvent(NamedEventOption option) { events.ToList().Remove(events.FirstOrDefault(x => x.ProfileName == option.ProfileName && x.EventName == option.EventName)); }
private IEvent GetNamedEvent(NamedEventOption option) { return(events.Where(x => x.ProfileName == option.ProfileName) .FirstOrDefault(x => x.EventName == option.EventName)); }