pub struct SmartHandle<T> { /* private fields */ }
Expand description
A thread handle that knows when the thread is finished executing
Implementations§
Source§impl<T> SmartHandle<T>
impl<T> SmartHandle<T>
Sourcepub fn join(self) -> Result<T>
pub fn join(self) -> Result<T>
Join the thread.
Analgous to JoinHandle::join
Sourcepub fn status(&self) -> ThreadStatus
pub fn status(&self) -> ThreadStatus
Check if the thread is finished executing
Sourcepub fn into_inner(self) -> JoinHandle<Result<T>>
pub fn into_inner(self) -> JoinHandle<Result<T>>
Consume this handle and get the inner JoinHandle
Auto Trait Implementations§
impl<T> Freeze for SmartHandle<T>
impl<T> !RefUnwindSafe for SmartHandle<T>
impl<T> Send for SmartHandle<T>
impl<T> Sync for SmartHandle<T>
impl<T> Unpin for SmartHandle<T>
impl<T> !UnwindSafe for SmartHandle<T>
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