com.atlassian.crucible.spi.services
Interface RepositoryService


public interface RepositoryService

Provides an API for working with repositories


Method Summary
 java.util.List<RepositoryData> getRepositories()
          Returns the details of all the repositories in this instance that the current user has access to.
 RepositoryData getRepository(java.lang.String name)
          Returns the details of the repository with the specified name.
 SCMRepository getSCMRepository(java.lang.String name)
           Returns an SCMRepository instance for the Crucible source repository with the given name.
 

Method Detail

getRepositories

java.util.List<RepositoryData> getRepositories()
Returns the details of all the repositories in this instance that the current user has access to.

Returns:

getRepository

RepositoryData getRepository(java.lang.String name)
Returns the details of the repository with the specified name. When the repository exists, but the user has no access to it (possibly because the user isnot authenticated), a NotPermittedException is raised. The supplied repository name can be either a Crucible SCM plugin repository, or a FishEye repository.

Parameters:
name - the name of a Crucible repository.
Returns:
details of the repository with the specified name.

getSCMRepository

SCMRepository getSCMRepository(java.lang.String name)

Returns an SCMRepository instance for the Crucible source repository with the given name. Crucible source repositories are repositories of type "plugin" and implement PluginRepositoryData.

This method will return null for FishEye repositories. To browse and search FishEye repositories, use the services provided by the com.atlassian.fisheye.spi.services package.

This method requires the caller to be logged in, or Crucible must be configured to allow anonymous access.

Parameters:
name - the name of a Crucible SCM plugin repository.
Returns:
Throws:
NotPermittedException - when the caller is not logged in and Crucible does not allow anonymous access.
Since:
v2.1