pub struct ShapeLookupQuery { /* private fields */ }
Expand description
Queries documents that contain fields indexed using the shape
type.
Requires the shape
Mapping.
https://www.elastic.co/guide/en/elasticsearch/reference/current/query-dsl-shape-query.html
Implementations§
Source§impl ShapeLookupQuery
impl ShapeLookupQuery
pub fn serialize<__S>(
__self: &ShapeLookupQuery,
__serializer: __S,
) -> Result<__S::Ok, __S::Error>where
__S: Serializer,
Source§impl ShapeLookupQuery
impl ShapeLookupQuery
Sourcepub fn index<S>(self, index: S) -> Selfwhere
S: ToString,
pub fn index<S>(self, index: S) -> Selfwhere
S: ToString,
Name of the index where the pre-indexed shape is. Defaults to shapes
Sourcepub fn path<S>(self, path: S) -> Selfwhere
S: ToString,
pub fn path<S>(self, path: S) -> Selfwhere
S: ToString,
The field specified as path containing the pre-indexed shape. Defaults to shape
Sourcepub fn routing<S>(self, routing: S) -> Selfwhere
S: ToString,
pub fn routing<S>(self, routing: S) -> Selfwhere
S: ToString,
The routing of the shape document
Sourcepub fn relation(self, relation: SpatialRelation) -> Self
pub fn relation(self, relation: SpatialRelation) -> Self
The 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<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 ShapeLookupQuery
impl Clone for ShapeLookupQuery
Source§fn clone(&self) -> ShapeLookupQuery
fn clone(&self) -> ShapeLookupQuery
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read more