Create a repository list from the supplied raw value.

@param array|null $repositories The raw repository list data.

@return array<integer,RepositoryInterface>|null The newly created repository list.
979637
protected function createRepositories(array $repositories = null)
    {
        if (null !== $repositories) {
            foreach ($repositories as $index => $repository) {
                $repositories[$index] = $this->createRepository(
                    new ObjectAccess($repository)
                );
            }
        }

        return $repositories;
    }
776139
public static function makeResourceRepository(string $repository): Repository
    {
        $api = App::make(ApiClient::class);

        return new $repository($api);
    }
577795
@GET
    @Path("/repositorysummaries")
    public List<RepositorySummary> getRepositorySummaries() {
        List<RepositorySummary> result = new ArrayList<RepositorySummary>(repositories.size());
        for (String repositoryId : repositories.keySet()) {
            RepositorySummary repositorySummary = getScriptRepo(repositoryId).getRepositorySummary();
            result.add(repositorySummary);
        }
        return result;
    }
413420
public static function create($repo_path, $source = null)
    {
        try {
            $repo = new Repository($repo_path);
            $remote = $repo->getRemoteOriginUrl();
            if ($remote===$source || $remote.'.git'===$source || $remote===$source.'.git') {
                $branch = $repo->getCurrentBranch();
                $repo->pull($remote, $branch);
                return $repo;
            }
        } catch (\Exception $e) {
        }
        return Repository::createNew($repo_path, $source);
    }
946707
public void setRepositories(java.util.Collection<RepositoryNameIdPair> repositories) {
        if (repositories == null) {
            this.repositories = null;
            return;
        }

        this.repositories = new java.util.ArrayList<RepositoryNameIdPair>(repositories);
    }
168678
public function setRepositories($repositories)
    {
        if (!is_array($repositories) && (!is_object($repositories) || !$repositories instanceof \Traversable)) {
            throw new InvalidArgumentException(sprintf(
                'Invalid argument provided for $repositories, expecting either an array or Traversable object, but' .
                ' "%s" given',
                is_object($repositories) ? get_class($repositories) : gettype($repositories)
            ));
        }
        $this->stack = new \SplStack();
        $this->addRepositories($repositories);
    }
1139784
private function initializeRepositories(array $repositories): void
    {
        foreach ($repositories as $name => $data) {
            $this->repositories[$name] = new Repository($this, $name, $data);
        }
    }
89378
public static function getConfiguration(array $repositories)
	{
		$config = [[], [], []];
		foreach ($repositories as $name => $repository) {
			/** @var string $className */
			$className = is_object($repository) ? get_class($repository) : $repository;
			$config[0][$className] = true;
			$config[1][$name] = $className;
			foreach ($repository::getEntityClassNames() as $entityClassName) {
				$config[2][$entityClassName] = $className;
			}
		}
		return $config;
	}
55037
public function delete(Repository $repository = null)
    {
        if (!$repository) {
            $repository = $this->getRepository();
        }

        $repository = $repository->aliased('write');

        $delete = $this->getQuery()->transformToDelete();

        $prepare = $repository->prepareQuery($delete);

        return $repository->executePrepared($prepare);
    }
572472
public void setRepositoriesNotFound(java.util.Collection<String> repositoriesNotFound) {
        if (repositoriesNotFound == null) {
            this.repositoriesNotFound = null;
            return;
        }

        this.repositoriesNotFound = new java.util.ArrayList<String>(repositoriesNotFound);
    }
1087916
public function listRepositories($since = null)
	{
		$data = array();
		if(!is_null($since))
			$data['since'] = $since;
		
		return $this->client->request("/repositories", 'GET', $data, 200, 'GitHubSimpleRepo', true);
	}
128656
def grab_sub_repo(repositories, repos):
    
    for i, repo in enumerate(repositories):
        if repos in repo:
            sub = repositories[i].replace(repos, "")
            repositories[i] = repos
            return sub
    return ""
246691
public function repository($name = null)
    {
        $name = $name ?: $this->getDefaultDriver();

        return $this->repositories[$name] = $this->get($name);
    }
1282832
@Override
    public RestRepositories getRepositories(Request request) {
        RestRepositories repositories = new RestRepositories();
        for (String repositoryName : getRepositoryManager().getJcrRepositoryNames()) {
            addRepository(request, repositories, repositoryName);
        }
        return repositories;
    }
704157
public function repository_from_url(string $url, bool $obj = false){
    $repository = '';
    $repositories = $this->repositories();

    foreach ( $repositories as $i => $d ){
      if ( (strpos($url, $i) === 0) &&
        (\strlen($i) > \strlen($repository) )
      ){
        $repository = $i;
      }
    }
    if ( !empty($repository) ){
      return empty($obj) ? $repository : $repositories[$repository];
    }
    return false;
  }
118101
private function defineRepositories(array $objects, ContainerBuilder $container)
    {
        foreach ($objects as $object => $services) {
            if (array_key_exists('model', $services)) {
                $repositoryDefinition = $this->getRepositoryDefinition($object, $services, $container);

                $container->setDefinition(
                    $this->getContainerKey('repository', $object),
                    $repositoryDefinition
                )->setPublic(true);
            }
        }
    }
899418
public static function add_to_repo($repository_path, $files = null)
    {
        $repo = new pakeGit($repository_path);
        $repo->add($files);

        return $repo;
    }