UNPKG

antlr-ng

Version:

Next generation ANTLR Tool

19 lines (18 loc) 759 B
import { type Token } from "antlr4ng"; import { GrammarAST } from "./GrammarAST.js"; export declare abstract class GrammarASTWithOptions extends GrammarAST { readonly astType: string; private options; constructor(nodeOrToken: GrammarASTWithOptions | Token); constructor(type: number, t?: Token, text?: string); setOption(key: string, node: GrammarAST | null): void; getOptionString(key: string): string | undefined; /** * Gets AST node holding value for option key; ignores default options * and command-line forced options. */ getOptionAST(key: string): GrammarAST | undefined; getNumberOfOptions(): number; getOptions(): Map<string, GrammarAST | null>; abstract dupNode(): GrammarASTWithOptions; }