/
index-lazy.js
61 lines (58 loc) · 2.28 KB
/
index-lazy.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
"use strict";
var __importDefault = (this && this.__importDefault) || function (mod) {
return (mod && mod.__esModule) ? mod : { "default": mod };
};
exports.__esModule = true;
var main_1 = __importDefault(require("./main"));
var lazy_resolver_1 = __importDefault(require("./main/lazy-resolver"));
/**
* Exactly the same interface as @index.js - the only difference is that the
* functions only load dependencies at the moment they need them.
*/
module.exports = {
/**
* See the function of the same name in @index.js.
*/
renderMsc: function (pScript, pOptions, pCallBack) {
main_1["default"].renderMsc(pScript, pOptions || {}, pCallBack, lazy_resolver_1["default"].getParser, lazy_resolver_1["default"].getGraphicsRenderer);
},
/**
* See the function of the same name in @index.js.
*/
translateMsc: function (pScript, pOptions) {
return main_1["default"].translateMsc(pScript, pOptions || {}, lazy_resolver_1["default"].getParser, lazy_resolver_1["default"].getTextRenderer);
},
/**
* See the variable of the same name in @index.js.
*/
version: main_1["default"].version,
/**
* See the variable of the same name in @index.js.
*/
getAllowedValues: main_1["default"].getAllowedValues,
/**
* See the function of the same name in @index.js
*/
getParser: lazy_resolver_1["default"].getParser,
/**
* See the function of the same name in @index.js
*/
getGraphicsRenderer: lazy_resolver_1["default"].getGraphicsRenderer,
/**
* See the function of the same name in @index.js
*/
getTextRenderer: lazy_resolver_1["default"].getTextRenderer
};
/*
This file is part of mscgen_js.
mscgen_js is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation, either version 3 of the License, or
(at your option) any later version.
mscgen_js is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with mscgen_js. If not, see <http://www.gnu.org/licenses/>.
*/