SyntaxEditor Class
Definition
An editor for making changes to a syntax tree.
public ref class SyntaxEditor
public class SyntaxEditor
type SyntaxEditor = class
Public Class SyntaxEditor
- Inheritance
-
SyntaxEditor
- Derived
Constructors
SyntaxEditor(SyntaxNode, Workspace) |
Creates a new SyntaxEditor instance. |
Properties
Generator |
A SyntaxGenerator to use to create and change SyntaxNode's. |
OriginalRoot |
The SyntaxNode that was specified when the SyntaxEditor was constructed. |
Methods
GetChangedRoot() |
Returns the changed root node. |
InsertAfter(SyntaxNode, IEnumerable<SyntaxNode>) |
Insert the new nodes after the specified node already existing in the tree. |
InsertAfter(SyntaxNode, SyntaxNode) |
Insert the new node after the specified node already existing in the tree. |
InsertBefore(SyntaxNode, IEnumerable<SyntaxNode>) |
Insert the new nodes before the specified node already existing in the tree. |
InsertBefore(SyntaxNode, SyntaxNode) |
Insert the new node before the specified node already existing in the tree. |
RemoveNode(SyntaxNode) |
Remove the node from the tree. |
RemoveNode(SyntaxNode, SyntaxRemoveOptions) |
Remove the node from the tree. |
ReplaceNode(SyntaxNode, Func<SyntaxNode,SyntaxGenerator,SyntaxNode>) |
Replace the specified node with a node produced by the function. |
ReplaceNode(SyntaxNode, SyntaxNode) |
Replace the specified node with a different node. |
TrackNode(SyntaxNode) |
Makes sure the node is tracked, even if it is not changed. |