com.atlassian.jira.bc.issue.search
Class AbstractIssuePickerSearchProvider

java.lang.Object
  extended by com.atlassian.jira.bc.issue.search.AbstractIssuePickerSearchProvider
All Implemented Interfaces:
IssuePickerSearchProvider
Direct Known Subclasses:
HistoryIssuePickerSearchProvider, LuceneCurrentSearchIssuePickerSearchProvider

public abstract class AbstractIssuePickerSearchProvider
extends Object
implements IssuePickerSearchProvider

Abstract convienience class with common methods for IssuePickerSearchProviers


Field Summary
protected  SearchProvider searchProvider
           
 
Constructor Summary
AbstractIssuePickerSearchProvider(SearchProvider searchProvider, ConstantsManager constantsManager)
           
 
Method Summary
protected abstract  String getId()
          This returns a simple ID of the results, used mainly for html tag ids
protected abstract  String getLabelKey()
          This returns the label key of the results, eg why type of results are they.
protected  SearchRequest getNoSortRequest(SearchRequest searchRequest, User currentUser)
          We need to remove any sorting that might be in play on the base SearchRequest.
protected abstract  SearchRequest getRequest(User user)
           
 IssuePickerResults getResults(JiraServiceContext context, IssuePickerSearchService.IssuePickerParameters issuePickerParams, int maxIssueCount)
          Returns a list of issues matching the query string
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

searchProvider

protected SearchProvider searchProvider
Constructor Detail

AbstractIssuePickerSearchProvider

public AbstractIssuePickerSearchProvider(SearchProvider searchProvider,
                                         ConstantsManager constantsManager)
Method Detail

getResults

public IssuePickerResults getResults(JiraServiceContext context,
                                     IssuePickerSearchService.IssuePickerParameters issuePickerParams,
                                     int maxIssueCount)
Description copied from interface: IssuePickerSearchProvider
Returns a list of issues matching the query string

Specified by:
getResults in interface IssuePickerSearchProvider
Parameters:
context - service context
issuePickerParams - params for issue picker
maxIssueCount - Number of issues still needed.
Returns:
list of issues that match query (implementation specific) which is never null.
See Also:
IssuePickerSearchProvider

getLabelKey

protected abstract String getLabelKey()
This returns the label key of the results, eg why type of results are they.

Returns:
an i18n key.

getId

protected abstract String getId()
This returns a simple ID of the results, used mainly for html tag ids

Returns:
an i18n key.

getNoSortRequest

protected SearchRequest getNoSortRequest(SearchRequest searchRequest,
                                         User currentUser)
We need to remove any sorting that might be in play on the base SearchRequest.

Parameters:
searchRequest - - the search request to wrap
currentUser - the user who is making this search request, can be null
Returns:
a wrapped SearchRequest with no sorting

getRequest

protected abstract SearchRequest getRequest(User user)


Copyright © 2002-2009 Atlassian. All Rights Reserved.