src/Package/Finder.php
private function scanNamespaceForPackages(NamespaceInterface $root, PackageInterface $parent = null): Generator
    {
        foreach ($root->iterateNamespaces() as $namespace) {
            yield from $this->loadPackage($namespace, $parent);
        }
    }
private function scanNamespaceForPackages(NamespaceInterface $root, PackageInterface $parent = null): Generator
    {
        foreach ($root->iterateNamespaces() as $namespace) {
            yield from $this->loadPackage($namespace, $parent);
        }
    }
private function scanNamespaceForPackages ( NamespaceInterface $ root , PackageInterface $ parent = null ) : Generator { foreach ( $ root -> iterateNamespaces ( ) as $ namespace ) { yield from $ this -> loadPackage ( $ namespace , $ parent ) ; } }
Finds all packages in a namespace.

@param NamespaceInterface    $root   The namespace to search.
@param PackageInterface|null $parent The parent package currently being searched, or null if none.

@return Generator|PackageInterface[]
Finds all packages in a namespace .