import type { SGContext, SGNode } from './node.js'; export type BackEdge = { parent: SGNode; child: SGNode; }; export declare class Supergroup { roots: SGNode[]; root?: SGNode; nodes: SGNode[]; backedges: BackEdge[]; ctx: SGContext; constructor(roots: SGNode[], opts: { root?: SGNode; backedges?: BackEdge[]; ctx: SGContext; }); /** iterative DFS pre-order; each node once, even multi-parent nodes */ private computeNodes; flatten(): SGNode[]; node(path: string | unknown[]): SGNode | undefined; select(arg: ((n: SGNode) => boolean) | unknown[]): SGNode[]; /** refresh the DFS node index after post-construction structural edits */ reindex(): void; }