ModifierList.Insert Method
Containing Type: ModifierList
Assembly: Roslynator.CSharp.dll
Overloads
Method | Summary |
---|---|
Insert(SyntaxTokenList, SyntaxKind, IComparer<SyntaxKind>) | Creates a new list of modifiers with the modifier of the specified kind inserted. |
Insert(SyntaxTokenList, SyntaxToken, IComparer<SyntaxToken>) | Creates a new list of modifiers with a specified modifier inserted. |
Insert<TNode>(TNode, SyntaxKind, IComparer<SyntaxKind>) | Creates a new node with a modifier of the specified kind inserted. |
Insert<TNode>(TNode, SyntaxToken, IComparer<SyntaxToken>) | Creates a new node with the specified modifier inserted. |
Insert(SyntaxTokenList, SyntaxKind, IComparer<SyntaxKind>)
Creates a new list of modifiers with the modifier of the specified kind inserted.
public static Microsoft.CodeAnalysis.SyntaxTokenList Insert(Microsoft.CodeAnalysis.SyntaxTokenList modifiers, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind, System.Collections.Generic.IComparer<Microsoft.CodeAnalysis.CSharp.SyntaxKind>? comparer = null)
Parameters
modifiers SyntaxTokenList
kind SyntaxKind
comparer IComparer<SyntaxKind>
Returns
Insert(SyntaxTokenList, SyntaxToken, IComparer<SyntaxToken>)
Creates a new list of modifiers with a specified modifier inserted.
public static Microsoft.CodeAnalysis.SyntaxTokenList Insert(Microsoft.CodeAnalysis.SyntaxTokenList modifiers, Microsoft.CodeAnalysis.SyntaxToken modifier, System.Collections.Generic.IComparer<Microsoft.CodeAnalysis.SyntaxToken>? comparer = null)
Parameters
modifiers SyntaxTokenList
modifier SyntaxToken
comparer IComparer<SyntaxToken>
Returns
Insert<TNode>(TNode, SyntaxKind, IComparer<SyntaxKind>)
Creates a new node with a modifier of the specified kind inserted.
public static TNode Insert<TNode>(TNode node, Microsoft.CodeAnalysis.CSharp.SyntaxKind kind, System.Collections.Generic.IComparer<Microsoft.CodeAnalysis.CSharp.SyntaxKind>? comparer = null) where TNode : Microsoft.CodeAnalysis.SyntaxNode
Type Parameters
TNode
Parameters
node TNode
kind SyntaxKind
comparer IComparer<SyntaxKind>
Returns
TNode
Insert<TNode>(TNode, SyntaxToken, IComparer<SyntaxToken>)
Creates a new node with the specified modifier inserted.
public static TNode Insert<TNode>(TNode node, Microsoft.CodeAnalysis.SyntaxToken modifier, System.Collections.Generic.IComparer<Microsoft.CodeAnalysis.SyntaxToken>? comparer = null) where TNode : Microsoft.CodeAnalysis.SyntaxNode
Type Parameters
TNode
Parameters
node TNode
modifier SyntaxToken
comparer IComparer<SyntaxToken>
Returns
TNode