SnapshotSpan::Intersection Method (SnapshotSpan)
Visual Studio 2015
Calculates the intersection with the given SnapshotSpan.
Assembly: Microsoft.VisualStudio.Text.Data (in Microsoft.VisualStudio.Text.Data.dll)
Parameters
- snapshotSpan
-
Type:
Microsoft.VisualStudio.Text::SnapshotSpan
The span to check.
Return Value
Type: System::Nullable<SnapshotSpan>The intersection of the spans, or null if they do not intersect.
| Exception | Condition |
|---|---|
| ArgumentException | snapshotSpan does not refer to the same snapshot. |
Two spans intersect if they have positions in common, or if the end of one span coincides with the start of the other span, and neither is empty.
Show: