progress
This commit is contained in:
parent
16e76d6b31
commit
484dbfc9d9
529 changed files with 113694 additions and 0 deletions
57
AspClassic.Parser/GetAccessorDeclaration.cs
Normal file
57
AspClassic.Parser/GetAccessorDeclaration.cs
Normal file
|
@ -0,0 +1,57 @@
|
|||
using System.Collections.Generic;
|
||||
|
||||
namespace AspClassic.Parser;
|
||||
|
||||
/// <summary>
|
||||
/// A parse tree for a Get property accessor.
|
||||
/// </summary>
|
||||
public sealed class GetAccessorDeclaration : ModifiedDeclaration
|
||||
{
|
||||
private readonly Location _GetLocation;
|
||||
|
||||
private readonly StatementCollection _Statements;
|
||||
|
||||
private readonly EndBlockDeclaration _EndDeclaration;
|
||||
|
||||
/// <summary>
|
||||
/// The location of the 'Get'.
|
||||
/// </summary>
|
||||
public Location GetLocation => _GetLocation;
|
||||
|
||||
/// <summary>
|
||||
/// The statements in the accessor.
|
||||
/// </summary>
|
||||
public StatementCollection Statements => _Statements;
|
||||
|
||||
/// <summary>
|
||||
/// The End declaration for the accessor.
|
||||
/// </summary>
|
||||
public EndBlockDeclaration EndDeclaration => _EndDeclaration;
|
||||
|
||||
/// <summary>
|
||||
/// Constructs a new parse tree for a Get property accessor.
|
||||
/// </summary>
|
||||
/// <param name="attributes">The attributes for the parse tree.</param>
|
||||
/// <param name="modifiers">The modifiers for the parse tree.</param>
|
||||
/// <param name="getLocation">The location of the 'Get'.</param>
|
||||
/// <param name="statements">The statements in the declaration.</param>
|
||||
/// <param name="endDeclaration">The end block declaration, if any.</param>
|
||||
/// <param name="span">The location of the parse tree.</param>
|
||||
/// <param name="comments">The comments for the parse tree.</param>
|
||||
public GetAccessorDeclaration(AttributeBlockCollection attributes, ModifierCollection modifiers, Location getLocation, StatementCollection statements, EndBlockDeclaration endDeclaration, Span span, IList<Comment> comments)
|
||||
: base(TreeType.GetAccessorDeclaration, attributes, modifiers, span, comments)
|
||||
{
|
||||
SetParent(statements);
|
||||
SetParent(endDeclaration);
|
||||
_GetLocation = getLocation;
|
||||
_Statements = statements;
|
||||
_EndDeclaration = endDeclaration;
|
||||
}
|
||||
|
||||
protected override void GetChildTrees(IList<Tree> childList)
|
||||
{
|
||||
base.GetChildTrees(childList);
|
||||
Tree.AddChild(childList, Statements);
|
||||
Tree.AddChild(childList, EndDeclaration);
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue