pub struct SubqueryNormalizer;Expand description
Flattens doubly-nested Select subqueries.
A doubly-nested subquery is:
SELECT … WHERE {
{
SELECT … WHERE {
{
SELECT … WHERE { … } ← this innermost is merged up
}
}
}
}The normalizer merges the innermost Select into its parent when the
parent has no patterns or filters of its own and the vars are compatible.
Implementations§
Source§impl SubqueryNormalizer
impl SubqueryNormalizer
Sourcepub fn normalize(&self, node: SubqueryNode) -> SubqueryNode
pub fn normalize(&self, node: SubqueryNode) -> SubqueryNode
Normalize node, returning an equivalent (possibly simplified) SubqueryNode.
Trait Implementations§
Auto Trait Implementations§
impl Freeze for SubqueryNormalizer
impl RefUnwindSafe for SubqueryNormalizer
impl Send for SubqueryNormalizer
impl Sync for SubqueryNormalizer
impl Unpin for SubqueryNormalizer
impl UnsafeUnpin for SubqueryNormalizer
impl UnwindSafe for SubqueryNormalizer
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
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more