CSharpSyntaxNode.FindToken(Int32, Boolean) 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.
Finds a token according to the following rules:
If position matches the End of the node/s FullSpan and the node is CompilationUnit, then EoF is returned.
If node.FullSpan.Contains(position) then the token that contains given position is returned.
Otherwise an ArgumentOutOfRangeException is thrown
public Microsoft.CodeAnalysis.SyntaxToken FindToken (int position, bool findInsideTrivia = false);
override this.FindToken : int * bool -> Microsoft.CodeAnalysis.SyntaxToken
Public Function FindToken (position As Integer, Optional findInsideTrivia As Boolean = false) As SyntaxToken
Parameters
- position
- Int32
- findInsideTrivia
- Boolean
Returns
Applies to
Collaborer avec nous sur GitHub
La source de ce contenu se trouve sur GitHub, où vous pouvez également créer et examiner les problèmes et les demandes de tirage. Pour plus d’informations, consultez notre guide du contributeur.