UNPKG

1.18 kBJavaScriptView Raw
1/// <reference path="../typings/tsd.d.ts" />
2var DInit = require('./Init');
3var DFiles = require('./config/Files');
4var Dollyjs;
5(function (Dollyjs) {
6 /**
7 * @class Dolly
8 * Base framework class
9 */
10 var Dolly = (function () {
11 /**
12 * @constructs Dolly
13 */
14 function Dolly() {
15 }
16 /**
17 * Init dolly application
18 * @param basePath {string}
19 * @param dollyConfPath {string}
20 * @param dollyPref {object}
21 * @static
22 */
23 Dolly.init = function (basePath, dollyConfPath, dollyPref) {
24 DFiles.Files.rootPath = basePath;
25 DFiles.Files.dollyConfPath = dollyConfPath;
26 DInit.Init.initDolly(dollyPref);
27 Dolly.server = DInit.Init.server;
28 Dolly.io = DInit.Init.io;
29 if (dollyPref.enableIO) {
30 var io = require((DFiles.Files.pathFiles()).configFolder + '/IO');
31 new io();
32 }
33 return DInit.Init.APP;
34 };
35 return Dolly;
36 })();
37 Dollyjs.Dolly = Dolly;
38})(Dollyjs || (Dollyjs = {}));
39module.exports = Dollyjs;
40//# sourceMappingURL=Dolly.js.map
\No newline at end of file