owner node and other related information according to the position
| Property | Modifier | Type | Description |
|---|
char | readonly | number | UTF-16 code unit at position, or NaN outside the source text. |
getPositionDetailAfterTrivia | readonly | () => PositionDetail | get the PositionDetail of positionAfterTrivia |
getPositionDetailBeforeTrivia | readonly | () => PositionDetail | get the PositionDetail of positionBeforeTrivia |
inTrivia | readonly | boolean | Whether the position query identifies whitespace or comment trivia at this offset. |
nextChar | readonly | number | UTF-16 code unit immediately after position, or NaN outside the source text. |
node | readonly | Node | undefined | Most specific node accepted by the position query, or undefined when none matches. |
position | readonly | number | Queried zero-based UTF-16 offset in the source file. |
preChar | readonly | number | UTF-16 code unit immediately before position, or NaN outside the source text. |
triviaEndPosition | readonly | number | if the position is in a trivia, return the end position (exclude as other ‘end’ means) of the trivia containing the position if the position is not a trivia, return the end position (exclude as other ‘end’ means) of the trivia after the node containing the position Please be aware that this may not be the next node in the tree because some non-trivia char is ignored in the tree but will considered here also comments are considered as trivia |
triviaStartPosition | readonly | number | if the position is in a trivia, return the start position of the trivia containing the position if the position is not a trivia, return the start position of the trivia before the text(identifier code) containing the position Please be aware that this may not be the pre node in the tree because some non-trivia char is ignored in the tree but will counted here also comments are considered as trivia |