/** * @return array */ function build() { $config = []; foreach ($this->fileSystem->glob($this->mask) as $filePath) { $config = array_merge($config, Yaml::parse($this->fileSystem->getFileContent($filePath))); } return $config; }
/** * Loads all modules contained in app and builds them. * * @return void */ protected function loadModules() { $moduleMask = implode(DIRECTORY_SEPARATOR, array($this->appPath->root(), 'src', $this->contextName . 'Module.php')); foreach ($this->fileSystem->glob($moduleMask) as $filePath) { $class = $this->loadModule($filePath); $class->build($this->containerBuilder); } }
/** * @return array */ function build() { $config = []; foreach ($this->fileSystem->glob($this->mask) as $filePath) { $config = array_merge($config, $this->fileSystem->includeFile($filePath)); } return $config; }
/** * @return array */ function build() { $config = []; foreach ($this->fileSystem->glob($this->mask) as $filePath) { $json_decoded_array = json_decode($this->fileSystem->getFileContent($filePath), true); $config = array_merge($config, $json_decoded_array); } return $config; }
protected function loadModules() { $moduleMask = implode(DIRECTORY_SEPARATOR, array($this->appPath->root(), "src", $this->contextName . "Module.php")); foreach ($this->fileSystem->glob($moduleMask) as $filePath) { /** @var IModule $class */ $class = $this->fileSystem->loadClass($filePath); $class->build($this->containerBuilder); } }