Replies: 1 comment 5 replies
-
class Application extends events.EventEmitter {
constructor() {
super();
this.initialization = true;
this.finalization = false;
this.root = process.cwd();
this.path = path.join(this.root, 'application');
this.schemas = new Schemas('schemas', this);
this.static = new Resources('static', this);
this.resources = new Resources('resources', this);
this.api = new Interfaces('api', this);
this.lib = new Modules('lib', this);
this.domain = new Modules('domain', this);
new Modules('domain', this);
this.starts = [];
this.Application = Application;
this.Error = Error;
this.cert = null;
this.config = null;
this.logger = null;
this.console = null;
this.auth = null;
this.watcher = null;
}
... |
Beta Was this translation helpful? Give feedback.
5 replies
Answer selected by
MrWaip
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Я пытался понять, кем заполняется массив
starts
вApplication
и у меня есть два вопроса.В конструкторе Application есть ошибка,
new Modules('domain', this);
создается повторно, никуда не сохраняется и не используется.application.js - строка 35 и 37
Как-то очень непонятно получается, что Modules заполняет массивы starts класса Application. Как будто нарушен принцип "Information Expert".
modules.js
Beta Was this translation helpful? Give feedback.
All reactions