pub struct NestedQuery<E = Root> { /* private fields */ }Expand description
A nested clause (parents with a matching element), with the score_mode /
ignore_unmapped options plus boost / name. E is the enclosing scope.
Implementations§
Source§impl<E> NestedQuery<E>
impl<E> NestedQuery<E>
Sourcepub fn score_mode(self, score_mode: NestedScoreMode) -> Self
pub fn score_mode(self, score_mode: NestedScoreMode) -> Self
How matching elements’ scores combine into the parent score
(NestedScoreMode::Avg is the default; NestedScoreMode::None
makes the clause a pure filter).
Sourcepub fn ignore_unmapped(self, ignore_unmapped: bool) -> Self
pub fn ignore_unmapped(self, ignore_unmapped: bool) -> Self
Treat an unmapped path as matching nothing instead of erroring.
Trait Implementations§
Source§impl<E> AsQuery<E> for NestedQuery<E>
impl<E> AsQuery<E> for NestedQuery<E>
Source§fn into_query(self) -> Option<Query<E>>
fn into_query(self) -> Option<Query<E>>
The clause this produces, or
None to contribute nothing.Source§fn and(self, other: impl AsQuery<S>) -> Query<S>where
Self: Sized,
fn and(self, other: impl AsQuery<S>) -> Query<S>where
Self: Sized,
self AND other. An absent side is the identity.Source§fn or(self, other: impl AsQuery<S>) -> Query<S>where
Self: Sized,
fn or(self, other: impl AsQuery<S>) -> Query<S>where
Self: Sized,
self OR other. An absent side is the identity.Source§impl<E: Clone> Clone for NestedQuery<E>
impl<E: Clone> Clone for NestedQuery<E>
Source§fn clone(&self) -> NestedQuery<E>
fn clone(&self) -> NestedQuery<E>
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl<E> Freeze for NestedQuery<E>
impl<E> RefUnwindSafe for NestedQuery<E>
impl<E> Send for NestedQuery<E>
impl<E> Sync for NestedQuery<E>
impl<E> Unpin for NestedQuery<E>
impl<E> UnsafeUnpin for NestedQuery<E>
impl<E> UnwindSafe for NestedQuery<E>
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