Struct elasticsearch_dsl::search::queries::geo::GeoDistanceQuery
source · pub struct GeoDistanceQuery { /* private fields */ }
Expand description
Matches geo_point and geo_shape values within a given distance of a geopoint.
https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-geo-distance-query.html
Implementations§
source§impl GeoDistanceQuery
impl GeoDistanceQuery
pub fn serialize<__S>(
__self: &GeoDistanceQuery,
__serializer: __S
) -> Result<__S::Ok, __S::Error>where
__S: Serializer,
source§impl GeoDistanceQuery
impl GeoDistanceQuery
sourcepub fn validation_method(self, validation_method: ValidationMethod) -> Self
pub fn validation_method(self, validation_method: ValidationMethod) -> Self
Set to IGNORE_MALFORMED
to accept geo points with invalid latitude or longitude, set to
COERCE
to also try to infer correct latitude or longitude. (default is STRICT
).
sourcepub fn distance_type(self, distance_type: GeoDistanceType) -> Self
pub fn distance_type(self, distance_type: GeoDistanceType) -> Self
sourcepub fn boost<T>(self, boost: T) -> Selfwhere
T: AsPrimitive<f32>,
pub fn boost<T>(self, boost: T) -> Selfwhere
T: AsPrimitive<f32>,
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§
source§impl Clone for GeoDistanceQuery
impl Clone for GeoDistanceQuery
source§fn clone(&self) -> GeoDistanceQuery
fn clone(&self) -> GeoDistanceQuery
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for GeoDistanceQuery
impl Debug for GeoDistanceQuery
source§impl From<GeoDistanceQuery> for Option<Query>
impl From<GeoDistanceQuery> for Option<Query>
source§fn from(q: GeoDistanceQuery) -> Self
fn from(q: GeoDistanceQuery) -> Self
Converts to this type from the input type.
source§impl From<GeoDistanceQuery> for Query
impl From<GeoDistanceQuery> for Query
source§fn from(q: GeoDistanceQuery) -> Self
fn from(q: GeoDistanceQuery) -> Self
Converts to this type from the input type.
source§impl IntoIterator for GeoDistanceQuery
impl IntoIterator for GeoDistanceQuery
§type Item = GeoDistanceQuery
type Item = GeoDistanceQuery
The type of the elements being iterated over.
§type IntoIter = IntoIter<<GeoDistanceQuery as IntoIterator>::Item>
type IntoIter = IntoIter<<GeoDistanceQuery as IntoIterator>::Item>
Which kind of iterator are we turning this into?
source§impl PartialEq<GeoDistanceQuery> for Query
impl PartialEq<GeoDistanceQuery> for Query
source§fn eq(&self, other: &GeoDistanceQuery) -> bool
fn eq(&self, other: &GeoDistanceQuery) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialEq<Query> for GeoDistanceQuery
impl PartialEq<Query> for GeoDistanceQuery
source§impl PartialEq for GeoDistanceQuery
impl PartialEq for GeoDistanceQuery
source§fn eq(&self, other: &GeoDistanceQuery) -> bool
fn eq(&self, other: &GeoDistanceQuery) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for GeoDistanceQuery
impl Serialize for GeoDistanceQuery
impl StructuralPartialEq for GeoDistanceQuery
Auto Trait Implementations§
impl RefUnwindSafe for GeoDistanceQuery
impl Send for GeoDistanceQuery
impl Sync for GeoDistanceQuery
impl Unpin for GeoDistanceQuery
impl UnwindSafe for GeoDistanceQuery
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more