public function registerServerNamespace()
    {
        foreach ($this->customComponents as $ns => $componentDir) {
            if (is_int($ns)) {
                $ns = $componentDir;
                $componentDir = ComposerHelper::getDirByNamespace($ns);
                $ns = rtrim($ns, "\\");
                $componentDir = rtrim($componentDir, "/");
            }

            $this->componentNamespaces[] = $ns;
            $componentDir = alias($componentDir);

            foreach ($this->serverScan as $dir) {
                $scanDir = $componentDir . DS . $dir;
                if (!is_dir($scanDir)) {
                    continue;
                }

                $scanNs = $ns . "\\" . $dir;
                $this->scanNamespaces[$scanNs] = $scanDir;
            }
        }
    }
public function registerServerNamespace()
    {
        foreach ($this->customComponents as $ns => $componentDir) {
            if (is_int($ns)) {
                $ns = $componentDir;
                $componentDir = ComposerHelper::getDirByNamespace($ns);
                $ns = rtrim($ns, "\\");
                $componentDir = rtrim($componentDir, "/");
            }

            $this->componentNamespaces[] = $ns;
            $componentDir = alias($componentDir);

            foreach ($this->serverScan as $dir) {
                $scanDir = $componentDir . DS . $dir;
                if (!is_dir($scanDir)) {
                    continue;
                }

                $scanNs = $ns . "\\" . $dir;
                $this->scanNamespaces[$scanNs] = $scanDir;
            }
        }
    }
public function registerServerNamespace ( ) { foreach ( $ this -> customComponents as $ ns => $ componentDir ) { if ( is_int ( $ ns ) ) { $ ns = $ componentDir ; $ componentDir = ComposerHelper :: getDirByNamespace ( $ ns ) ; $ ns = rtrim ( $ ns , "\\" ) ; $ componentDir = rtrim ( $ componentDir , "/" ) ; } $ this -> componentNamespaces [ ] = $ ns ; $ componentDir = alias ( $ componentDir ) ; foreach ( $ this -> serverScan as $ dir ) { $ scanDir = $ componentDir . DS . $ dir ; if ( ! is_dir ( $ scanDir ) ) { continue ; } $ scanNs = $ ns . "\\" . $ dir ; $ this -> scanNamespaces [ $ scanNs ] = $ scanDir ; } } }
Register the server namespace
@author limx
Register the server namespace