pub struct CustomSpawn<B>(/* private fields */);
Expand description
CustomSpawn
is an alternative implementation of ThreadSpawn
that uses a user-supplied closure
for custom thread configuration.
This allows for fine-grained control over thread properties, enabling application-specific setups.
Implementations§
Source§impl<B> CustomSpawn<B>
impl<B> CustomSpawn<B>
Sourcepub fn new(spawn_handler: B) -> Self
pub fn new(spawn_handler: B) -> Self
Creates a new instance of CustomSpawn
with the specified configuration closure.
Trait Implementations§
Source§impl<B: Clone> Clone for CustomSpawn<B>
impl<B: Clone> Clone for CustomSpawn<B>
Source§fn clone(&self) -> CustomSpawn<B>
fn clone(&self) -> CustomSpawn<B>
Returns a copy of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreAuto Trait Implementations§
impl<B> Freeze for CustomSpawn<B>where
B: Freeze,
impl<B> RefUnwindSafe for CustomSpawn<B>where
B: RefUnwindSafe,
impl<B> Send for CustomSpawn<B>where
B: Send,
impl<B> Sync for CustomSpawn<B>where
B: Sync,
impl<B> Unpin for CustomSpawn<B>where
B: Unpin,
impl<B> UnwindSafe for CustomSpawn<B>where
B: UnwindSafe,
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