library/Phalex/Loader/Autoloader.php
public function register()
    {
        $moduleHandler = $this->diFactory->get('moduleHandler');
        $autoloadConf  = $moduleHandler->getModulesAutoloadConfig();

        if (isset($autoloadConf['namespaces'])) {
            if (!ArrayUtils::isHashTable($autoloadConf['namespaces'])) {
                throw new Exception\RuntimeException('Config autoload for namespace is invalid');
            }
            $this->loader->registerNamespaces($autoloadConf['namespaces']);
        }

        if (isset($autoloadConf['classmap'])) {
            $this->registerClassMap($autoloadConf['classmap']);
        }
        $this->loader->register();
        return $this;
    }
public function register()
    {
        $moduleHandler = $this->diFactory->get('moduleHandler');
        $autoloadConf  = $moduleHandler->getModulesAutoloadConfig();

        if (isset($autoloadConf['namespaces'])) {
            if (!ArrayUtils::isHashTable($autoloadConf['namespaces'])) {
                throw new Exception\RuntimeException('Config autoload for namespace is invalid');
            }
            $this->loader->registerNamespaces($autoloadConf['namespaces']);
        }

        if (isset($autoloadConf['classmap'])) {
            $this->registerClassMap($autoloadConf['classmap']);
        }
        $this->loader->register();
        return $this;
    }
public function register ( ) { $ moduleHandler = $ this -> diFactory -> get ( 'moduleHandler' ) ; $ autoloadConf = $ moduleHandler -> getModulesAutoloadConfig ( ) ; if ( isset ( $ autoloadConf [ 'namespaces' ] ) ) { if ( ! ArrayUtils :: isHashTable ( $ autoloadConf [ 'namespaces' ] ) ) { throw new Exception \ RuntimeException ( 'Config autoload for namespace is invalid' ) ; } $ this -> loader -> registerNamespaces ( $ autoloadConf [ 'namespaces' ] ) ; } if ( isset ( $ autoloadConf [ 'classmap' ] ) ) { $ this -> registerClassMap ( $ autoloadConf [ 'classmap' ] ) ; } $ this -> loader -> register ( ) ; return $ this ; }
Auto register namespace and class map
@throws Exception\RuntimeException
@todo Should cache register classmap
Auto register namespace and class map