BaseSearchQuery
An abstract class that holds all the search query builder methods. Inheritors of the class can implement some shortcut methods. For instance SearchQuery.execute which can be suspendable or blocking.
Constructors
Types
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.
Clears current search query doc value fields.
Adds fields to the search query doc value fields 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.
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 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.
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 timeout for the search query.
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.