Struct skipping_search::MultiIntersection [−][src]
pub struct MultiIntersection<S> where
S: SkippingSearch, { /* fields omitted */ }
Combines an arbitrary number of SkippingSearch
objects, and returns only the items present in all of them.
Methods
impl<S> MultiIntersection<S> where
S: SkippingSearch,
[src]
impl<S> MultiIntersection<S> where
S: SkippingSearch,
pub fn new(sub_searches: Vec<S>) -> Self
[src]
pub fn new(sub_searches: Vec<S>) -> Self
Assembles a multi-intersection out of other SkippingSearch
objects.
Panics
Will panic if sub_searches.len() == 0
Trait Implementations
impl<S> SkippingSearch for MultiIntersection<S> where
S: SkippingSearch,
[src]
impl<S> SkippingSearch for MultiIntersection<S> where
S: SkippingSearch,
type Item = S::Item
fn suggest_next(&self) -> Option<Self::Item>
[src]
fn suggest_next(&self) -> Option<Self::Item>
Returns the smallest value for which find_and_advance
may return true. For efficiency reasons, making sure the value is one for which find_and_advance
will return true is preferred, when possible. Read more
fn find_and_advance(&mut self, item: &Self::Item) -> bool
[src]
fn find_and_advance(&mut self, item: &Self::Item) -> bool
Returns whether this contains the passed-in value. Also mutates the receiver to forget about any values smaller than or equal to the item. Read more
fn size_hint(&self) -> (usize, Option<usize>)
[src]
fn size_hint(&self) -> (usize, Option<usize>)
Returns a lower/upper bound on the number of values that can be obtained by using self.find_and_advance(self.suggest_next())
repeatedly. (0, None)
is a valid, minimally constraining answer. (n, Some(n))
is a maximally constraining answer. Read more
Auto Trait Implementations
impl<S> Send for MultiIntersection<S> where
S: Send,
impl<S> Send for MultiIntersection<S> where
S: Send,
impl<S> Sync for MultiIntersection<S> where
S: Sync,
impl<S> Sync for MultiIntersection<S> where
S: Sync,