IList<T>.LastIndexOf Method
Overloads
| LastIndexOf(T) |
Determines the index of a specific item in the list starting at the end of the list. |
| LastIndexOf(T, Integer) |
Determines the index of a specific item in the list starting at the specified index towards the start of the list. |
| LastIndexOf(T, Integer, Integer) |
Determines the index of a specific item in the list starting at the specified index and for the specified count of elements towards the start of the list. |
Determines the index of a specific item in the list starting at the end of the list.
function LastIndexOf(const item: T): Integer
Parameters
- item
- T
The element to locate in the list.
Returns
The index of item if found in the list; otherwise, -1.
Determines the index of a specific item in the list starting at the specified index towards the start of the list.
function LastIndexOf(const item: T; index: Integer): Integer
Parameters
- item
- T
The element to locate in the list.
- index
- Integer
The index where to start to locate the specified item in the list.
Returns
The index of item if found in the list; otherwise, -1.
Exceptions
index is not a valid index in the list.
Determines the index of a specific item in the list starting at the specified index and for the specified count of elements towards the start of the list.
function LastIndexOf(const item: T; index: Integer; count: Integer): Integer
Parameters
- item
- T
The element to locate in the list.
- index
- Integer
The index where to start to locate the specified item in the list.
- count
- Integer
The number of items to compare item with.
Returns
The index of item if found in the list; otherwise, -1.