Trait rin::prelude::StreamExt[][src]

pub trait StreamExt<'a, T>: WithInner<'a, T> {
Show methods pub fn unique(self) -> Stream<'a, T>;
pub fn rc(self) -> StreamRc<'a, T>
    where
        T: Clone
; pub fn on_value<'b, F>(self, f: F) -> Stream<'b, T>
    where
        'a: 'b,
        T: Clone + 'a,
        F: 'b + FnMut(T)
, { ... }
pub fn map<'b, T3, F>(self, f: F) -> Stream<'b, T3>
    where
        'a: 'b,
        T: 'a,
        F: FnMut(T) -> T3 + 'b,
        T3: 'b
, { ... }
pub fn filter<'b, F>(self, f: F) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(&T) -> bool
, { ... }
pub fn filter_by<'b, 'c>(self, p: Property<'b, bool>) -> Stream<'c, T>
    where
        'a: 'b,
        'b: 'c,
        T: 'a
, { ... }
pub fn partition<'b, F>(self, f: F) -> (Stream<'b, T>, Stream<'b, T>)
    where
        'a: 'b,
        T: 'a,
        F: FnMut(&T) -> bool + 'b
, { ... }
pub fn filter_map<'b, T3, F>(self, f: F) -> Stream<'b, T3>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(T) -> Option<T3>,
        T3: 'b
, { ... }
pub fn partition_map<'b, F, L, R>(
        self,
        f: F
    ) -> (Stream<'b, L>, Stream<'b, R>)
    where
        'a: 'b,
        L: 'b,
        T: 'a,
        F: FnMut(T) -> Either<L, R> + 'b,
        R: 'b
, { ... }
pub fn flat_map<'b, T3, F>(self, f: F) -> Stream<'b, T3>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(T) -> Stream<'b, T3>,
        T3: 'b + Clone
, { ... }
pub fn take<'b>(self, take: usize) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a
, { ... }
pub fn take_then<'b>(self, take: usize, then: T) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a
, { ... }
pub fn take_while<'b, F>(self, f: F) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(&T) -> bool
, { ... }
pub fn take_while_then<'b, F>(self, f: F, then: T) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(&T) -> bool
, { ... }
pub fn skip<'b>(self, skip: usize) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a
, { ... }
pub fn skip_while<'b, F>(self, f: F) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(&T) -> bool
, { ... }
pub fn fold<'b, T3, F>(self, initial: T3, f: F) -> Stream<'b, T3>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(T3, T) -> T3,
        T3: 'b + Clone
, { ... }
pub fn scan<'b, T2, T3, F>(self, initial: T2, f: F) -> Stream<'b, T3>
    where
        'a: 'b,
        T: 'a,
        F: 'b + FnMut(&mut T2, T) -> Option<T3>,
        T3: 'b,
        T2: 'b
, { ... }
pub fn dedup<'b>(self) -> Stream<'b, T>
    where
        'a: 'b,
        T: Clone + 'a + PartialEq<T>
, { ... }
pub fn dedup_by<'b, F, T2>(self, f: F) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a,
        F: Fn(&T) -> T2 + 'b,
        T2: PartialEq<T2> + 'b
, { ... }
pub fn dedup_or<'b>(self, or: Property<'b, bool>) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a + PartialEq<T> + Clone
, { ... }
pub fn delay<'b>(self, delay: usize) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a + PartialEq<T>
, { ... }
pub fn inspect<'b, F>(self, inspect: F) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'b,
        F: Fn(&T) + 'b
, { ... }
pub fn once<'b, T2>(self, once: T2) -> Stream<'b, T2>
    where
        'a: 'b,
        T: 'a,
        T2: 'b
, { ... }
pub fn merge<'b, 'c, S>(self, other: S) -> Stream<'c, T>
    where
        'a: 'c,
        'b: 'c,
        T: Clone + 'c,
        S: StreamExt<'b, T>
, { ... }
pub fn throttle<'c>(self, fps: f32) -> Stream<'c, T>
    where
        'a: 'c,
        T: 'a
, { ... }
pub fn benchmark<'b, 'c, F, S>(
        self,
        frame_stream: S
    ) -> (Stream<'c, T>, Stream<'c, Duration>)
    where
        'a: 'c,
        'b: 'c,
        T: Clone + 'a,
        F: 'b,
        S: StreamExt<'b, F>
, { ... }
pub fn bandpass<'b>(self, alpha: T) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a + Zero<Output = T> + One<Output = T> + Sub<T, Output = T> + Add<T> + Mul<T> + Clone
, { ... }
pub fn resolution<'b>(self, resolution: u8) -> Stream<'b, T>
    where
        'a: 'b,
        T: 'a + Div<T, Output = T> + Mul<T, Output = T> + Float
, { ... }
pub fn to_bool<'b>(self) -> Stream<'b, bool>
    where
        'a: 'b,
        T: 'a
, { ... }
pub fn until<'b, 'c, T2, S>(self, until: S) -> Stream<'c, bool>
    where
        'a: 'c,
        'b: 'c,
        T: 'a,
        S: StreamExt<'b, T2>,
        T2: 'b
, { ... }
pub fn try_iter<'b>(self) -> TryIter<'b, T>

Notable traits for TryIter<'a, T>

impl<'a, T> Iterator for TryIter<'a, T> type Item = T;

    where
        'a: 'b,
        Self: 'a,
        T: 'a
, { ... }
pub fn to_parameter(self, initial: T) -> Parameter<'a, T>
    where
        Self: 'a,
        T: 'a
, { ... }
pub fn try_iter_last_frame<'b, S>(
        self,
        last_frame: S
    ) -> TryIterLastFrame<'b, T>

Notable traits for TryIterLastFrame<'a, T>

impl<'a, T> Iterator for TryIterLastFrame<'a, T> type Item = T;

    where
        'a: 'b,
        Self: 'a,
        T: 'a,
        S: StreamExt<'a, ()> + 'a
, { ... }
pub fn to_box(self) -> Box<dyn StreamExt<'a, T> + 'a, Global>
    where
        Self: 'a
, { ... }
pub fn to_property(self, initial: T) -> Property<'a, T>
    where
        Self: Into<StreamRc<'a, T>>,
        T: Clone + 'a
, { ... }
pub fn to_property_last_value(self, initial: T) -> PropertyLastValue<'a, T>
    where
        Self: Into<StreamRc<'a, T>>,
        T: Clone + 'a
, { ... }
pub fn collect<'b>(self, samples: usize) -> Property<'b, Vec<T, Global>>
    where
        'a: 'b,
        T: Clone + 'a
, { ... }
}

Required methods

pub fn unique(self) -> Stream<'a, T>[src]

pub fn rc(self) -> StreamRc<'a, T> where
    T: Clone
[src]

Loading content...

Provided methods

pub fn on_value<'b, F>(self, f: F) -> Stream<'b, T> where
    'a: 'b,
    T: Clone + 'a,
    F: 'b + FnMut(T), 
[src]

pub fn map<'b, T3, F>(self, f: F) -> Stream<'b, T3> where
    'a: 'b,
    T: 'a,
    F: FnMut(T) -> T3 + 'b,
    T3: 'b, 
[src]

pub fn filter<'b, F>(self, f: F) -> Stream<'b, T> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(&T) -> bool
[src]

pub fn filter_by<'b, 'c>(self, p: Property<'b, bool>) -> Stream<'c, T> where
    'a: 'b,
    'b: 'c,
    T: 'a, 
[src]

pub fn partition<'b, F>(self, f: F) -> (Stream<'b, T>, Stream<'b, T>) where
    'a: 'b,
    T: 'a,
    F: FnMut(&T) -> bool + 'b, 
[src]

pub fn filter_map<'b, T3, F>(self, f: F) -> Stream<'b, T3> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(T) -> Option<T3>,
    T3: 'b, 
[src]

pub fn partition_map<'b, F, L, R>(self, f: F) -> (Stream<'b, L>, Stream<'b, R>) where
    'a: 'b,
    L: 'b,
    T: 'a,
    F: FnMut(T) -> Either<L, R> + 'b,
    R: 'b, 
[src]

pub fn flat_map<'b, T3, F>(self, f: F) -> Stream<'b, T3> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(T) -> Stream<'b, T3>,
    T3: 'b + Clone
[src]

pub fn take<'b>(self, take: usize) -> Stream<'b, T> where
    'a: 'b,
    T: 'a, 
[src]

pub fn take_then<'b>(self, take: usize, then: T) -> Stream<'b, T> where
    'a: 'b,
    T: 'a, 
[src]

pub fn take_while<'b, F>(self, f: F) -> Stream<'b, T> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(&T) -> bool
[src]

pub fn take_while_then<'b, F>(self, f: F, then: T) -> Stream<'b, T> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(&T) -> bool
[src]

pub fn skip<'b>(self, skip: usize) -> Stream<'b, T> where
    'a: 'b,
    T: 'a, 
[src]

pub fn skip_while<'b, F>(self, f: F) -> Stream<'b, T> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(&T) -> bool
[src]

pub fn fold<'b, T3, F>(self, initial: T3, f: F) -> Stream<'b, T3> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(T3, T) -> T3,
    T3: 'b + Clone
[src]

pub fn scan<'b, T2, T3, F>(self, initial: T2, f: F) -> Stream<'b, T3> where
    'a: 'b,
    T: 'a,
    F: 'b + FnMut(&mut T2, T) -> Option<T3>,
    T3: 'b,
    T2: 'b, 
[src]

pub fn dedup<'b>(self) -> Stream<'b, T> where
    'a: 'b,
    T: Clone + 'a + PartialEq<T>, 
[src]

pub fn dedup_by<'b, F, T2>(self, f: F) -> Stream<'b, T> where
    'a: 'b,
    T: 'a,
    F: Fn(&T) -> T2 + 'b,
    T2: PartialEq<T2> + 'b, 
[src]

pub fn dedup_or<'b>(self, or: Property<'b, bool>) -> Stream<'b, T> where
    'a: 'b,
    T: 'a + PartialEq<T> + Clone
[src]

pub fn delay<'b>(self, delay: usize) -> Stream<'b, T> where
    'a: 'b,
    T: 'a + PartialEq<T>, 
[src]

pub fn inspect<'b, F>(self, inspect: F) -> Stream<'b, T> where
    'a: 'b,
    T: 'b,
    F: Fn(&T) + 'b, 
[src]

pub fn once<'b, T2>(self, once: T2) -> Stream<'b, T2> where
    'a: 'b,
    T: 'a,
    T2: 'b, 
[src]

pub fn merge<'b, 'c, S>(self, other: S) -> Stream<'c, T> where
    'a: 'c,
    'b: 'c,
    T: Clone + 'c,
    S: StreamExt<'b, T>, 
[src]

pub fn throttle<'c>(self, fps: f32) -> Stream<'c, T> where
    'a: 'c,
    T: 'a, 
[src]

pub fn benchmark<'b, 'c, F, S>(
    self,
    frame_stream: S
) -> (Stream<'c, T>, Stream<'c, Duration>) where
    'a: 'c,
    'b: 'c,
    T: Clone + 'a,
    F: 'b,
    S: StreamExt<'b, F>, 
[src]

pub fn bandpass<'b>(self, alpha: T) -> Stream<'b, T> where
    'a: 'b,
    T: 'a + Zero<Output = T> + One<Output = T> + Sub<T, Output = T> + Add<T> + Mul<T> + Clone
[src]

pub fn resolution<'b>(self, resolution: u8) -> Stream<'b, T> where
    'a: 'b,
    T: 'a + Div<T, Output = T> + Mul<T, Output = T> + Float
[src]

pub fn to_bool<'b>(self) -> Stream<'b, bool> where
    'a: 'b,
    T: 'a, 
[src]

pub fn until<'b, 'c, T2, S>(self, until: S) -> Stream<'c, bool> where
    'a: 'c,
    'b: 'c,
    T: 'a,
    S: StreamExt<'b, T2>,
    T2: 'b, 
[src]

pub fn try_iter<'b>(self) -> TryIter<'b, T>

Notable traits for TryIter<'a, T>

impl<'a, T> Iterator for TryIter<'a, T> type Item = T;
where
    'a: 'b,
    Self: 'a,
    T: 'a, 
[src]

pub fn to_parameter(self, initial: T) -> Parameter<'a, T> where
    Self: 'a,
    T: 'a, 
[src]

pub fn try_iter_last_frame<'b, S>(
    self,
    last_frame: S
) -> TryIterLastFrame<'b, T>

Notable traits for TryIterLastFrame<'a, T>

impl<'a, T> Iterator for TryIterLastFrame<'a, T> type Item = T;
where
    'a: 'b,
    Self: 'a,
    T: 'a,
    S: StreamExt<'a, ()> + 'a, 
[src]

pub fn to_box(self) -> Box<dyn StreamExt<'a, T> + 'a, Global> where
    Self: 'a, 
[src]

pub fn to_property(self, initial: T) -> Property<'a, T> where
    Self: Into<StreamRc<'a, T>>,
    T: Clone + 'a, 
[src]

pub fn to_property_last_value(self, initial: T) -> PropertyLastValue<'a, T> where
    Self: Into<StreamRc<'a, T>>,
    T: Clone + 'a, 
[src]

pub fn collect<'b>(self, samples: usize) -> Property<'b, Vec<T, Global>> where
    'a: 'b,
    T: Clone + 'a, 
[src]

Loading content...

Implementations on Foreign Types

impl<'a, 'b, T, S> StreamExt<'b, T> for &'b S where
    'a: 'b,
    T: 'b + Clone,
    S: WithInner<'a, T> + StreamInner<'a, T>, 
[src]

Loading content...

Implementors

impl<'a, T2> StreamExt<'a, T2> for Stream<'a, T2> where
    T2: 'a, 
[src]

impl<'a, T> StreamExt<'a, T> for StreamRc<'a, T> where
    T: 'a, 
[src]

Loading content...