pub trait Skip<T>where
T: ObservableType,{
// Required method
fn skip(&mut self, n: usize) -> Pipe<T>;
}Required Methods§
Sourcefn skip(&mut self, n: usize) -> Pipe<T>
fn skip(&mut self, n: usize) -> Pipe<T>
Attaches a skip operator to the end of the chain and forwards the pipe
skip is used to skip the first n events observed.
§Example
use drumbeat::event::observable::Observable;
use drumbeat::event::ops::*;
let rx = Observable::of(vec![1, 2, 3])
.pipe()
.skip(2)
.collect();
assert_eq!(rx.recv().unwrap(), [3]);