public function getMainPrefixAndPath(Dir $rootDir) {
    $prefixesPaths = $this->getPrefixes();
    $prefixes = array_keys($prefixesPaths);
    
    if (count($prefixes) > 0) {
      $firstPrefixPaths = array_shift($prefixesPaths);

      $path = array_shift($firstPrefixPaths);
      $dir = $path instanceof Dir ? $path : $rootDir->sub($path);
    
      return array(array_shift($prefixes), $dir);
    }
    
    throw new NoAutoLoadPrefixException('Cannot retrieve the main Prefix and Library Path from AutoLoadInfo. AutoLoadInfo is defined: '.print_r($prefixesPaths, true)."\nPlease insert autoload informations into your composer.json");
  }
public function getMainPrefixAndPath(Dir $rootDir) {
    $prefixesPaths = $this->getPrefixes();
    $prefixes = array_keys($prefixesPaths);
    
    if (count($prefixes) > 0) {
      $firstPrefixPaths = array_shift($prefixesPaths);

      $path = array_shift($firstPrefixPaths);
      $dir = $path instanceof Dir ? $path : $rootDir->sub($path);
    
      return array(array_shift($prefixes), $dir);
    }
    
    throw new NoAutoLoadPrefixException('Cannot retrieve the main Prefix and Library Path from AutoLoadInfo. AutoLoadInfo is defined: '.print_r($prefixesPaths, true)."\nPlease insert autoload informations into your composer.json");
  }
public function getMainPrefixAndPath ( Dir $ rootDir ) { $ prefixesPaths = $ this -> getPrefixes ( ) ; $ prefixes = array_keys ( $ prefixesPaths ) ; if ( count ( $ prefixes ) > 0 ) { $ firstPrefixPaths = array_shift ( $ prefixesPaths ) ; $ path = array_shift ( $ firstPrefixPaths ) ; $ dir = $ path instanceof Dir ? $ path : $ rootDir -> sub ( $ path ) ; return array ( array_shift ( $ prefixes ) , $ dir ) ; } throw new NoAutoLoadPrefixException ( 'Cannot retrieve the main Prefix and Library Path from AutoLoadInfo. AutoLoadInfo is defined: ' . print_r ( $ prefixesPaths , true ) . "\nPlease insert autoload informations into your composer.json" ) ; }
Returns the first to find prefix and path in autoloadInfo

normally this is the package main Prefix and the main package-library-path
@return list(string $prefix, $dir)
@throws NoAutoLoadPrefixException if autoload info is not defined
Returns the first to find prefix and path in autoloadInfo