Class SearchMvtRequest.Builder
java.lang.Object
co.elastic.clients.elasticsearch._core.SearchMvtRequest.Builder
- All Implemented Interfaces:
ObjectBuilder<SearchMvtRequest>
- Enclosing class:
- SearchMvtRequest
public static class SearchMvtRequest.Builder extends java.lang.Object implements ObjectBuilder<SearchMvtRequest>
Builder for
SearchMvtRequest.-
Constructor Summary
Constructors Constructor Description Builder() -
Method Summary
Modifier and Type Method Description SearchMvtRequest.BuilderaddFields(java.lang.String value)Add a value tofields(List), creating the list if needed.SearchMvtRequest.BuilderaddIndex(java.lang.String value)Add a value toindex(List), creating the list if needed.SearchMvtRequest.BuilderaddSort(jakarta.json.JsonValue value)Add a value tosort(List), creating the list if needed.SearchMvtRequest.Builderaggs(java.lang.String key, java.util.function.Function<Aggregation.Builder,ObjectBuilder<Aggregation>> fn)Setaggs(Map)to a singleton map.SearchMvtRequest.Builderaggs(java.util.Map<java.lang.String,Aggregation> value)Sub-aggregations for the geotile_grid.SearchMvtRequestbuild()Builds aSearchMvtRequest.SearchMvtRequest.BuilderexactBounds(java.lang.Boolean value)If false, the meta layer’s feature is the bounding box of the tile.SearchMvtRequest.Builderextent(java.lang.Integer value)Size, in pixels, of a side of the tile.SearchMvtRequest.Builderfield(java.lang.String value)Field containing geospatial data to returnSearchMvtRequest.Builderfields(java.lang.String... value)Fields to return in thehitslayer.SearchMvtRequest.Builderfields(java.util.List<java.lang.String> value)Fields to return in thehitslayer.SearchMvtRequest.BuildergridPrecision(java.lang.Integer value)Additional zoom levels available through the aggs layer.SearchMvtRequest.BuildergridType(GridType value)Determines the geometry type for features in the aggs layer.SearchMvtRequest.Builderindex(java.lang.String... value)Comma-separated list of data streams, indices, or aliases to searchSearchMvtRequest.Builderindex(java.util.List<java.lang.String> value)Comma-separated list of data streams, indices, or aliases to searchSearchMvtRequest.BuilderputAggs(java.lang.String key, Aggregation value)Add a key/value toaggs(Map), creating the map if needed.SearchMvtRequest.BuilderputAggs(java.lang.String key, java.util.function.Function<Aggregation.Builder,ObjectBuilder<Aggregation>> fn)Add a key/value toaggs(Map), creating the map if needed.SearchMvtRequest.BuilderputRuntimeMappings(java.lang.String key, RuntimeField value)Add a key/value toruntimeMappings(Map), creating the map if needed.SearchMvtRequest.BuilderputRuntimeMappings(java.lang.String key, java.util.function.Function<RuntimeField.Builder,ObjectBuilder<RuntimeField>> fn)Add a key/value toruntimeMappings(Map), creating the map if needed.SearchMvtRequest.Builderquery(Query value)Query DSL used to filter documents for the search.SearchMvtRequest.Builderquery(java.util.function.Function<Query.Builder,ObjectBuilder<Query>> fn)Query DSL used to filter documents for the search.SearchMvtRequest.BuilderruntimeMappings(java.lang.String key, java.util.function.Function<RuntimeField.Builder,ObjectBuilder<RuntimeField>> fn)SetruntimeMappings(Map)to a singleton map.SearchMvtRequest.BuilderruntimeMappings(java.util.Map<java.lang.String,RuntimeField> value)Defines one or more runtime fields in the search request.SearchMvtRequest.Buildersize(java.lang.Integer value)Maximum number of features to return in the hits layer.SearchMvtRequest.Buildersort(jakarta.json.JsonValue... value)Sorts features in the hits layer.SearchMvtRequest.Buildersort(java.util.List<jakarta.json.JsonValue> value)Sorts features in the hits layer.SearchMvtRequest.Builderx(int value)X coordinate for the vector tile to searchSearchMvtRequest.Buildery(int value)Y coordinate for the vector tile to searchSearchMvtRequest.Builderzoom(int value)Zoom level for the vector tile to searchMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
index
Comma-separated list of data streams, indices, or aliases to searchAPI name:
index -
index
Comma-separated list of data streams, indices, or aliases to searchAPI name:
index -
addIndex
Add a value toindex(List), creating the list if needed. 4 -
field
Field containing geospatial data to returnAPI name:
field -
zoom
Zoom level for the vector tile to searchAPI name:
zoom -
x
X coordinate for the vector tile to searchAPI name:
x -
y
Y coordinate for the vector tile to searchAPI name:
y -
aggs
Sub-aggregations for the geotile_grid.Supports the following aggregation types:
- avg
- cardinality
- max
- min
- sum
API name:
aggs -
putAggs
Add a key/value toaggs(Map), creating the map if needed. -
aggs
public SearchMvtRequest.Builder aggs(java.lang.String key, java.util.function.Function<Aggregation.Builder,ObjectBuilder<Aggregation>> fn)Setaggs(Map)to a singleton map. -
putAggs
public SearchMvtRequest.Builder putAggs(java.lang.String key, java.util.function.Function<Aggregation.Builder,ObjectBuilder<Aggregation>> fn)Add a key/value toaggs(Map), creating the map if needed. -
exactBounds
If false, the meta layer’s feature is the bounding box of the tile. If true, the meta layer’s feature is a bounding box resulting from a geo_bounds aggregation. The aggregation runs on <field> values that intersect the <zoom>/<x>/<y> tile with wrap_longitude set to false. The resulting bounding box may be larger than the vector tile.API name:
exact_bounds -
extent
Size, in pixels, of a side of the tile. Vector tiles are square with equal sides.API name:
extent -
fields
Fields to return in thehitslayer. Supports wildcards (*). This parameter does not support fields with array values. Fields with array values may return inconsistent results.API name:
fields -
fields
Fields to return in thehitslayer. Supports wildcards (*). This parameter does not support fields with array values. Fields with array values may return inconsistent results.API name:
fields -
addFields
Add a value tofields(List), creating the list if needed. 4 -
gridPrecision
Additional zoom levels available through the aggs layer. For example, if <zoom> is 7 and grid_precision is 8, you can zoom in up to level 15. Accepts 0-8. If 0, results don’t include the aggs layer.API name:
grid_precision -
gridType
Determines the geometry type for features in the aggs layer. In the aggs layer, each feature represents a geotile_grid cell. If 'grid' each feature is a Polygon of the cells bounding box. If 'point' each feature is a Point that is the centroid of the cell.API name:
grid_type -
query
Query DSL used to filter documents for the search.API name:
query -
query
public SearchMvtRequest.Builder query(java.util.function.Function<Query.Builder,ObjectBuilder<Query>> fn)Query DSL used to filter documents for the search.API name:
query -
runtimeMappings
public SearchMvtRequest.Builder runtimeMappings(@Nullable java.util.Map<java.lang.String,RuntimeField> value)Defines one or more runtime fields in the search request. These fields take precedence over mapped fields with the same name.API name:
runtime_mappings -
putRuntimeMappings
Add a key/value toruntimeMappings(Map), creating the map if needed. -
runtimeMappings
public SearchMvtRequest.Builder runtimeMappings(java.lang.String key, java.util.function.Function<RuntimeField.Builder,ObjectBuilder<RuntimeField>> fn)SetruntimeMappings(Map)to a singleton map. -
putRuntimeMappings
public SearchMvtRequest.Builder putRuntimeMappings(java.lang.String key, java.util.function.Function<RuntimeField.Builder,ObjectBuilder<RuntimeField>> fn)Add a key/value toruntimeMappings(Map), creating the map if needed. -
size
Maximum number of features to return in the hits layer. Accepts 0-10000. If 0, results don’t include the hits layer.API name:
size -
sort
Sorts features in the hits layer. By default, the API calculates a bounding box for each feature. It sorts features based on this box’s diagonal length, from longest to shortest.API name:
sort -
sort
Sorts features in the hits layer. By default, the API calculates a bounding box for each feature. It sorts features based on this box’s diagonal length, from longest to shortest.API name:
sort -
addSort
Add a value tosort(List), creating the list if needed. 4 -
build
Builds aSearchMvtRequest.- Specified by:
buildin interfaceObjectBuilder<SearchMvtRequest>- Throws:
java.lang.NullPointerException- if some of the required fields are null.
-