public override void AddStory(NewsStory story) { foreach (var subQ in _subscriberQueues.Values) { subQ.AddStory(story); } }
public async Task AddStory(NewsStory item) { try { await _context.News.InsertOneAsync(item); } catch (Exception ex) { // log or manage the exception throw ex; } }
public void Put(NewsStory story) { EnsureChannelExists(story.Tag); head.AddStory(story); }
public virtual void AddStory(NewsStory story) { storyQueue.Enqueue(story); OnStoryAdded?.Invoke(story); }