SearchQuery
An asynchronous version of search query.
Constructors
Types
A prepared search query used for delete by count API.
A prepared search query used for delete by query API.
A prepared search query is a public read-only view to a search query. Mainly it is used to compile a search query.
A prepared search query used for update by query API.
Functions
Clears the existing aggregations.
Adds aggregations to the existing query aggregations.
Method is called before query execution. Can be overriden in subclasses of SearchQuery.
Clones this search query builder.
Retrieves a number of hits for the search query using an index.
Update by query API.
Clears current search query doc value fields.
Adds fields to the search query doc value fields list.
Alias of SearchQuery.search. Executes the search query using an index.
Clears current search query extensions.
Adds extensions to the search query extensions list.
Clears current search query retrieval fields.
Adds fields to the search query retrieval fields list.
Clears the existing filters.
Combines all the filter expressions together and wraps the existing query using the dev.evo.elasticmagic.query.Bool query expression.
Sets a number of hits to skip in a search result.
Clears the existing post filters.
Filter expressions in the post filter will be applied after the aggregations are calculated. Useful for building faceted filtering.
Makes an immutable view of the search query. Be careful when using this method.
Replaces main query expression.
Allows to replace a specific query expression node using a handle of the node.
Enables/disables a request cache of the search query.
Clears the existing rescorers.
Adds rescores to the existing query rescorers. Rescoring is executed after post filter phase.
Sets a routing parameter of the search query. A search request will be send to a specific shard.
Updates search type of the search query.
Clears current search query runtime fields.
Adds fields to the search query runtime fields list.
Clears current search query stored fields.
Adds fields to the search query script fields list.
Executes the search query using an index.
Updates search parameters.
Updates search type of the search query.
Specifies if a sequence number and a primary term should be returned within a hit.
Sets a maximum number of hits in a search result.
Clears source filtering values that were previously set.
Adds includes field lists to the document source fields filtering.
Disables or enables document's source filtering.
Clears current search query stored fields.
Adds fields to the search query stored fields list.
Sets a maximum number of matched documents per shard after which the query should be terminated.
If trackScores is true
forces computing scores even when sorting on a field.
When trackTotalHits is true
the search query will always count the total number of hits that match the query.
Update by query API.
Enables/disables a document version to be returned within a hit.