ListBase<(Of <(<'T>)>)> Methods
The ListBase<(Of <(<'T>)>)> type exposes the following members.
Methods
Name | Description | |
---|---|---|
![]() |
Add |
Adds an item to the end of the list. This method is equivalent to calling:
C# Insert(Count, item) |
![]() |
AsReadOnly |
Provides a read-only view of this list. The returned IList<T> provides
a view of the list that prevents modifications to the list. Use the method to provide
access to the list without allowing changes. Since the returned object is just a view,
changes to the list will be reflected in the view.
|
![]() |
Clear |
This method must be overridden by the derived class to empty the list
of all items.
|
![]() |
Contains |
Determines if the list contains any item that compares equal to item.
The implementation simply checks whether IndexOf(item) returns a non-negative value.
|
![]() |
CopyTo(array<T>[]()[][]) |
Copies all the items in the list, in order, to array,
starting at index 0.
|
![]() |
CopyTo(array<T>[]()[][], Int32) |
Copies all the items in the list, in order, to array,
starting at arrayIndex.
|
![]() |
CopyTo(Int32, array<T>[]()[][], Int32, Int32) |
Copies a range of elements from the list to array,
starting at arrayIndex.
|
![]() |
Find |
Finds the first item in the list that satisfies the condition
defined by predicate. If no item matches the condition, than
the default value for T (null or all-zero) is returned.
|
![]() |
FindIndex(Predicate<(Of <<'(T>)>>)) |
Finds the index of the first item in the list that satisfies the condition
defined by predicate. If no item matches the condition, -1 is returned.
|
![]() |
FindIndex(Int32, Predicate<(Of <<'(T>)>>)) |
Finds the index of the first item, in the range of items extending from index to the end, that satisfies the condition
defined by predicate. If no item matches the condition, -1 is returned.
|
![]() |
FindIndex(Int32, Int32, Predicate<(Of <<'(T>)>>)) |
Finds the index of the first item, in the range of count items starting from index, that satisfies the condition
defined by predicate. If no item matches the condition, -1 is returned.
|
![]() |
FindLast |
Finds the last item in the list that satisfies the condition
defined by predicate. If no item matches the condition, than
the default value for T (null or all-zero) is returned.
|
![]() |
FindLastIndex(Predicate<(Of <<'(T>)>>)) |
Finds the index of the last item in the list that satisfies the condition
defined by predicate. If no item matches the condition, -1 is returned.
|
![]() |
FindLastIndex(Int32, Predicate<(Of <<'(T>)>>)) |
Finds the index of the last item, in the range of items extending from the beginning
of the list to index, that satisfies the condition
defined by predicate. If no item matches the condition, -1 is returned.
|
![]() |
FindLastIndex(Int32, Int32, Predicate<(Of <<'(T>)>>)) |
Finds the index of the last item, in the range of count items ending at index, that satisfies the condition
defined by predicate. If no item matches the condition, -1 is returned.
|
![]() |
GetEnumerator |
Enumerates all of the items in the list, in order. The item at index 0
is enumerated first, then the item at index 1, and so on.
|
![]() |
IndexOf(T) |
Finds the index of the first item in the list that is equal to item.
|
![]() |
IndexOf(T, Int32) |
Finds the index of the first item, in the range of items extending from index to the end,
that is equal to item.
|
![]() |
IndexOf(T, Int32, Int32) |
Finds the index of the first item, in the range of count items starting from index,
that is equal to item.
|
![]() |
Insert |
This method must be overridden by the derived class to insert a new
item at the given index.
|
![]() |
LastIndexOf(T) |
Finds the index of the last item in the list that is equal to item.
|
![]() |
LastIndexOf(T, Int32) |
Finds the index of the last item, in the range of items extending from the beginning
of the list to index, that is equal to item.
|
![]() |
LastIndexOf(T, Int32, Int32) |
Finds the index of the last item, in the range of count items ending at index,
that is equal to item.
|
![]() |
Range |
Returns a view onto a sub-range of this list. Items are not copied; the
returned IList<T> is simply a different view onto the same underlying items. Changes to this list
are reflected in the view, and vice versa. Insertions and deletions in the view change the size of the
view, but insertions and deletions in the underlying list do not.
|
![]() |
Remove |
Searches the list for the first item that compares equal to item.
If one is found, it is removed. Otherwise, the list is unchanged.
|
![]() |
RemoveAt |
This method must be overridden by the derived class to remove the
item at the given index.
|
![]() |
TryFind |
Finds the first item in the list that satisfies the condition
defined by predicate.
|
![]() |
TryFindLast |
Finds the last item in the list that satisfies the condition
defined by predicate.
|