C# Class Microsoft.R.Core.AST.AstNode

Inheritance: IAstNode
Mostrar archivo Open project: Microsoft/RTVS

Protected Properties

Property Type Description
_children TextRangeCollection

Public Methods

Method Description
Accept ( Func visitor, object parameter ) : bool
Accept ( IAstVisitor visitor, object parameter ) : bool
AppendChild ( IAstNode child ) : void
Contains ( int position ) : bool
GetElementsEnclosingRange ( int start, int length, IAstNode &startNode, PositionType &startPositionType, IAstNode &endNode, PositionType &endPositionType ) : IAstNode

Finds two nodes that surround given text range

GetPositionNode ( int position, IAstNode &node ) : PositionType

Determines position type and the enclosing node for a given position in the document text.

NodeFromPosition ( int position ) : IAstNode

Finds deepest node that contains given position

NodeFromRange ( ITextRange range, bool inclusiveEnd = false ) : IAstNode

Finds deepest node that fully encloses given range

Parse ( ParseContext context, IAstNode parent = null ) : bool
RemoveChildren ( int start, int count ) : void
Shift ( int offset ) : void
ShiftStartingFrom ( int position, int offset ) : void

Method Details

Accept() public method

public Accept ( Func visitor, object parameter ) : bool
visitor Func
parameter object
return bool

Accept() public method

public Accept ( IAstVisitor visitor, object parameter ) : bool
visitor IAstVisitor
parameter object
return bool

AppendChild() public method

public AppendChild ( IAstNode child ) : void
child IAstNode
return void

Contains() public method

public Contains ( int position ) : bool
position int
return bool

GetElementsEnclosingRange() public method

Finds two nodes that surround given text range
public GetElementsEnclosingRange ( int start, int length, IAstNode &startNode, PositionType &startPositionType, IAstNode &endNode, PositionType &endPositionType ) : IAstNode
start int Range start
length int Range length
startNode IAstNode Node that precedes the range or null if there is none
startPositionType PositionType Type of position in the start node
endNode IAstNode Node that follows the range or null if there is none
endPositionType PositionType Type of position in the end node
return IAstNode

GetPositionNode() public method

Determines position type and the enclosing node for a given position in the document text.
public GetPositionNode ( int position, IAstNode &node ) : PositionType
position int Position in the document text
node IAstNode Node that contains position
return PositionType

NodeFromPosition() public method

Finds deepest node that contains given position
public NodeFromPosition ( int position ) : IAstNode
position int Position
return IAstNode

NodeFromRange() public method

Finds deepest node that fully encloses given range
public NodeFromRange ( ITextRange range, bool inclusiveEnd = false ) : IAstNode
range ITextRange
inclusiveEnd bool
return IAstNode

Parse() public method

public Parse ( ParseContext context, IAstNode parent = null ) : bool
context Microsoft.R.Core.Parser.ParseContext
parent IAstNode
return bool

RemoveChildren() public method

public RemoveChildren ( int start, int count ) : void
start int
count int
return void

Shift() public method

public Shift ( int offset ) : void
offset int
return void

ShiftStartingFrom() public method

public ShiftStartingFrom ( int position, int offset ) : void
position int
offset int
return void

Property Details

_children protected_oe property

protected TextRangeCollection _children
return TextRangeCollection