Struct elasticsearch_dsl::search::queries::geo::GeoShapeQuery
source · [−]pub struct GeoShapeQuery { /* private fields */ }
Expand description
Filter documents indexed using the geo_shape
or geo_point
type.
Requires the
geo_shape
mapping
or the
geo_point
mapping.
The geo_shape
query uses the same grid square representation as the
geo_shape
mapping to find documents that have a shape that intersects
with the query shape. It will also use the same Prefix Tree configuration
as defined for the field mapping.
https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-geo-shape-query.html
Implementations
sourceimpl GeoShapeQuery
impl GeoShapeQuery
sourcepub fn relation(self, relation: SpatialRelation) -> Self
pub fn relation(self, relation: SpatialRelation) -> Self
The geo_shape strategy mapping parameter determines which spatial relation operators may be used at search time.
sourcepub fn ignore_unmapped(self, ignore_unmapped: bool) -> Self
pub fn ignore_unmapped(self, ignore_unmapped: bool) -> Self
When set to true the ignore_unmapped
option will ignore an unmapped
field and will not match any documents for this query. This can be
useful when querying multiple indexes which might have different
mappings. When set to false
(the default value) the query will throw
an exception if the field is not mapped.
sourcepub fn boost<B>(self, boost: B) -> Self where
B: TryInto<Boost>,
pub fn boost<B>(self, boost: B) -> Self where
B: TryInto<Boost>,
Floating point number used to decrease or increase the
relevance scores
of a query. Defaults to 1.0
.
You can use the boost parameter to adjust relevance scores for searches containing two or more queries.
Boost values are relative to the default value of 1.0
.
A boost value between 0 and 1.0
decreases the relevance score.
A value greater than 1.0
increases the relevance score.
Trait Implementations
sourceimpl Clone for GeoShapeQuery
impl Clone for GeoShapeQuery
sourcefn clone(&self) -> GeoShapeQuery
fn clone(&self) -> GeoShapeQuery
Returns a copy of the value. Read more
1.0.0 · sourcefn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from source
. Read more
sourceimpl Debug for GeoShapeQuery
impl Debug for GeoShapeQuery
sourceimpl From<GeoShapeQuery> for Query
impl From<GeoShapeQuery> for Query
sourcefn from(q: GeoShapeQuery) -> Self
fn from(q: GeoShapeQuery) -> Self
Converts to this type from the input type.
sourceimpl From<GeoShapeQuery> for Option<Query>
impl From<GeoShapeQuery> for Option<Query>
sourcefn from(q: GeoShapeQuery) -> Self
fn from(q: GeoShapeQuery) -> Self
Converts to this type from the input type.
sourceimpl From<GeoShapeQuery> for Queries
impl From<GeoShapeQuery> for Queries
sourcefn from(q: GeoShapeQuery) -> Self
fn from(q: GeoShapeQuery) -> Self
Converts to this type from the input type.
sourceimpl PartialEq<GeoShapeQuery> for GeoShapeQuery
impl PartialEq<GeoShapeQuery> for GeoShapeQuery
sourcefn eq(&self, other: &GeoShapeQuery) -> bool
fn eq(&self, other: &GeoShapeQuery) -> bool
This method tests for self
and other
values to be equal, and is used
by ==
. Read more
sourcefn ne(&self, other: &GeoShapeQuery) -> bool
fn ne(&self, other: &GeoShapeQuery) -> bool
This method tests for !=
.
sourceimpl PartialEq<GeoShapeQuery> for Query
impl PartialEq<GeoShapeQuery> for Query
sourceimpl PartialEq<Query> for GeoShapeQuery
impl PartialEq<Query> for GeoShapeQuery
sourceimpl Serialize for GeoShapeQuery
impl Serialize for GeoShapeQuery
impl StructuralPartialEq for GeoShapeQuery
Auto Trait Implementations
impl RefUnwindSafe for GeoShapeQuery
impl Send for GeoShapeQuery
impl Sync for GeoShapeQuery
impl Unpin for GeoShapeQuery
impl UnwindSafe for GeoShapeQuery
Blanket Implementations
sourceimpl<T> BorrowMut<T> for T where
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more