Interface ProjectSearchRequestService

All Known Implementing Classes:
ProjectSearchRequestServiceImpl

@ExperimentalApi public interface ProjectSearchRequestService
Provides functionality to associate a search request with a given project.
Since:
v7.0
  • Method Details

    • associateSearchRequestsWithProject

      ServiceOutcome<List<SearchRequest>> associateSearchRequestsWithProject(ApplicationUser user, @Nonnull Project project, Long... searchRequestIds)
      For a given project this method will associated the provided search requests such that they will be returned by subsequent calls to getSearchRequestsForProject(ApplicationUser, Project).

      The user performing this operation must have rights to ProjectAction.EDIT_PROJECT_CONFIG, otherwise this this method will return an error result.

      If a search request cannot be found by its id it will simply not be associated with the project.

      Parameters:
      user - The user performing this operation
      project - The project to associate the search requests with
      searchRequestIds - A list of search requests to associate
      Since:
      7.0
    • getSearchRequestsForProject

      List<SearchRequest> getSearchRequestsForProject(ApplicationUser user, @Nonnull Project project)
      Retrieves all search requests for a given project that the user is allowed to see. If the provided user does not have the ProjectAction.VIEW_ISSUES permission this method should return an empty list.
      Parameters:
      user - The user performing this operation
      project - The project that search requests are associated with
      Returns:
      all search requests for the given project that the user provided is allowed to see. Empty if none are found.
      Since:
      7.0