pub struct JoinHandle<T> { /* private fields */ }Expand description
Join handle for spawned tasks 生成任务的join句柄
Allows awaiting task completion and retrieving the result. 允许等待任务完成并检索结果。
Implementations§
Source§impl<T> JoinHandle<T>
impl<T> JoinHandle<T>
Sourcepub fn is_finished(&self) -> bool
pub fn is_finished(&self) -> bool
Check if the task has finished (completed, cancelled, or panicked). 检查任务是否已完成(成功完成、已取消或发生panic)。
Auto Trait Implementations§
impl<T> !RefUnwindSafe for JoinHandle<T>
impl<T> !UnwindSafe for JoinHandle<T>
impl<T> Freeze for JoinHandle<T>
impl<T> Send for JoinHandle<T>where
T: Send,
impl<T> Sync for JoinHandle<T>where
T: Send,
impl<T> Unpin for JoinHandle<T>
impl<T> UnsafeUnpin for JoinHandle<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