ReadOnlyLinkedElementCollection<T>.FindIndex(Predicate<T>) 方法

定義

尋找符合指定條件的第一個元素。Finds first element which satisfies a given condition.

public:
 int FindIndex(Predicate<T> ^ match);
public int FindIndex (Predicate<T> match);
member this.FindIndex : Predicate<'T (requires 'T :> Microsoft.VisualStudio.Modeling.ModelElement)> -> int
Public Function FindIndex (match As Predicate(Of T)) As Integer

參數

match
Predicate<T>

條件。Condition.

傳回

Int32

清單中的第一個元素,述詞會傳回 true,如果找不到則為 null。First element in the list for which the predicate returns true or null if none found.

適用於