using System; using System.Collections.Generic; namespace AspClassic.Parser; /// /// A parse tree for an Implements declaration. /// public sealed class ImplementsDeclaration : Declaration { private readonly TypeNameCollection _ImplementedTypes; /// /// The list of types. /// public TypeNameCollection ImplementedTypes => _ImplementedTypes; /// /// Constructs a parse tree for an Implements declaration. /// /// The types inherited or implemented. /// The location of the parse tree. /// The comments for the parse tree. public ImplementsDeclaration(TypeNameCollection implementedTypes, Span span, IList comments) : base(TreeType.ImplementsDeclaration, span, comments) { if (implementedTypes == null) { throw new ArgumentNullException("implementedTypes"); } SetParent(implementedTypes); _ImplementedTypes = implementedTypes; } protected override void GetChildTrees(IList childList) { base.GetChildTrees(childList); Tree.AddChild(childList, ImplementedTypes); } }