public class SearchRequestUtils extends Object
Constructor and Description |
---|
SearchRequestUtils() |
Modifier and Type | Method and Description |
---|---|
static SearchContext |
getCombinedSearchContext(SearchContext baseSearchContext,
SearchContext possibleContext)
Creates the most specific
SearchContext possible from the two parameters. |
static List<String> |
getSearchSortDescriptions(SearchRequest searchRequest,
FieldManager fieldManager,
SearchHandlerManager searchHandlerManager,
SearchSortUtil searchSortUtil,
I18nHelper i18nHelper,
com.atlassian.crowd.embedded.api.User searcher)
Deprecated.
Use
SearchSortUtil.getSearchSortDescriptions(SearchRequest, I18nHelper, User) instead. Since v5.0. |
public static SearchContext getCombinedSearchContext(SearchContext baseSearchContext, SearchContext possibleContext)
SearchContext
possible from the two parameters. The baseSearchContext is used as
the parent context and the possibleContext is used to narrow it down. Thus if the possibleContext contains Project A
and the baseSearchContext is global, a context with Project A will be returned. If baseSearchContext is Project A & Project B
the Project A will be returned. If baseSearchContext is only Project B, then Project B will be returned. The same
logic applies for issue types.baseSearchContext
- the base parent contextpossibleContext
- the context to try to narrow the baseSearchContext onSearchContext
object based on the baseSearchContext. Null if baseSearchContext is nullpublic static List<String> getSearchSortDescriptions(SearchRequest searchRequest, FieldManager fieldManager, SearchHandlerManager searchHandlerManager, SearchSortUtil searchSortUtil, I18nHelper i18nHelper, com.atlassian.crowd.embedded.api.User searcher)
SearchSortUtil.getSearchSortDescriptions(SearchRequest, I18nHelper, User)
instead. Since v5.0.searchRequest
- the search request containing the sorts; must not be null.fieldManager
- field managersearchHandlerManager
- search handler managersearchSortUtil
- search sort utilityi18nHelper
- i18n helpersearcher
- the user making the requestCopyright © 2002-2016 Atlassian. All Rights Reserved.