TextFilePosition Class ​
Definition ​
A SourcePosition in a text source code file.
c#
public sealed class TextFilePosition : SourceFilePosition<TextFilePosition, TextFile>, IEquatable<SourcePosition>, IEqualityOperators<SourcePosition, SourcePosition, Boolean>, ITextSourcePositionProperties ​
| Name | Description |
|---|---|
StartColumnIndex | Zero based index of the start column of the position in the text file. |
StartColumnNumber | Number, that is, 1 based index, of the start column of the position in the text file. |
StartLine | The start line of the text source. |
StartLineIndex | Zero based index of the start line of the position in the text file. |
StartLineNumber | Number, that is, 1 based index, of the start line of the position in the text file. |
Text | The text source. |
Methods ​
| Name | Description |
|---|---|
CreateCombination(TextFilePosition) | Creates a combination of this SourceFilePosition<TSelf, TFile> and another. Used to create a combination for Combine(TSelf). |
CreateZeroWidthPrefix() | Create a new TextFilePosition with zero width at the start of this TextFilePosition. |
ToString() | Returns a string that represents the current object. |
WriteSourceForMessage(StringBuilder) | Writes the source for the purposes of displaying a Message. |
Operators ​
| Name | Description |
|---|---|
Addition(TextFilePosition, TextFilePosition) | Combines two TextFilePositions to give a new SourcePosition that includes both x and y along with any source in-between the two. |