IProjectionSnapshot.MapToSourceSnapshots Method (Span)
Maps a span of the current projection snapshot to a list of snapshot spans belonging to source snapshots. The resulting spans will be ordered by the order of their appearance in the projection.
Namespace: Microsoft.VisualStudio.Text.Projection
Assembly: Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)
Syntax
'Declaration
Function MapToSourceSnapshots ( _
span As Span _
) As ReadOnlyCollection(Of SnapshotSpan)
ReadOnlyCollection<SnapshotSpan> MapToSourceSnapshots(
Span span
)
ReadOnlyCollection<SnapshotSpan>^ MapToSourceSnapshots(
Span span
)
abstract MapToSourceSnapshots :
span:Span -> ReadOnlyCollection<SnapshotSpan>
function MapToSourceSnapshots(
span : Span
) : ReadOnlyCollection<SnapshotSpan>
Parameters
- span
Type: Microsoft.VisualStudio.Text.Span
The span in the projection snapshot.
Return Value
Type: System.Collections.ObjectModel.ReadOnlyCollection<SnapshotSpan>
A non-empty list of snapshot spans.
Exceptions
Exception | Condition |
---|---|
ArgumentOutOfRangeException | span is not valid for this buffer. |
Remarks
If a nulla null reference (Nothing in Visual Basic) span occurs on a source span seam, it may map to more than one nulla null reference (Nothing in Visual Basic) source span.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.