Class MultiTextFieldQuery
java.lang.Object
com.atlassian.confluence.search.v2.query.MultiTextFieldQuery
- All Implemented Interfaces:
Expandable<SearchQuery>,SearchQuery
- Direct Known Subclasses:
TextQuery
Represents a query against multiple fields.
-
Field Summary
Fields inherited from interface com.atlassian.confluence.search.v2.SearchQuery
DEFAULT_BOOST -
Constructor Summary
ConstructorsConstructorDescriptionMultiTextFieldQuery(String query, String... fields) Constructs a multi-field query with the operator set toBooleanOperator.AND.MultiTextFieldQuery(String query, Set<String> fields, BooleanOperator operator) Constructs a multi-field query with the specified query, fields and operator.MultiTextFieldQuery(Collection<String> fields, Map<String, ? extends AnalyzerDescriptorProvider> analyzerProviders, BooleanOperator operator, String query) Create a query where a field can be tokenized by a provided analyzer. -
Method Summary
Modifier and TypeMethodDescriptionbooleanexpand()Expands this query into a composite query (that composes other queries).Map<String,? extends AnalyzerDescriptorProvider> Returns information required to construct analyzer for the query if it is available.getKey()List of parameters asStrings orSearchQuerys.getQuery()inthashCode()Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.atlassian.confluence.search.v2.SearchQuery
getBoost, getSubClauses
-
Constructor Details
-
MultiTextFieldQuery
Constructs a multi-field query with the specified query, fields and operator.- Parameters:
fields- the fields to query againstoperator- whether the query must match all termsANDor any of them {code OR}.query- the query
-
MultiTextFieldQuery
Constructs a multi-field query with the operator set toBooleanOperator.AND.- Parameters:
fields- the fields to query againstquery- the query
-
MultiTextFieldQuery
public MultiTextFieldQuery(Collection<String> fields, Map<String, ? extends AnalyzerDescriptorProvider> analyzerProviders, BooleanOperator operator, String query) Create a query where a field can be tokenized by a provided analyzer.- Parameters:
fields- the fields to query againstanalyzerProviders- specifies a non-standard analyzer for a fieldoperator- whether the query must match all termsANDor any of them {code OR}query- the query- Since:
- 7.0
-
-
Method Details
-
getKey
- Specified by:
getKeyin interfaceSearchQuery- Returns:
- the plugin key
-
getQuery
-
getUnescapedQuery
-
getFields
-
getAnalyzerProviders
Returns information required to construct analyzer for the query if it is available.- Since:
- 7.0
-
getOperator
-
getParameters
Description copied from interface:SearchQueryList of parameters asStrings orSearchQuerys.- Specified by:
getParametersin interfaceSearchQuery- Returns:
Strings orSearchQuerys.
-
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
-
equals
-
hashCode
public int hashCode()
-