UNPKG

1.12 kBJavaScriptView Raw
1import { TextRange } from './TextRange';
2import { DocComment } from '../nodes';
3import { ParserMessageLog } from './ParserMessageLog';
4/**
5 * An internal data structure that tracks all the state being built up by the various
6 * parser stages.
7 */
8var ParserContext = /** @class */ (function () {
9 function ParserContext(configuration, sourceRange) {
10 /**
11 * The text range starting from the opening `/**` and ending with
12 * the closing `*\/` delimiter.
13 */
14 this.commentRange = TextRange.empty;
15 /**
16 * The text ranges corresponding to the lines of content inside the comment.
17 */
18 this.lines = [];
19 /**
20 * A complete list of all tokens that were extracted from the input lines.
21 */
22 this.tokens = [];
23 this.configuration = configuration;
24 this.sourceRange = sourceRange;
25 this.docComment = new DocComment({ configuration: this.configuration });
26 this.log = new ParserMessageLog();
27 }
28 return ParserContext;
29}());
30export { ParserContext };
31//# sourceMappingURL=ParserContext.js.map
\No newline at end of file