Struct SourceLocation
A SourceRange within a specific workspace document.
public readonly record struct SourceLocation : IComparable<SourceLocation>, IEquatable<SourceLocation>
- Implements
- Inherited Members
Constructors
SourceLocation(Uri, SourceRange)
A SourceRange within a specific workspace document.
public SourceLocation(Uri Uri, SourceRange Range)
Parameters
UriUriThe
Uriof the source document.RangeSourceRangeThe range within the source document.
Properties
Range
The range within the source document.
public SourceRange Range { get; init; }
Property Value
Uri
The Uri of the source document.
public Uri Uri { get; init; }
Property Value
Methods
CompareTo(SourceLocation)
Compares two locations by where their ranges start, in document order; the documents are not compared.
public int CompareTo(SourceLocation other)
Parameters
otherSourceLocationThe location to compare with.
Returns
- int
Less than zero when this location starts before
other, zero when they start at the same position, greater than zero when it starts after.