Class TextDiffLine
- Namespace
- NuvTools.AspNetCore.Blazor.Components
- Assembly
- NuvTools.AspNetCore.Blazor.dll
One side of a TextDiffRow: a line of the old or the new text.
public sealed record TextDiffLine : IEquatable<TextDiffLine>
- Inheritance
-
TextDiffLine
- Implements
- Inherited Members
Constructors
TextDiffLine(int, string, int, int)
One side of a TextDiffRow: a line of the old or the new text.
public TextDiffLine(int Number, string Text, int ChangeStart = 0, int ChangeLength = 0)
Parameters
NumberintLine number in its own text, starting at 1.
TextstringThe line, without its line break.
ChangeStartintWhere the changed part starts, for a modified line; 0 otherwise.
ChangeLengthintLength of the changed part, for a modified line; 0 otherwise.
Properties
After
The text after the changed part.
public string After { get; }
Property Value
Before
The text before the changed part (the whole line when nothing inside it changed).
public string Before { get; }
Property Value
ChangeLength
Length of the changed part, for a modified line; 0 otherwise.
public int ChangeLength { get; init; }
Property Value
ChangeStart
Where the changed part starts, for a modified line; 0 otherwise.
public int ChangeStart { get; init; }
Property Value
Changed
The changed part of a modified line.
public string Changed { get; }
Property Value
Number
Line number in its own text, starting at 1.
public int Number { get; init; }
Property Value
Text
The line, without its line break.
public string Text { get; init; }