Table of Contents

Class SyntaxSelection

Namespace
RDCore.SDK.Model.AST.Abstract
Assembly
RDCore.SDK.dll

What a selection grows to, step by step, from a position of a module (LSP 3.17 §Selection Range Request): each node of the syntax tree that is written around the position, from the innermost - a name - to the outermost - the whole module.

public static class SyntaxSelection
Inheritance
SyntaxSelection
Inherited Members

Remarks

The tree is walked as it is written (SyntaxNodeWalk), the statements of the blocks of structured statements included: a selection in the body of an If grows to its statement, then to the whole If block, then to the procedure.

Methods

RangesAt(ModuleNode, SourcePosition)

The ranges a selection at position grows to.

public static IReadOnlyList<SourceRange> RangesAt(ModuleNode module, SourcePosition position)

Parameters

module ModuleNode

The syntax tree of the module.

position SourcePosition

The position.

Returns

IReadOnlyList<SourceRange>

The ranges, innermost first, each in the next; the last is the whole of what the module declares. None for a position outside of it.