pub fn all<F>(&mut self, filter: F) -> Vec<Event>
    where
        F: Fn(&Event) -> bool,
    {
        let mut events = Vec::new();
        while let Ok(event) = self.receiver.try_recv() {
            if filter(&event) {
                events.push(event);
            }
        }
        events
    }
/// Returns the received events without waiting for any more.
Returns the received events without waiting for any more.
Returns the received events without waiting for any more .
pub fn all<F>(&mut self, filter: F) -> Vec<Event>
    where
        F: Fn(&Event) -> bool,
    {
        let mut events = Vec::new();
        while let Ok(event) = self.receiver.try_recv() {
            if filter(&event) {
                events.push(event);
            }
        }
        events
    }
pub fn all < F > ( & mut self , filter : F ) -> Vec < Event > where F : Fn ( & Event ) -> bool , { let mut events = Vec :: new ( ) ; while let Ok ( event ) = self . receiver . try_recv ( ) { if filter ( & event ) { events . push ( event ) ; } } events }
Returns the received events without waiting for any more.
Returns the received events without waiting for any more .
&mut self
filter
F
&mut self
filter
F