Skip to main content

WorkspaceExtensions Class

Namespace: Roslynator.CSharp

Assembly: Roslynator.CSharp.Workspaces.dll

A set of extension methods for the workspace layer.

public static class WorkspaceExtensions

Methods

MethodSummary
RemoveCommentsAsync(Document, CommentFilter, CancellationToken)Creates a new document with comments of the specified kind removed.
RemoveCommentsAsync(Document, TextSpan, CommentFilter, CancellationToken)Creates a new document with comments of the specified kind removed.
RemovePreprocessorDirectivesAsync(Document, PreprocessorDirectiveFilter, CancellationToken)Creates a new document with preprocessor directives of the specified kind removed.
RemovePreprocessorDirectivesAsync(Document, TextSpan, PreprocessorDirectiveFilter, CancellationToken)Creates a new document with preprocessor directives of the specified kind removed.
RemoveRegionAsync(Document, RegionInfo, CancellationToken)Creates a new document with the specified region removed.
RemoveTriviaAsync(Document, TextSpan, CancellationToken)Creates a new document with trivia inside the specified span removed.
ReplaceMembersAsync(Document, MemberDeclarationListInfo, IEnumerable<MemberDeclarationSyntax>, CancellationToken)Creates a new document with the specified members replaced with new members.
ReplaceMembersAsync(Document, MemberDeclarationListInfo, SyntaxList<MemberDeclarationSyntax>, CancellationToken)Creates a new document with the specified members replaced with new members.
ReplaceModifiersAsync(Document, ModifierListInfo, IEnumerable<SyntaxToken>, CancellationToken)Creates a new document with the specified modifiers replaced with new modifiers.
ReplaceModifiersAsync(Document, ModifierListInfo, SyntaxTokenList, CancellationToken)Creates a new document with the specified modifiers replaced with new modifiers.
ReplaceStatementsAsync(Document, StatementListInfo, IEnumerable<StatementSyntax>, CancellationToken)Creates a new document with the specified statements replaced with new statements.
ReplaceStatementsAsync(Document, StatementListInfo, SyntaxList<StatementSyntax>, CancellationToken)Creates a new document with the specified statements replaced with new statements.