Class
ObservableItemCollection<T>

Represents an observable collection that provides notifications for both collection changes and property changes of individual items. This class extends ObservableCollection<T> to provide enhanced item tracking capabilities.

Definition

Namespace:Telerik.Maui

Assembly:Telerik.Maui.Core.dll

Type Parameters:

T

The type of elements in the collection.

Syntax:

cs-api-definition
public class ObservableItemCollection<T> : ObservableCollection<T>, IList<T>, ICollection<T>, IList, ICollection, IReadOnlyList<T>, IReadOnlyCollection<T>, IEnumerable<T>, IEnumerable, INotifyCollectionChanged, INotifyPropertyChanged

Inheritance: objectCollection<T>ObservableCollection<T>ObservableItemCollection<T>

Derived Classes: PdfViewerSelectionMenuItemCollection

Implements: ICollectionICollection<T>IEnumerableIEnumerable<T>IListIList<T>INotifyCollectionChangedINotifyPropertyChangedIReadOnlyCollection<T>IReadOnlyList<T>

Inherited Members ObservableCollection<T>.Move(int, int)ObservableCollection<T>.RemoveItem(int)ObservableCollection<T>.InsertItem(int, T)ObservableCollection<T>.SetItem(int, T)ObservableCollection<T>.MoveItem(int, int)ObservableCollection<T>.OnPropertyChanged(PropertyChangedEventArgs)ObservableCollection<T>.OnCollectionChanged(NotifyCollectionChangedEventArgs)ObservableCollection<T>.BlockReentrancy()ObservableCollection<T>.CheckReentrancy()ObservableCollection<T>.CollectionChangedObservableCollection<T>.PropertyChangedCollection<T>.Add(T)Collection<T>.Clear()Collection<T>.CopyTo(T[], int)Collection<T>.Contains(T)Collection<T>.GetEnumerator()Collection<T>.IndexOf(T)Collection<T>.Insert(int, T)Collection<T>.Remove(T)Collection<T>.RemoveAt(int)Collection<T>.CountCollection<T>.ItemsCollection<T>.this[int]

Constructors

ObservableItemCollection()

Initializes a new instance of the ObservableItemCollection<T> class.

Declaration

cs-api-definition
public ObservableItemCollection()

Methods

ClearItems()

Removes all items from the collection while preserving item tracking capabilities.

Declaration

cs-api-definition
protected override void ClearItems()

Overrides ObservableCollection<T>.ClearItems()

Events

ItemAdded

Occurs when an item is added to the collection.

Declaration

cs-api-definition
public event EventHandler<ObservableItemCollectionChangedEventArgs<T>> ItemAdded

Event Value

EventHandler<ObservableItemCollectionChangedEventArgs<T>>

ItemPropertyChanged

Occurs when a property of an item in the collection changes. This event is only raised for items that implement INotifyPropertyChanged.

Declaration

cs-api-definition
public event EventHandler<ItemPropertyChangedEventArgs<T>> ItemPropertyChanged

Event Value

EventHandler<ItemPropertyChangedEventArgs<T>>

ItemRemoved

Occurs when an item is removed from the collection.

Declaration

cs-api-definition
public event EventHandler<ObservableItemCollectionChangedEventArgs<T>> ItemRemoved

Event Value

EventHandler<ObservableItemCollectionChangedEventArgs<T>>