pub struct ThreadId { /* private fields */ }Expand description
A unique identifier for a running thread.
A ThreadId is an opaque object that uniquely identifies each thread
created during the lifetime of a process. ThreadIds are guaranteed not to
be reused, even when a thread terminates. ThreadIds are under the control
of Rust’s standard library and there may not be any relationship between
ThreadId and the underlying platform’s notion of a thread identifier –
the two concepts cannot, therefore, be used interchangeably. A ThreadId
can be retrieved from the [id] method on a Thread.
Trait Implementations§
impl Copy for ThreadId
impl Eq for ThreadId
impl StructuralPartialEq for ThreadId
Auto Trait Implementations§
impl Freeze for ThreadId
impl RefUnwindSafe for ThreadId
impl Send for ThreadId
impl Sync for ThreadId
impl Unpin for ThreadId
impl UnwindSafe for ThreadId
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