Class GitHubAccessorWithBasicAuth
java.lang.Object
com.atlassian.bamboo.plugins.github.accessor.GitHubAccessor
com.atlassian.bamboo.plugins.github.accessor.GitHubAccessorWithBasicAuth
-
Nested Class Summary
Nested classes/interfaces inherited from class com.atlassian.bamboo.plugins.github.accessor.GitHubAccessor
GitHubAccessor.ApiEndpoints, GitHubAccessor.GitHubAccessorFieldNames, GitHubAccessor.HttpResponse, GitHubAccessor.ParserFunction<T,R> -
Field Summary
Fields inherited from class com.atlassian.bamboo.plugins.github.accessor.GitHubAccessor
apiBaseUrl, GITHUB_API_BASE_URL, MAX_PAGE_SIZE, outboundWhitelist -
Constructor Summary
ConstructorsConstructorDescriptionGitHubAccessorWithBasicAuth(String username, String password, String apiBaseUrl, com.atlassian.plugins.whitelist.OutboundWhitelist outboundWhitelist) -
Method Summary
Modifier and TypeMethodDescriptionvoiddeleteComment(String repo, String commentId) Retrieves a list of accessible repositories.getCommentIds(String repo, String commitId) getCommits(String repo) protected <M extends org.apache.http.client.methods.HttpRequestBase>
voidsetAuthentication(@NotNull RESTCall<M> restCall) Sets the authentication details for the given REST call.Methods inherited from class com.atlassian.bamboo.plugins.github.accessor.GitHubAccessor
checkIfBaseUrlIsAllowed, commentOnCommit, createWebhook, delete, destroyWebhook, foldArrayAndSort, foldIntegerArrayAndSort, getBranches, getCommits, getJSONArrayResponseFromUrl, getPageableResults, getPullRequests, getStringFromUrl, getStringFromUrl, getWebhooks, post, sanitizeBaseUrl, sendBuildStatus
-
Constructor Details
-
GitHubAccessorWithBasicAuth
-
-
Method Details
-
getAccessibleRepositories
Description copied from class:GitHubAccessorRetrieves a list of accessible repositories.- Specified by:
getAccessibleRepositoriesin classGitHubAccessor- Returns:
- an iterable collection of accessible repository names
- Throws:
IOException- if an I/O error occursGitHubException- if a GitHub-specific error occurs
-
getAccessibleRepositoriesAndBranches
protected Map<String,Iterable<String>> getAccessibleRepositoriesAndBranches() throws IOException, GitHubException- Throws:
IOExceptionGitHubException
-
getUserOrganisations
- Throws:
IOExceptionGitHubException
-
getUserRepositories
- Throws:
IOExceptionGitHubException
-
getOrganisationRepositories
- Throws:
IOExceptionGitHubException
-
getCommits
- Throws:
IOExceptionGitHubException
-
getCommentIds
- Throws:
IOExceptionGitHubException
-
deleteComment
- Throws:
IOExceptionGitHubException
-
setAuthentication
protected <M extends org.apache.http.client.methods.HttpRequestBase> void setAuthentication(@NotNull @NotNull RESTCall<M> restCall) Description copied from class:GitHubAccessorSets the authentication details for the given REST call.- Specified by:
setAuthenticationin classGitHubAccessor- Type Parameters:
M- the type of the HTTP request- Parameters:
restCall- the REST call to set the authentication details for
-