com.atlassian.greenhopper.service.issue
Interface SearchService

All Known Implementing Classes:
SearchServiceImpl

public interface SearchService

Wrapper around JIRA's SearchService to make results easier to consume in GH.

Since:
v5.8.5
Author:
mtokar

Method Summary
 ServiceOutcome<java.lang.Iterable<com.atlassian.jira.issue.Issue>> findOne(com.atlassian.crowd.embedded.api.User user, com.atlassian.query.Query query)
          Perform an issue search for a single issue.
 ServiceOutcome<com.atlassian.jira.issue.search.SearchResults> search(com.atlassian.crowd.embedded.api.User user, com.atlassian.query.Query query)
          Perform an issue search using the specified user and query.
 ServiceOutcome<java.lang.Long> searchCount(com.atlassian.crowd.embedded.api.User user, com.atlassian.query.Query query)
          Perform an issue search using the specified user and query and return the number of results.
 ServiceOutcome<java.lang.Long> searchCountOverrideSecurity(com.atlassian.crowd.embedded.api.User user, org.apache.lucene.search.Query query)
          Perform an issue search using the specified user and query and return the number of results.
 ServiceOutcome<java.lang.Long> searchCountOverrideSecurity(com.atlassian.crowd.embedded.api.User user, com.atlassian.query.Query query)
          Perform an issue search using the specified user and query and return the number of results.
 ServiceOutcome<com.atlassian.jira.issue.search.SearchResults> searchOverrideSecurity(com.atlassian.crowd.embedded.api.User user, com.atlassian.query.Query query)
          Perform an issue search using the specified user and query and return the results.
 

Method Detail

findOne

@NotNull
ServiceOutcome<java.lang.Iterable<com.atlassian.jira.issue.Issue>> findOne(com.atlassian.crowd.embedded.api.User user,
                                                                                   com.atlassian.query.Query query)
Perform an issue search for a single issue. Will configure the PagerFilter appropriately. Returns an Iterable so you can neatly just for-each it if there are no errors, and things just work™


search

@NotNull
ServiceOutcome<com.atlassian.jira.issue.search.SearchResults> search(com.atlassian.crowd.embedded.api.User user,
                                                                             com.atlassian.query.Query query)
Perform an issue search using the specified user and query. Will automatically select the correct PagerFilter depending on GreenHopper's settings. Neatly wraps exceptions into ServiceOutcome.

Parameters:
user - the user
query - the query
Returns:
the outcome

searchCountOverrideSecurity

@NotNull
ServiceOutcome<java.lang.Long> searchCountOverrideSecurity(com.atlassian.crowd.embedded.api.User user,
                                                                   org.apache.lucene.search.Query query)
Perform an issue search using the specified user and query and return the number of results. User's permissions are not taken into account when performing the search. Neatly wraps exceptions into ServiceOutcome.

Parameters:
user - the user
query - the lucene query to search for
Returns:
the outcome

searchCount

@NotNull
ServiceOutcome<java.lang.Long> searchCount(com.atlassian.crowd.embedded.api.User user,
                                                   com.atlassian.query.Query query)
Perform an issue search using the specified user and query and return the number of results. Neatly wraps exceptions into ServiceOutcome.

Parameters:
user - the user
query - the query
Returns:
the outcome

searchCountOverrideSecurity

@NotNull
ServiceOutcome<java.lang.Long> searchCountOverrideSecurity(com.atlassian.crowd.embedded.api.User user,
                                                                   com.atlassian.query.Query query)
Perform an issue search using the specified user and query and return the number of results. User's permissions are not taken into account when performing the search. Neatly wraps exceptions into ServiceOutcome.

Parameters:
user - the user
query - the query
Returns:
the outcome

searchOverrideSecurity

@NotNull
ServiceOutcome<com.atlassian.jira.issue.search.SearchResults> searchOverrideSecurity(com.atlassian.crowd.embedded.api.User user,
                                                                                             com.atlassian.query.Query query)
Perform an issue search using the specified user and query and return the results. User's permissions are not taken into account when performing the search. Neatly wraps exceptions into ServiceOutcome.

Parameters:
user - the user
query - the query
Returns:
the outcome


Copyright © 2007-2012 Atlassian. All Rights Reserved.