progress
This commit is contained in:
parent
16e76d6b31
commit
484dbfc9d9
529 changed files with 113694 additions and 0 deletions
31
AspClassic.Parser/InstanceExpression.cs
Normal file
31
AspClassic.Parser/InstanceExpression.cs
Normal file
|
@ -0,0 +1,31 @@
|
|||
using System;
|
||||
|
||||
namespace AspClassic.Parser;
|
||||
|
||||
/// <summary>
|
||||
/// A parse tree for Me, MyBase or MyClass.
|
||||
/// </summary>
|
||||
public sealed class InstanceExpression : Expression
|
||||
{
|
||||
private InstanceType _InstanceType;
|
||||
|
||||
/// <summary>
|
||||
/// The type of the instance expression.
|
||||
/// </summary>
|
||||
public InstanceType InstanceType => _InstanceType;
|
||||
|
||||
/// <summary>
|
||||
/// Constructs a new parse tree for My, MyBase or MyClass.
|
||||
/// </summary>
|
||||
/// <param name="instanceType">The type of the instance expression.</param>
|
||||
/// <param name="span">The location of the parse tree.</param>
|
||||
public InstanceExpression(InstanceType instanceType, Span span)
|
||||
: base(TreeType.InstanceExpression, span)
|
||||
{
|
||||
if (instanceType < InstanceType.Me || instanceType > InstanceType.MyBase)
|
||||
{
|
||||
throw new ArgumentOutOfRangeException("instanceType");
|
||||
}
|
||||
_InstanceType = instanceType;
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue