Click or drag to resize

VisualBasicExtensionsIsKind Method (SyntaxNode, SyntaxKind)



Determines if SyntaxNode is a specified kind.

Namespace:  Microsoft.CodeAnalysis
Assembly:  Microsoft.CodeAnalysis.VisualBasic (in Microsoft.CodeAnalysis.VisualBasic.dll) Version: 2.3.0-dev-56735-00. Commit Hash: <developer build>
Syntax
public static bool IsKind(
	this SyntaxNode node,
	SyntaxKind kind
)

Parameters

node
Type: Microsoft.CodeAnalysisSyntaxNode
The Source SyntaxNode.
kind
Type: Microsoft.CodeAnalysis.VisualBasicSyntaxKind
The SyntaxKind to test for.

Return Value

Type: Boolean
A boolean value if node is of specified kind; otherwise false.

Usage Note

In Visual Basic and C#, you can call this method as an instance method on any object of type SyntaxNode. When you use instance method syntax to call this method, omit the first parameter. For more information, see Extension Methods (Visual Basic) or Extension Methods (C# Programming Guide).
See Also