public class BitbucketApiServiceImpl extends Object implements BitbucketApiService, org.springframework.beans.factory.DisposableBean
Constructor and Description |
---|
BitbucketApiServiceImpl() |
Modifier and Type | Method and Description |
---|---|
void |
destroy() |
List<BitbucketNodeEntity> |
getBranches(String owner,
String slug,
String username,
String password)
JAXB binding cannot be used in this method as Bitbucket returns JSON with node names containing characters
which cannot be used as XML element names.
|
List<BitbucketResourceEntity> |
getPublicRepositories(String username)
Return a list of public repositories that user has access to.
|
List<BitbucketResourceEntity> |
getRepositories(String username,
String password)
Retrieve list of all repositories accessible to Bitbucket user
|
void |
updateBuildStatus(String owner,
String slug,
String revision,
RestBuildStatus buildStatus,
String username,
String password)
Send build status update to Bitbucket server
|
public void destroy() throws Exception
destroy
in interface org.springframework.beans.factory.DisposableBean
Exception
@NotNull public List<BitbucketResourceEntity> getPublicRepositories(@NotNull String username) throws BitbucketApiException
BitbucketApiService
getPublicRepositories
in interface BitbucketApiService
BitbucketApiException
@NotNull public List<BitbucketResourceEntity> getRepositories(@NotNull String username, @NotNull String password) throws BitbucketApiException
BitbucketApiService
getRepositories
in interface BitbucketApiService
BitbucketApiException
@NotNull public List<BitbucketNodeEntity> getBranches(@NotNull String owner, @NotNull String slug, @NotNull String username, @Nullable String password) throws BitbucketApiException
getBranches
in interface BitbucketApiService
owner
- slug
- username
- password
- BitbucketApiException
public void updateBuildStatus(@NotNull String owner, @NotNull String slug, @NotNull String revision, @NotNull RestBuildStatus buildStatus, @NotNull String username, @NotNull String password) throws BitbucketApiException
BitbucketApiService
updateBuildStatus
in interface BitbucketApiService
owner
- repository ownerslug
- repository slugrevision
- changeset revisionbuildStatus
- payload to be sent to Bitbucketusername
- credentials used to authenticate against Bitbucketpassword
- credentials used to authenticate against BitbucketBitbucketApiException
Copyright © 2017 Atlassian Software Systems Pty Ltd. All rights reserved.