Skip to main content

IAvaloniaList<T> Interface

A notifying list.

Definition

Namespace: Avalonia.Collections
Assembly: Avalonia.Base (in Avalonia.Base.dll)

public interface IAvaloniaList<T> : IList<T>, 
ICollection<T>, IEnumerable<T>, IEnumerable, IAvaloniaReadOnlyList<T>, IReadOnlyList<T>,
IReadOnlyCollection<T>, INotifyCollectionChanged, INotifyPropertyChanged

View Source
ImplementsIAvaloniaReadOnlyList(T), ICollection(T), IEnumerable(T), IList(T), IReadOnlyCollection(T), IReadOnlyList(T), IEnumerable, INotifyCollectionChanged, INotifyPropertyChanged

Type Parameters

The type of the items in the list.

Properties

CountGets the number of items in the list.
IsReadOnlyGets a value indicating whether the ICollection(T) is read-only.
(Inherited from ICollection(T))
Item(Int32)Gets or sets the element at the specified index.

Methods

Add(T)Adds an item to the ICollection(T).
(Inherited from ICollection(T))
AddRange(IEnumerable(T))Adds multiple items to the collection.
Clear()Removes all items from the ICollection(T).
(Inherited from ICollection(T))
Contains(T)Determines whether the ICollection(T) contains a specific value.
(Inherited from ICollection(T))
CopyTo(T[], Int32)Copies the elements of the ICollection(T) to an Array, starting at a particular Array index.
(Inherited from ICollection(T))
GetEnumerator()Returns an enumerator that iterates through the collection.
(Inherited from IEnumerable(T))
IndexOf(T)Determines the index of a specific item in the IList(T).
(Inherited from IList(T))
Insert(Int32, T)Inserts an item to the IList(T) at the specified index.
(Inherited from IList(T))
InsertRange(Int32, IEnumerable(T))Inserts multiple items at the specified index.
Move(Int32, Int32)Moves an item to a new index.
MoveRange(Int32, Int32, Int32)Moves multiple items to a new index.
Remove(T)Removes the first occurrence of a specific object from the ICollection(T).
(Inherited from ICollection(T))
RemoveAll(IEnumerable(T))Removes multiple items from the collection.
RemoveAt(Int32)Removes the IList(T) item at the specified index.
(Inherited from IList(T))
RemoveRange(Int32, Int32)Removes a range of elements from the collection.

Events

CollectionChangedOccurs when the collection changes.
(Inherited from INotifyCollectionChanged)
PropertyChangedOccurs when a property value changes.
(Inherited from INotifyPropertyChanged)

Extension Methods

ForEachItem(T)(Action(T), Action(T), Action, Boolean)Invokes an action for each item in a collection and subsequently each item added or removed from the collection.
(Defined by AvaloniaListExtensions)
ForEachItem(T)(Action(Int32, T), Action(Int32, T), Action, Boolean)Invokes an action for each item in a collection and subsequently each item added or removed from the collection.
(Defined by AvaloniaListExtensions)
GetWeakCollectionChangedObservable()Gets a weak observable for the CollectionChanged event.
(Defined by NotifyCollectionChangedExtensions)
TrackItemPropertyChanged(T)(Action(Tuple(Object, PropertyChangedEventArgs)))Listens for property changed events from all items in a collection.
(Defined by AvaloniaListExtensions)
WeakSubscribe(Action(NotifyCollectionChangedEventArgs))Subscribes to the CollectionChanged event using a weak subscription.
(Defined by NotifyCollectionChangedExtensions)
WeakSubscribe(NotifyCollectionChangedEventHandler)Subscribes to the CollectionChanged event using a weak subscription.
(Defined by NotifyCollectionChangedExtensions)

See Also

Reference

Avalonia.Collections Namespace