SyntaxNodeExtensions.GetCurrentNode<TNode>(SyntaxNode, TNode) Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets the node within the subtree corresponding to the original tracked node. Use TrackNodes to start tracking nodes.
public:
generic <typename TNode>
where TNode : Microsoft::CodeAnalysis::SyntaxNode[System::Runtime::CompilerServices::Extension]
static TNode GetCurrentNode(Microsoft::CodeAnalysis::SyntaxNode ^ root, TNode node);
public static TNode GetCurrentNode<TNode> (this Microsoft.CodeAnalysis.SyntaxNode root, TNode node) where TNode : Microsoft.CodeAnalysis.SyntaxNode;
public static TNode? GetCurrentNode<TNode> (this Microsoft.CodeAnalysis.SyntaxNode root, TNode node) where TNode : Microsoft.CodeAnalysis.SyntaxNode;
static member GetCurrentNode : Microsoft.CodeAnalysis.SyntaxNode * 'Node -> 'Node (requires 'Node :> Microsoft.CodeAnalysis.SyntaxNode)
<Extension()>
Public Function GetCurrentNode(Of TNode As SyntaxNode) (root As SyntaxNode, node As TNode) As TNode
Type Parameters
- TNode
Parameters
- root
- SyntaxNode
The root of the subtree containing the current node corresponding to the original tracked node.
- node
- TNode
The node instance originally tracked.
Returns
TNode
Applies to
GitHub에서 Microsoft와 공동 작업
이 콘텐츠의 원본은 GitHub에서 찾을 수 있으며, 여기서 문제와 끌어오기 요청을 만들고 검토할 수도 있습니다. 자세한 내용은 참여자 가이드를 참조하세요.
.NET