SyntaxExtensions.IsKind Method
Containing Type: SyntaxExtensions
Assembly: Roslynator.CSharp.dll
Overloads
IsKind(SyntaxNode, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a node's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxNode? node, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind5, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind6)
Parameters
node SyntaxNode
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
kind5 SyntaxKind
kind6 SyntaxKind
Returns
IsKind(SyntaxNode, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a node's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxNode? node, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind5)
Parameters
node SyntaxNode
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
kind5 SyntaxKind
Returns
IsKind(SyntaxNode, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a node's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxNode? node, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4)
Parameters
node SyntaxNode
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
Returns
IsKind(SyntaxNode, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a node's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxNode? node, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3)
Parameters
node SyntaxNode
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
Returns
IsKind(SyntaxNode, SyntaxKind, SyntaxKind)
Returns true if a node's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxNode? node, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2)
Parameters
node SyntaxNode
kind1 SyntaxKind
kind2 SyntaxKind
Returns
IsKind(SyntaxToken, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxToken token, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind5, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind6)
Parameters
token SyntaxToken
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
kind5 SyntaxKind
kind6 SyntaxKind
Returns
IsKind(SyntaxToken, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxToken token, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind5)
Parameters
token SyntaxToken
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
kind5 SyntaxKind
Returns
IsKind(SyntaxToken, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxToken token, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4)
Parameters
token SyntaxToken
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
Returns
IsKind(SyntaxToken, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxToken token, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3)
Parameters
token SyntaxToken
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
Returns
IsKind(SyntaxToken, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxToken token, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2)
Parameters
token SyntaxToken
kind1 SyntaxKind
kind2 SyntaxKind
Returns
IsKind(SyntaxTrivia, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxTrivia trivia, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind5, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind6)
Parameters
trivia SyntaxTrivia
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
kind5 SyntaxKind
kind6 SyntaxKind
Returns
IsKind(SyntaxTrivia, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxTrivia trivia, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind5)
Parameters
trivia SyntaxTrivia
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
kind5 SyntaxKind
Returns
IsKind(SyntaxTrivia, SyntaxKind, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxTrivia trivia, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind4)
Parameters
trivia SyntaxTrivia
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
kind4 SyntaxKind
Returns
IsKind(SyntaxTrivia, SyntaxKind, SyntaxKind, SyntaxKind)
Returns true if a token's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxTrivia trivia, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind3)
Parameters
trivia SyntaxTrivia
kind1 SyntaxKind
kind2 SyntaxKind
kind3 SyntaxKind
Returns
IsKind(SyntaxTrivia, SyntaxKind, SyntaxKind)
Returns true if a trivia's kind is one of the specified kinds.
public static bool IsKind(this Microsoft.CodeAnalysis.SyntaxTrivia trivia, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind1, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind2)
Parameters
trivia SyntaxTrivia
kind1 SyntaxKind
kind2 SyntaxKind