1 | import * as PP from "./preprocessor";
|
2 | import { ExecutionOptions } from "./interpreter";
|
3 | import * as LexerParser from "./LexerParser";
|
4 | import * as _lexer from "./lexer";
|
5 | export { _lexer as lexer };
|
6 | import * as BrsTypes from "./brsTypes";
|
7 | export { BrsTypes as types };
|
8 | export { PP as preprocessor };
|
9 | import * as _parser from "./parser";
|
10 | export { _parser as parser };
|
11 | /**
|
12 | * Executes a BrightScript file by path and writes its output to the streams
|
13 | * provided in `options`.
|
14 | *
|
15 | * @param filename the absolute path to the `.brs` file to be executed
|
16 | * @param options configuration for the execution, including the streams to use for `stdout` and
|
17 | * `stderr` and the base directory for path resolution
|
18 | *
|
19 | * @returns a `Promise` that will be resolve if `filename` is successfully
|
20 | * executed, or be rejected if an error occurs.
|
21 | */
|
22 | export declare function execute(filenames: string[], options: Partial<ExecutionOptions>): Promise<LexerParser.types.BrsType[]>;
|
23 | /**
|
24 | * A synchronous version of the lexer-parser flow.
|
25 | *
|
26 | * @param filename the paths to BrightScript files to lex and parse synchronously
|
27 | * @param options configuration for the execution, including the streams to use for `stdout` and
|
28 | * `stderr` and the base directory for path resolution
|
29 | *
|
30 | * @returns the AST produced from lexing and parsing the provided files
|
31 | */
|
32 | export declare function lexParseSync(filenames: string[], options: Partial<ExecutionOptions>): _parser.Stmt.Statement[];
|
33 | /**
|
34 | * Launches an interactive read-execute-print loop, which reads input from
|
35 | * `stdin` and executes it.
|
36 | *
|
37 | * **NOTE:** Currently limited to single-line inputs :(
|
38 | */
|
39 | export declare function repl(): void;
|