blob: 99d326735ab341ab663ed66abdae9d6031c93f3e (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
//
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License. See License.txt in the project root for license information.
//
using System.Collections.ObjectModel;
using Microsoft.VisualStudio.Text.Differencing;
namespace Microsoft.VisualStudio.Text.Utilities
{
/// <summary>
/// Represents the set of differences between two projection snapshots.
/// </summary>
public class ProjectionSpanDifference
{
/// <summary>
/// Initializes a new instance of <see cref="ProjectionSpanDifference"/>.
/// </summary>
/// <param name="differenceCollection">The collection of snapshot spans that include the differences.</param>
/// <param name="insertedSpans">A read-only collection of the inserted snapshot spans.</param>
/// <param name="deletedSpans">A read-only collection of the deleted snapshot spans.</param>
public ProjectionSpanDifference(IDifferenceCollection<SnapshotSpan> differenceCollection, ReadOnlyCollection<SnapshotSpan> insertedSpans, ReadOnlyCollection<SnapshotSpan> deletedSpans)
{
DifferenceCollection = differenceCollection;
InsertedSpans = insertedSpans;
DeletedSpans = deletedSpans;
}
/// <summary>
/// The collection of differences between the two snapshots.
/// </summary>
public IDifferenceCollection<SnapshotSpan> DifferenceCollection { get; private set; }
/// <summary>
/// The read-only collection of inserted snapshot spans.
/// </summary>
public ReadOnlyCollection<SnapshotSpan> InsertedSpans { get; private set; }
/// <summary>
/// The read-only collection of deleted snapshot spans.
/// </summary>
public ReadOnlyCollection<SnapshotSpan> DeletedSpans { get; private set; }
}
}
|