Interface ProjectRapidViewService
- All Known Implementing Classes:
ProjectRapidViewServiceImpl
@PublicApi
public interface ProjectRapidViewService
Service which provides functionality to interact with rapid views from a project specific context.
Before each operation validation is performed and its result is returned in ServiceOutcome
.
During validation, parameters and user's permissions are checked.
User param with null value is treated as non-logged user.
- Since:
- 7.2
-
Method Summary
Modifier and TypeMethodDescriptionfindFirstRapidViewByProject
(com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.project.Project project, Collator collator) Returns the first rapid view that contain an explicit reference to the given project (ordered ascending by 'NAME'.ServiceOutcome<Set<com.atlassian.jira.project.Project>>
findProjectsByRapidView
(com.atlassian.jira.user.ApplicationUser user, RapidView rapidView) Returns a set of projects that are referenced explicitly by the given rapid view.ServiceOutcome<Page<com.atlassian.jira.project.Project>>
findProjectsByRapidView
(com.atlassian.jira.user.ApplicationUser user, RapidView rapidView, PageRequest pageRequest) Returns a page of projects sorted by name that are referenced explicitly by the given rapid view.findRapidViewsByProject
(com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.project.Project project) Returns a list of rapid views that contain an explicit reference to the given project.getRapidViewsByProjectSortedByProjectCount
(com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.project.Project project) Returns a sorted list of rapid views that contain an explicit reference to the given project.
-
Method Details
-
findRapidViewsByProject
@Nonnull ServiceOutcome<List<RapidView>> findRapidViewsByProject(@Nullable com.atlassian.jira.user.ApplicationUser user, @Nonnull com.atlassian.jira.project.Project project) Returns a list of rapid views that contain an explicit reference to the given project.Views will be filtered down to those which the user can see.
- Parameters:
user
- the user who is performing operation and whose permissions are checked. Null means anonymous access.project
- the project for which to retrieve matching rapid views.- Returns:
- the matching rapid views
-
getRapidViewsByProjectSortedByProjectCount
@Nonnull ServiceOutcome<List<RapidView>> getRapidViewsByProjectSortedByProjectCount(@Nullable com.atlassian.jira.user.ApplicationUser user, com.atlassian.jira.project.Project project) Returns a sorted list of rapid views that contain an explicit reference to the given project.Views will be filtered down to those which the user can see. Views will be sorted based on increasing number of projects in the query.
- Parameters:
user
- the user who is performing operation and whose permissions are checked. Null means anonymous access.project
- the project for which to retrieve matching rapid views.- Returns:
- the matching rapid views
-
findFirstRapidViewByProject
@Nonnull ServiceOutcome<RapidView> findFirstRapidViewByProject(@Nullable com.atlassian.jira.user.ApplicationUser user, @Nonnull com.atlassian.jira.project.Project project, @Nonnull Collator collator) Returns the first rapid view that contain an explicit reference to the given project (ordered ascending by 'NAME'.Views will be filtered down to those which the user can see.
- Parameters:
user
- the user who is performing operation and whose permissions are checked. Null means anonymous access.project
- the project for which to retrieve the first matching rapid view.collator
- instance of @Collator
used for comparing views names- Returns:
- the first matching rapid view
-
findProjectsByRapidView
@Nonnull ServiceOutcome<Set<com.atlassian.jira.project.Project>> findProjectsByRapidView(@Nullable com.atlassian.jira.user.ApplicationUser user, @Nonnull RapidView rapidView) Returns a set of projects that are referenced explicitly by the given rapid view.Only projects that the user can browse will be included.
- Parameters:
user
- the user who is performing operation and whose permissions are checked. Null means anonymous access.rapidView
- the rapid view for which to retrieve matching projects.- Returns:
- the matching projects
-
findProjectsByRapidView
@Nonnull ServiceOutcome<Page<com.atlassian.jira.project.Project>> findProjectsByRapidView(@Nullable com.atlassian.jira.user.ApplicationUser user, @Nonnull RapidView rapidView, @Nonnull PageRequest pageRequest) Returns a page of projects sorted by name that are referenced explicitly by the given rapid view.Only projects that the user can browse will be included.
- Parameters:
user
- the user who is performing operation and whose permissions are checked. Null means anonymous access.rapidView
- the rapid view for which to retrieve matching projects.pageRequest
- information about the desired number of results and theirs offset.- Returns:
- a page of matching projects.
-