12 instantiations of RazorTextChange
Microsoft.CodeAnalysis.Razor.Workspaces (12)
DocumentMapping\RazorEditService.cs (4)
147normalizedChanges.Add(new RazorTextChange() 245return new RazorTextChange() 270return new RazorTextChange() 334edits.Add(new RazorTextChange()
DocumentMapping\RazorEditService_Methods.cs (2)
69edits.Add(new RazorTextChange() 111edits.Add(new RazorTextChange()
DocumentMapping\RazorEditService_UsingDirectives.cs (4)
85edits.Add(new RazorTextChange() 170edits.Add(new RazorTextChange() 215edits.Add(new RazorTextChange() 232edits.Add(new RazorTextChange()
Extensions\LspExtensions_SourceText.cs (1)
49=> new()
Extensions\LspExtensions_TextChange.cs (1)
13return new RazorTextChange()
33 references to RazorTextChange
Microsoft.CodeAnalysis.Razor.Workspaces (31)
DocumentMapping\IRazorEditService.cs (2)
26Task<ImmutableArray<RazorTextChange>> MapCSharpEditsAsync( 27ImmutableArray<RazorTextChange> textChanges,
DocumentMapping\RazorEditService.cs (14)
36public async Task<ImmutableArray<RazorTextChange>> MapCSharpEditsAsync( 37ImmutableArray<RazorTextChange> textChanges, 45using var edits = new PooledArrayBuilder<RazorTextChange>(); 71ref PooledArrayBuilder<RazorTextChange> edits, 108private ImmutableArray<RazorTextChange> NormalizeEdits(ImmutableArray<RazorTextChange> changes, CancellationToken cancellationToken) 114using var normalizedChanges = new PooledArrayBuilder<RazorTextChange>(changes.Length); 220private RazorTextChange? TryGetMappedEdit( 222RazorTextChange change) 290ref PooledArrayBuilder<RazorTextChange> edits, 291ImmutableArray<RazorTextChange> csharpEdits, 294out ImmutableArray<RazorTextChange> skippedEdits) 298using var skipped = new PooledArrayBuilder<RazorTextChange>(); 300foreach (var csharpEdit in csharpEdits)
DocumentMapping\RazorEditService_Methods.cs (2)
25private static void AddMethodChanges(ref PooledArrayBuilder<RazorTextChange> edits, RazorCodeDocument codeDocument, ImmutableArray<CSharpMethod> addedMethods, RazorFormattingOptions options) 80private static void AddMethodsInNewCodeBlock(ref PooledArrayBuilder<RazorTextChange> edits, RazorCodeDocument codeDocument, ImmutableArray<CSharpMethod> methods, RazorFormattingOptions options)
DocumentMapping\RazorEditService_UsingDirectives.cs (6)
43ref PooledArrayBuilder<RazorTextChange> edits, 72ref PooledArrayBuilder<RazorTextChange> edits, 119void AddNewUsingsToBlock(ref PooledArrayBuilder<RazorTextChange> edits, ImmutableArray<RazorUsingDirectiveSyntax> existingUsings, ImmutableArray<string> addedUsings) 178private static void AddRemoveUsingsChanges(ref PooledArrayBuilder<RazorTextChange> edits, RazorCodeDocument codeDocument, ImmutableArray<string> removedUsings, CancellationToken cancellationToken) 196ref PooledArrayBuilder<RazorTextChange> edits, 228private static void AddRemoveEdit(ref PooledArrayBuilder<RazorTextChange> edits, RazorUsingDirectiveSyntax node, SourceText text)
Extensions\LspExtensions_SourceText.cs (2)
48public static RazorTextChange GetRazorTextChange(this SourceText text, TextEdit edit) 58public static TextEdit GetTextEdit(this SourceText text, RazorTextChange change)
Extensions\LspExtensions_TextChange.cs (1)
11public static RazorTextChange ToRazorTextChange(this TextChange textChange)
Extensions\RazorTextChangeExtensions.cs (1)
10public static TextChange ToTextChange(this RazorTextChange razorTextChange)
Protocol\DocumentMapping\RazorMapToDocumentEditsParams.cs (1)
18public required RazorTextChange[] TextChanges { get; init; }
Protocol\DocumentMapping\RazorMapToDocumentEditsResponse.cs (1)
11public required RazorTextChange[] TextChanges { get; init; }
Protocol\UpdateBufferRequest.cs (1)
24public required RazorTextChange[] Changes { get; set; }
Microsoft.VisualStudio.LanguageServices.Razor (1)
LanguageClient\Extensions\TextChangeExtensions.cs (1)
11public static ITextChange ToVisualStudioTextChange(this RazorTextChange razorTextChange)
Microsoft.VisualStudio.LanguageServices.Razor.UnitTests (1)
Cohost\Formatting\FormattingLogTest.cs (1)
85var htmlChanges = JsonSerializer.Deserialize<RazorTextChange[]>(htmlChangesFile, JsonHelpers.JsonSerializerOptions);