/** * Typed AST wrappers over the SceneGraph XML CST — mirrors `../ast.ts`'s * role for the BrightScript CST: a convenient, type-safe API over the raw * `XmlSyntaxNode` children array. `.syntax` always gives access to the raw * CST when the typed API isn't enough. */ import { XmlSyntaxNode } from './xmlSyntaxNode.js'; import { XmlToken } from './xmlToken.js'; export declare class XmlDocument { readonly syntax: XmlSyntaxNode; constructor(syntax: XmlSyntaxNode); get root(): XmlElement | undefined; getText(): string; } /** Parses `xmlText` and returns its typed root element, or `undefined` if it has none. */ export declare function parseSceneGraphXml(xmlText: string): XmlElement | undefined; export declare class XmlElement { readonly syntax: XmlSyntaxNode; constructor(syntax: XmlSyntaxNode); get tagNameToken(): XmlToken | undefined; get tagName(): string; get selfClosing(): boolean; get attributes(): XmlAttribute[]; /** Case-insensitive attribute lookup by name. */ getAttribute(name: string): XmlAttribute | undefined; /** Direct child elements only (not text/comments, not deeper descendants). */ get children(): XmlElement[]; /** The first direct child element with the given tag name (case-insensitive), if any. */ findChildByTagName(tagName: string): XmlElement | undefined; /** All direct child elements with the given tag name (case-insensitive). */ findAllChildrenByTagName(tagName: string): XmlElement[]; /** * This element and every descendant (depth-first, self first), optionally * filtered by `predicate`. Self-inclusive to match the old regex-based * queries this replaces, which scanned the whole document text without * regard for how deep a `