src/CodeGeneration/NamespaceHelper.php
public function getProjectNamespaceRootFromEntityFqn(string $entityFqn): string
    {
        return $this->tidy(
            \substr(
                $entityFqn,
                0,
                \strrpos(
                    $entityFqn,
                    '\\' . AbstractGenerator::ENTITIES_FOLDER_NAME . '\\'
                )
            )
        );
    }
public function getProjectNamespaceRootFromEntityFqn(string $entityFqn): string
    {
        return $this->tidy(
            \substr(
                $entityFqn,
                0,
                \strrpos(
                    $entityFqn,
                    '\\' . AbstractGenerator::ENTITIES_FOLDER_NAME . '\\'
                )
            )
        );
    }
public function getProjectNamespaceRootFromEntityFqn ( string $ entityFqn ) : string { return $ this -> tidy ( \ substr ( $ entityFqn , 0 , \ strrpos ( $ entityFqn , '\\' . AbstractGenerator :: ENTITIES_FOLDER_NAME . '\\' ) ) ) ; }
Use the fully qualified name of two Entities to calculate the Project Namespace Root

- note: this assumes a single namespace level for entities, eg `Entities`

@param string $entityFqn

@return string
Use the fully qualified name of two Entities to calculate the Project Namespace Root