Skip to main content

StatementListInfo.IndexOf Method

Containing Type: StatementListInfo

Assembly: Roslynator.CSharp.dll

Overloads

MethodSummary
IndexOf(Func<StatementSyntax, Boolean>)Searches for a statement that matches the predicate and returns zero-based index of the first occurrence in the list.
IndexOf(StatementSyntax)The index of the statement in the list.

IndexOf(Func<StatementSyntax, Boolean>)

Searches for a statement that matches the predicate and returns zero-based index of the first occurrence in the list.

public int IndexOf(Func<Microsoft.CodeAnalysis.CSharp.Syntax.StatementSyntax, bool> predicate)

Parameters

predicate Func<StatementSyntax, Boolean>

Returns

Int32

IndexOf(StatementSyntax)

The index of the statement in the list.

public int IndexOf(Microsoft.CodeAnalysis.CSharp.Syntax.StatementSyntax statement)

Parameters

statement StatementSyntax

Returns

Int32