protected function processAccessInformation(Project &$project)
    {
        $matches = array();
        $reference = $project->getReference();

        if ($project->getType() == 'gitlab') {
            $info = array();

            if (preg_match('`^(.+)@(.+):([0-9]*)\/?(.+)\.git`', $reference, $matches)) {
                $info['user'] = $matches[1];
                $info['domain'] = $matches[2];
                $info['port'] = $matches[3];

                $project->setReference($matches[4]);
            }

            $project->setAccessInformation($info);
        }
    }
protected function processAccessInformation(Project &$project)
    {
        $matches = array();
        $reference = $project->getReference();

        if ($project->getType() == 'gitlab') {
            $info = array();

            if (preg_match('`^(.+)@(.+):([0-9]*)\/?(.+)\.git`', $reference, $matches)) {
                $info['user'] = $matches[1];
                $info['domain'] = $matches[2];
                $info['port'] = $matches[3];

                $project->setReference($matches[4]);
            }

            $project->setAccessInformation($info);
        }
    }
protected function processAccessInformation ( Project & $ project ) { $ matches = array ( ) ; $ reference = $ project -> getReference ( ) ; if ( $ project -> getType ( ) == 'gitlab' ) { $ info = array ( ) ; if ( preg_match ( '`^(.+)@(.+):([0-9]*)\/?(.+)\.git`' , $ reference , $ matches ) ) { $ info [ 'user' ] = $ matches [ 1 ] ; $ info [ 'domain' ] = $ matches [ 2 ] ; $ info [ 'port' ] = $ matches [ 3 ] ; $ project -> setReference ( $ matches [ 4 ] ) ; } $ project -> setAccessInformation ( $ info ) ; } }
In circumstances where it is necessary, populate access information based on other project properties.
@see ProjectService::createProject()
@param Project $project
In circumstances where it is necessary populate access information based on other project properties .