UNPKG

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