Struct FilterAnti

Source
pub struct FilterAnti<'leap, Key, Val, Tuple, Func>
where Key: Ord + 'leap, Val: Ord + 'leap, Tuple: Ord, Func: Fn(&Tuple) -> (Key, Val),
{ /* private fields */ }
Expand description

Wraps a Relation as a leaper.

Implementations§

Source§

impl<'leap, Key, Val, Tuple, Func> FilterAnti<'leap, Key, Val, Tuple, Func>
where Key: Ord + 'leap, Val: Ord + 'leap, Tuple: Ord, Func: Fn(&Tuple) -> (Key, Val),

Source

pub fn from(relation: &'leap Relation<(Key, Val)>, key_func: Func) -> Self

Constructs a FilterAnti from a relation and key and value function.

Trait Implementations§

Source§

impl<'leap, Key, Val, Val2, Tuple, Func> Leaper<'leap, Tuple, Val2> for FilterAnti<'leap, Key, Val, Tuple, Func>
where Key: Ord + 'leap, Val: Ord + 'leap, Tuple: Ord, Func: Fn(&Tuple) -> (Key, Val),

Source§

fn count(&mut self, prefix: &Tuple) -> usize

Estimates the number of proposed values.
Source§

fn propose(&mut self, _prefix: &Tuple, _values: &mut Vec<&'leap Val2>)

Populates values with proposed values.
Source§

fn intersect(&mut self, _prefix: &Tuple, _values: &mut Vec<&'leap Val2>)

Restricts values to proposed values.
Source§

impl<'leap, Key, Val, Tuple, Func> Leapers<'leap, Tuple, ()> for FilterAnti<'leap, Key, Val, Tuple, Func>
where Key: Ord + 'leap, Val: Ord + 'leap, Tuple: Ord, Func: Fn(&Tuple) -> (Key, Val),

Source§

fn for_each_count(&mut self, tuple: &Tuple, op: impl FnMut(usize, usize))

Internal method:
Source§

fn propose(&mut self, _: &Tuple, min_index: usize, values: &mut Vec<&'leap ()>)

Internal method:
Source§

fn intersect( &mut self, _: &Tuple, min_index: usize, values: &mut Vec<&'leap ()>, )

Internal method:

Auto Trait Implementations§

§

impl<'leap, Key, Val, Tuple, Func> Freeze for FilterAnti<'leap, Key, Val, Tuple, Func>
where Func: Freeze,

§

impl<'leap, Key, Val, Tuple, Func> RefUnwindSafe for FilterAnti<'leap, Key, Val, Tuple, Func>
where Func: RefUnwindSafe, Tuple: RefUnwindSafe, Key: RefUnwindSafe, Val: RefUnwindSafe,

§

impl<'leap, Key, Val, Tuple, Func> Send for FilterAnti<'leap, Key, Val, Tuple, Func>
where Func: Send, Tuple: Send, Key: Sync, Val: Sync,

§

impl<'leap, Key, Val, Tuple, Func> Sync for FilterAnti<'leap, Key, Val, Tuple, Func>
where Func: Sync, Tuple: Sync, Key: Sync, Val: Sync,

§

impl<'leap, Key, Val, Tuple, Func> Unpin for FilterAnti<'leap, Key, Val, Tuple, Func>
where Func: Unpin, Tuple: Unpin,

§

impl<'leap, Key, Val, Tuple, Func> UnwindSafe for FilterAnti<'leap, Key, Val, Tuple, Func>
where Func: UnwindSafe, Tuple: UnwindSafe, Key: RefUnwindSafe, Val: RefUnwindSafe,

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, 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.