RelIter

Struct RelIter 

Source
pub struct RelIter<I> {
    pub iter: I,
}
Expand description

Turns an iterator over RelValue<'_>s into a RelOps.

Fields§

§iter: I

Implementations§

Source§

impl<I> RelIter<I>

Source

pub fn new(iter: impl IntoIterator<IntoIter = I>) -> Self

Trait Implementations§

Source§

impl<I: Debug> Debug for RelIter<I>

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl<'a, I: Iterator<Item = RelValue<'a>>> RelOps<'a> for RelIter<I>

Source§

fn next(&mut self) -> Option<RelValue<'a>>

Advances the iterator and returns the next RelValue.
Source§

fn select<P>(self, predicate: P) -> Select<Self, P>
where P: FnMut(&RelValue<'_>) -> bool, Self: Sized,

Creates an Iterator which uses a closure to determine if a [RelValueRef] should be yielded. Read more
Source§

fn project<'b, P>( self, cols: &'b [ColExpr], extractor: P, ) -> Project<'b, Self, P>
where P: for<'c> FnMut(&[ColExpr], RelValue<'c>) -> RelValue<'c>, Self: Sized,

Creates an Iterator which uses a closure that projects to a new RelValue extracted from the current. Read more
Source§

fn join_inner<Pred, Proj, KeyLhs, KeyRhs, Rhs>( self, with: Rhs, key_lhs: KeyLhs, key_rhs: KeyRhs, predicate: Pred, project: Proj, ) -> JoinInner<'a, Self, Rhs, KeyLhs, KeyRhs, Pred, Proj>
where Self: Sized, Pred: FnMut(&RelValue<'a>, &RelValue<'a>) -> bool, Proj: FnMut(RelValue<'a>, RelValue<'a>) -> RelValue<'a>, KeyLhs: FnMut(&RelValue<'a>) -> AlgebraicValue, KeyRhs: FnMut(&RelValue<'a>) -> AlgebraicValue, Rhs: RelOps<'a>,

Intersection between the left and the right, both (non-sorted) iterators. Read more
Source§

fn collect_vec<T>(self, convert: impl FnMut(RelValue<'a>) -> T) -> Vec<T>
where Self: Sized,

Collect all the rows in this relation into a Vec<T> given a function RelValue<'a> -> T.
Source§

fn iter(&mut self) -> impl Iterator<Item = RelValue<'a>>
where Self: Sized,

Auto Trait Implementations§

§

impl<I> Freeze for RelIter<I>
where I: Freeze,

§

impl<I> RefUnwindSafe for RelIter<I>
where I: RefUnwindSafe,

§

impl<I> Send for RelIter<I>
where I: Send,

§

impl<I> Sync for RelIter<I>
where I: Sync,

§

impl<I> Unpin for RelIter<I>
where I: Unpin,

§

impl<I> UnwindSafe for RelIter<I>
where I: UnwindSafe,

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> Same for T

Source§

type Output = T

Should always be Self
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.