use of software.amazon.awssdk.services.codecommit.model.ListRepositoriesResponse in project aws-doc-sdk-examples by awsdocs.
the class ListRepositories method listRepos.
// snippet-start:[codecommit.java2.get_repos.main]
public static void listRepos(CodeCommitClient codeCommitClient) {
try {
ListRepositoriesResponse repResponse = codeCommitClient.listRepositories();
List<RepositoryNameIdPair> repoList = repResponse.repositories();
for (RepositoryNameIdPair repo : repoList) {
System.out.println("The repository name is " + repo.repositoryName());
}
} catch (CodeCommitException e) {
System.err.println(e.getMessage());
System.exit(1);
}
}
Aggregations