ObservableCollection<T>.OnCollectionChanged(NotifyCollectionChangedEventArgs) ObservableCollection<T>.OnCollectionChanged(NotifyCollectionChangedEventArgs) ObservableCollection<T>.OnCollectionChanged(NotifyCollectionChangedEventArgs) ObservableCollection<T>.OnCollectionChanged(NotifyCollectionChangedEventArgs) Method

정의

제공된 인수를 사용하여 CollectionChanged 이벤트를 발생시킵니다.Raises the CollectionChanged event with the provided arguments.

protected:
 virtual void OnCollectionChanged(System::Collections::Specialized::NotifyCollectionChangedEventArgs ^ e);
protected virtual void OnCollectionChanged (System.Collections.Specialized.NotifyCollectionChangedEventArgs e);
abstract member OnCollectionChanged : System.Collections.Specialized.NotifyCollectionChangedEventArgs -> unit
override this.OnCollectionChanged : System.Collections.Specialized.NotifyCollectionChangedEventArgs -> unit
Protected Overridable Sub OnCollectionChanged (e As NotifyCollectionChangedEventArgs)

매개 변수

예제

이 메서드를 재정의할 때 기본 구현을 호출 하거나 사용 하 여는 BlockReentrancy 다음 예제와 같이 재진입 컬렉션을 처리 하는 메서드를 변경 합니다.When overriding this method, either call the base implementation or use the BlockReentrancy method to handle reentrant collection changes, as in the following example:

using (BlockReentrancy())
{
    // OnCollectionChanged call
}
Using BlockReentrancy()
	' OnCollectionChanged call
End Using

설명

이 컬렉션 생성을 수정 하는 메서드와 속성을 CollectionChanged 이 통해 이벤트 virtual 메서드.Properties and methods that modify this collection raise the CollectionChanged event through this virtual method.

적용 대상