src/Modules/ModuleManager.php
protected function populateModuleCollection()
    {
        $this->modules = new Collection;

        foreach ($this->moduleClasses as $moduleClass) {

            $instance = $this->instantiateClass($moduleClass);

            if ($instance instanceof ModuleGeneratorInterface) {
                $this->storeModulesForGenerator($instance);
                continue;
            }

            // instance is a module
            $this->storeModule($instance);
        }

        return $this;
    }
protected function populateModuleCollection()
    {
        $this->modules = new Collection;

        foreach ($this->moduleClasses as $moduleClass) {

            $instance = $this->instantiateClass($moduleClass);

            if ($instance instanceof ModuleGeneratorInterface) {
                $this->storeModulesForGenerator($instance);
                continue;
            }

            // instance is a module
            $this->storeModule($instance);
        }

        return $this;
    }
protected function populateModuleCollection ( ) { $ this -> modules = new Collection ; foreach ( $ this -> moduleClasses as $ moduleClass ) { $ instance = $ this -> instantiateClass ( $ moduleClass ) ; if ( $ instance instanceof ModuleGeneratorInterface ) { $ this -> storeModulesForGenerator ( $ instance ) ; continue ; } // instance is a module $ this -> storeModule ( $ instance ) ; } return $ this ; }
Creates module instances for each registered class name
and stores them in the module collection.

@return $this
Creates module instances for each registered class name and stores them in the module collection .