Interface RssPermissionManager

    • Method Summary

      All Methods Instance Methods Abstract Methods 
      Modifier and Type Method Description
      void disableAllProjectAccess​(long repositoryId)
      Forbid Bamboo Specs stored in the repository identified by repositoryId to create or modify plans in all projects and deployment projects in Bamboo.
      void disableAllRepositoriesAccess​(long repositoryId)
      Forbid Bamboo Specs stored in the repository identified by repositoryId to use any linked repositories in Bamboo.
      void disableProjectCreation​(long repositoryId)
      Forbid Bamboo Specs stored in the repository identified by repositoryId to create new projects.
      List<Long> getAccessibleDeploymentProjects​(long repositoryId)
      List all deployment projects which can be created or modified by the Bamboo Specs from a repository identified by repositoryId.
      List<Long> getAccessibleProjects​(long repositoryId)
      List all build projects in which plans can be created or modified by the Bamboo Specs from a repository identified by repositoryId.
      List<Long> getAccessibleRepositories​(long repositoryId)
      List all repositories which can be used by the Bamboo Specs from a repository identified by repositoryId.
      List<Long> getRepositoriesWithAccessToDeploymentProject​(long projectId)
      List all repositories which are allowed to create or modify plans inside a deployment project identified by projectId.
      List<Long> getRepositoriesWithAccessToProject​(long projectId)
      List all repositories which are allowed to create or modify plans inside a build project identified by projectId.
      List<Long> getRepositoriesWithAccessToRepository​(long targetRepositoryId)
      List all repositories which are allowed to use target repository identified by targetRepositoryId.
      void grantDeploymentProjectAccess​(long projectId, long repositoryId)
      Allow Bamboo Specs stored in the repository identified by repositoryId to modify a deployment project identified by projectId.
      void grantProjectAccess​(long projectId, long repositoryId)
      Allow Bamboo Specs stored in the repository identified by repositoryId to modify plans in a project identified by projectId.
      void grantRepositoryAccess​(long targetRepositoryId, long repositoryId)
      Allow Bamboo Specs stored in the repository identified by repositoryId to use repository identified by targetRepositoryId.
      boolean isAllProjectsAccess​(long repositoryId)
      Whether a Bamboo Specs stored in the repository identified by repositoryId to modify all projects.
      boolean isAllRepositoriesAccess​(long repositoryId)
      Whether a Bamboo Specs stored in the repository identified by repositoryId to use all repositories.
      boolean isProjectCreationAllowed​(long repositoryId)
      Whether a Bamboo Specs stored in the repository identified by repositoryId are allowed to create new build and deployment projects.
      void revokeDeploymentProjectAccess​(long projectId, long repositoryId)
      Forbid Bamboo Specs stored in the repository identified by repositoryId to modify a deployment project identified by projectId.
      void revokeProjectAccess​(long projectId, long repositoryId)
      Forbid Bamboo Specs stored in the repository identified by repositoryId to modify plans in a project identified by projectId.
      void revokeRepositoryAccess​(long targetRepositoryId, long repositoryId)
      Forbid Bamboo Specs stored in the repository identified by repositoryId to use a repository identified by targetRepositoryId.
      void toggleAllProjectRepositoriesAccess​(long repositoryId, @NotNull String projectKey, boolean enabled)
      Allow or forbid Bamboo Specs stored in the repository identified by repositoryId to use all project repositories in plan of project.
      void toggleAllProjectsAccess​(long repositoryId, boolean enabled)
      Allow or forbid Bamboo Specs stored in the repository identified by repositoryId to create or modify plans in all projects and deployment projects in Bamboo.
      void toggleAllRepositoriesAccess​(long repositoryId, boolean enable)
      Allow or forbid Bamboo Specs stored in the repository identified by repositoryId to use all linked repositories in plans or deployment projects in Bamboo.
      void toggleProjectCreationPermission​(long repositoryId, boolean enabled)
      Allow or forbid Bamboo Specs stored in the repository identified by repositoryId to create new build and deployment projects.
    • Method Detail

      • getAccessibleProjects

        List<Long> getAccessibleProjects​(long repositoryId)
        List all build projects in which plans can be created or modified by the Bamboo Specs from a repository identified by repositoryId.
        Parameters:
        repositoryId - ID of the repository
        Returns:
        list of project IDs
      • getAccessibleDeploymentProjects

        List<Long> getAccessibleDeploymentProjects​(long repositoryId)
        List all deployment projects which can be created or modified by the Bamboo Specs from a repository identified by repositoryId.
        Parameters:
        repositoryId - ID of the repository
        Returns:
        list of project IDs
      • getAccessibleRepositories

        List<Long> getAccessibleRepositories​(long repositoryId)
        List all repositories which can be used by the Bamboo Specs from a repository identified by repositoryId.
        Parameters:
        repositoryId - ID of the repository
        Returns:
        list of vcs repository IDs
      • getRepositoriesWithAccessToProject

        List<Long> getRepositoriesWithAccessToProject​(long projectId)
        List all repositories which are allowed to create or modify plans inside a build project identified by projectId.
        Parameters:
        projectId - ID of the project
        Returns:
        list of repository IDs
      • getRepositoriesWithAccessToDeploymentProject

        List<Long> getRepositoriesWithAccessToDeploymentProject​(long projectId)
        List all repositories which are allowed to create or modify plans inside a deployment project identified by projectId.
        Parameters:
        projectId - ID of the project
        Returns:
        list of repository IDs
      • getRepositoriesWithAccessToRepository

        List<Long> getRepositoriesWithAccessToRepository​(long targetRepositoryId)
        List all repositories which are allowed to use target repository identified by targetRepositoryId.
        Parameters:
        targetRepositoryId - ID of the repository
        Returns:
        list of repository IDs
      • grantProjectAccess

        void grantProjectAccess​(long projectId,
                                long repositoryId)
                         throws AccessDeniedException
        Allow Bamboo Specs stored in the repository identified by repositoryId to modify plans in a project identified by projectId.
        Parameters:
        projectId - id of the project
        repositoryId - id of the repository
        Throws:
        AccessDeniedException - if user doesn't have ADMINISTRATION permission to project or READ permission to repository
      • grantDeploymentProjectAccess

        void grantDeploymentProjectAccess​(long projectId,
                                          long repositoryId)
                                   throws AccessDeniedException
        Allow Bamboo Specs stored in the repository identified by repositoryId to modify a deployment project identified by projectId.
        Parameters:
        repositoryId - id of the repository
        projectId - id of the project
        Throws:
        AccessDeniedException - if user doesn't have ADMINISTRATION permission to deployment project or READ permission to repository
      • grantRepositoryAccess

        void grantRepositoryAccess​(long targetRepositoryId,
                                   long repositoryId)
        Allow Bamboo Specs stored in the repository identified by repositoryId to use repository identified by targetRepositoryId.
        Parameters:
        targetRepositoryId - id of the target repository
        repositoryId - id of the repository
        Throws:
        AccessDeniedException - if user doesn't have ADMINISTRATION permission to target repository or READ permission to repository
      • revokeProjectAccess

        void revokeProjectAccess​(long projectId,
                                 long repositoryId)
                          throws AccessDeniedException
        Forbid Bamboo Specs stored in the repository identified by repositoryId to modify plans in a project identified by projectId.
        Parameters:
        projectId - id of the project
        repositoryId - id of the repository
        Throws:
        AccessDeniedException - if user doesn't have ADMINISTRATION permission to project
      • revokeDeploymentProjectAccess

        void revokeDeploymentProjectAccess​(long projectId,
                                           long repositoryId)
                                    throws AccessDeniedException
        Forbid Bamboo Specs stored in the repository identified by repositoryId to modify a deployment project identified by projectId.
        Parameters:
        projectId - id of the project
        repositoryId - id of the repository
        Throws:
        AccessDeniedException - if user doesn't have ADMINISTRATION permission to deployment project
      • revokeRepositoryAccess

        void revokeRepositoryAccess​(long targetRepositoryId,
                                    long repositoryId)
                             throws AccessDeniedException
        Forbid Bamboo Specs stored in the repository identified by repositoryId to use a repository identified by targetRepositoryId.
        Parameters:
        targetRepositoryId - id of the target repository
        repositoryId - id of the repository
        Throws:
        AccessDeniedException - if user doesn't have ADMINISTRATION permission to target repository
      • isAllProjectsAccess

        boolean isAllProjectsAccess​(long repositoryId)
                             throws AccessDeniedException
        Whether a Bamboo Specs stored in the repository identified by repositoryId to modify all projects.
        Parameters:
        repositoryId - id of the repository
        Returns:
        boolean
        Throws:
        AccessDeniedException - if user doesn't have READ permission to repository
      • isAllRepositoriesAccess

        boolean isAllRepositoriesAccess​(long repositoryId)
                                 throws AccessDeniedException
        Whether a Bamboo Specs stored in the repository identified by repositoryId to use all repositories.
        Parameters:
        repositoryId - id of the repository
        Returns:
        boolean
        Throws:
        AccessDeniedException - if user doesn't have READ permission to repository
      • isProjectCreationAllowed

        boolean isProjectCreationAllowed​(long repositoryId)
                                  throws AccessDeniedException
        Whether a Bamboo Specs stored in the repository identified by repositoryId are allowed to create new build and deployment projects.
        Parameters:
        repositoryId - id of the repository
        Returns:
        boolean
        Throws:
        AccessDeniedException - if user doesn't have READ permission to repository
Parameters:
repositoryId - id of the repository
Throws:
AccessDeniedException - if user doesn't have ADMINISTRATION or RESTRICTEDADMINISTRATION global permission
Parameters:
repositoryId - id of the repository
projectKey - key of project
Throws:
AccessDeniedException - if user doesn't have ADMINISTRATION permission on project