/// <summary> /// Add a subscriber to the list of subscribers /// </summary> /// <param name="subscriber"></param> /// <returns>True if added successfully or false otherwise</returns> public bool AddSubscriber(ILogSubscriber subscriber) { // Add subscriber only if it doesn't exist Type subType = subscriber.GetType(); if (Subscribers.All(c => c.GetType() != subType)) { Subscribers.Add(subscriber); return(true); } return(false); }