Class ContentCategoryQuery
- java.lang.Object
-
- com.atlassian.confluence.search.v2.query.ContentCategoryQuery
-
- All Implemented Interfaces:
Expandable<SearchQuery>,SearchQuery
public class ContentCategoryQuery extends Object implements SearchQuery
SearchQuery that finds content where content type is from the list of specified categories- Since:
- 7.20
-
-
Constructor Summary
Constructors Constructor Description ContentCategoryQuery(Category contentCategory)Construct aSearchQuerythat finds content matching a givenCategoryContentCategoryQuery(Set<Category> contentCategories)Construct aSearchQuerythat finds content matching at least one of the specified Set ofCategory
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description SearchQueryexpand()Expands this query into a composite query (that composes other queries).StringgetKey()List<Category>getParameters()List of parameters asStrings orSearchQuerys.-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.atlassian.confluence.search.v2.SearchQuery
getBoost, getSubClauses
-
-
-
-
Field Detail
-
KEY
public static final String KEY
- See Also:
- Constant Field Values
-
-
Constructor Detail
-
ContentCategoryQuery
public ContentCategoryQuery(Category contentCategory)
Construct aSearchQuerythat finds content matching a givenCategory- Parameters:
contentCategory- Category to match
-
ContentCategoryQuery
public ContentCategoryQuery(Set<Category> contentCategories)
Construct aSearchQuerythat finds content matching at least one of the specified Set ofCategory- Parameters:
contentCategories- a Set ofCategory- Throws:
IllegalArgumentException- if contentCategories list is empty
-
-
Method Detail
-
getKey
public String getKey()
- Specified by:
getKeyin interfaceSearchQuery- Returns:
- the plugin key
-
getParameters
public List<Category> getParameters()
Description copied from interface:SearchQueryList of parameters asStrings orSearchQuerys.- Specified by:
getParametersin interfaceSearchQuery- Returns:
Strings orSearchQuerys.
-
expand
public SearchQuery expand()
Description copied from interface:SearchQueryExpands this query into a composite query (that composes other queries). By overriding this method, one can specify a new query that is composition of the behaviour of the composed queries.- Specified by:
expandin interfaceExpandable<SearchQuery>- Specified by:
expandin interfaceSearchQuery- Returns:
- a query
-
-