PostSharp 6.10 / / Post­Sharp Documentation / API Reference / Post­Sharp.​Patterns.​Collections Namespace / Advisable­Collection(T) Class / Advisable­Collection(T) Methods / Advisable­Collection(T).​Index­Of­Item Method

AdvisableCollection<T>.IndexOfItem Method

Searches for the specified object and returns the zero-based index of the first occurrence within the entire underlying collection.

Namespace:  PostSharp.Patterns.Collections
Assembly:  PostSharp.Patterns.Common (in PostSharp.Patterns.Common.dll) Version: (
protected virtual int IndexOfItem(
	T item


Type: T
The object to locate in the AdvisableCollection<T>. The value can be null for reference types.

Return Value

Type: Int32
The zero-based index of the first occurrence of item within the entire AdvisableCollection<T>, if found; otherwise, -1.
See Also