aspclassic-core/AspClassic.Parser/SourceRegion.cs
Jelle Luteijn 484dbfc9d9 progress
2022-05-15 11:19:49 +02:00

41 lines
990 B
C#

namespace AspClassic.Parser;
/// <summary>
/// A region marked in the source code.
/// </summary>
public sealed class SourceRegion
{
private readonly Location _Start;
private readonly Location _Finish;
private readonly string _Description;
/// <summary>
/// The start location of the region.
/// </summary>
public Location Start => _Start;
/// <summary>
/// The end location of the region.
/// </summary>
public Location Finish => _Finish;
/// <summary>
/// The description of the region.
/// </summary>
public string Description => _Description;
/// <summary>
/// Constructs a new source region.
/// </summary>
/// <param name="start">The start location of the region.</param>
/// <param name="finish">The end location of the region.</param>
/// <param name="description">The description of the region.</param>
public SourceRegion(Location start, Location finish, string description)
{
_Start = start;
_Finish = finish;
_Description = description;
}
}