Exemple #1
0
 /// <summary>
 /// Creates a new tree of nodes with the specified nodes, tokens or trivia replaced.
 /// </summary>
 protected internal virtual SyntaxNode ReplaceCore <TNode>(
     IEnumerable <TNode> nodes = null,
     Func <TNode, TNode, SyntaxNode> computeReplacementNode = null,
     IEnumerable <SyntaxToken> tokens = null,
     Func <SyntaxToken, SyntaxToken, SyntaxToken> computeReplacementToken = null,
     IEnumerable <SyntaxTrivia> trivia = null,
     Func <SyntaxTrivia, SyntaxTrivia, SyntaxTrivia> computeReplacementTrivia = null) where TNode : SyntaxNode
 {
     return(SyntaxReplacer.Replace(this, nodes, computeReplacementNode, tokens, computeReplacementToken, trivia, computeReplacementTrivia));
 }
Exemple #2
0
 protected internal virtual SyntaxNode InsertTokensInListCore(SyntaxToken originalToken, IEnumerable <SyntaxToken> newTokens, bool insertBefore)
 {
     return(SyntaxReplacer.InsertTokenInList(this, originalToken, newTokens, insertBefore));
 }
Exemple #3
0
 protected internal virtual SyntaxNode ReplaceTokenInListCore(SyntaxToken originalToken, IEnumerable <SyntaxToken> newTokens)
 {
     return(SyntaxReplacer.ReplaceTokenInList(this, originalToken, newTokens));
 }
Exemple #4
0
 protected internal virtual SyntaxNode InsertNodesInListCore(SyntaxNode nodeInList, IEnumerable <SyntaxNode> nodesToInsert, bool insertBefore)
 {
     return(SyntaxReplacer.InsertNodeInList(this, nodeInList, nodesToInsert, insertBefore));
 }
Exemple #5
0
 protected internal virtual SyntaxNode ReplaceNodeInListCore(SyntaxNode originalNode, IEnumerable <SyntaxNode> replacementNodes)
 {
     return(SyntaxReplacer.ReplaceNodeInList(this, originalNode, replacementNodes));
 }