| 1234567891011121314151617181920212223242526272829303132 | [[java-rest-high-java-builders]]== Using Java BuildersThe Java High Level REST Client depends on the Elasticsearch core project which providesdifferent types of Java `Builders` objects, including:Query Builders::The query builders are used to create the query to execute within a search request. Thereis a query builder for every type of query supported by the Query DSL. Each query builderimplements the `QueryBuilder` interface and allows to set the specific options for a giventype of query. Once created, the `QueryBuilder` object can be set as the query parameter of`SearchSourceBuilder`. The <<java-rest-high-document-search-request-building-queries, Search Request>>page shows an example of how to build a full search request using `SearchSourceBuilder` and`QueryBuilder` objects. The <<java-rest-high-query-builders, Building Search Queries>> pagegives a list of all available search queries with their corresponding `QueryBuilder` objectsand `QueryBuilders` helper methods.Aggregation Builders::Similarly to query builders, the aggregation builders are used to create the aggregations tocompute during a search request execution. There is an aggregation builder for every type ofaggregation (or pipeline aggregation) supported by Elasticsearch. All builders extend the`AggregationBuilder` class (or `PipelineAggregationBuilder`class). Once created, `AggregationBuilder`objects can be set as the aggregation parameter of `SearchSourceBuilder`. There is a exampleof how `AggregationBuilder` objects are used with `SearchSourceBuilder` objects to define the aggregationsto compute with a search query in <<java-rest-high-document-search-request-building-aggs, Search Request>> page.The <<java-rest-high-aggregation-builders, Building Aggregations>> page gives a list of all availableaggregations with their corresponding `AggregationBuilder` objects and `AggregationBuilders` helper methods.include::query-builders.asciidoc[]include::aggs-builders.asciidoc[]
 |