NotifyCollectionChangedExtensions.

WeakSubscribe(INotifyCollectionChanged, NotifyCollectionChangedEventHandler) Method

Summary

Subscribes to the CollectionChanged event using a weak subscription.

Syntax

public static IDisposable WeakSubscribe(this INotifyCollectionChanged collection, NotifyCollectionChangedEventHandler handler)

Parameters

Name Type Description
collection INotifyCollectionChanged The collection.
handler NotifyCollectionChangedEventHandler An action called when the collection event is raised.

Return Value

Type Description
IDisposable A disposable used to terminate the subscription.