Struct avr_oxide::concurrency::util::ThreadSet
source · #[repr(C)]pub struct ThreadSet { /* private fields */ }
Implementations§
source§impl ThreadSet
impl ThreadSet
pub fn new() -> Self
pub fn add_thread(&mut self, isotoken: Isolated, id: ThreadId)
pub fn add_current_thread(&mut self, isotoken: Isolated)
pub fn remove_thread(&mut self, isotoken: Isolated, id: ThreadId)
pub fn remove_current_thread(&mut self, isotoken: Isolated)
pub fn contains_thread(&self, _isotoken: Isolated, id: ThreadId) -> bool
pub fn contains_current_thread(&self, isotoken: Isolated) -> bool
pub fn remove_all(&mut self)
sourcepub fn do_each<F>(&self, isotoken: Isolated, f: F)
pub fn do_each<F>(&self, isotoken: Isolated, f: F)
Execute the given closure for each thread in this threadset.
The closure should return a boolean indicating if it should continue iterating through the threads.
sourcepub fn do_each_consuming<F>(&mut self, isotoken: Isolated, f: F)
pub fn do_each_consuming<F>(&mut self, isotoken: Isolated, f: F)
Execute the given closure for each thread in this threadset. The thread is removed from the threadset following execution of the closure.
The closure should return a boolean indicating if it should continue iterating through the threads.
Auto Trait Implementations§
impl Freeze for ThreadSet
impl RefUnwindSafe for ThreadSet
impl Send for ThreadSet
impl Sync for ThreadSet
impl Unpin for ThreadSet
impl UnwindSafe for ThreadSet
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more