public CovariantCollectionAdapterWithAddNotifications( ICollection <TDerived> source, ItemAddedEventHandler addedEventHandler, AddingItemEventHandler addingEventHandler) : base(source) { if (addingEventHandler != null) { AddingItem += addingEventHandler; // Fire events for existing source items, removing them as necessary source .Where(x => !ShouldIncludeItem(x)) .ToList() .ForEach(x => source.Remove(x)); } if (addedEventHandler != null) { ItemAdded += addedEventHandler; // Fire events for existing source items foreach (var item in source) { OnItemAdded(item); } } }