Struct open_coroutine_core::scheduler::join::JoinHandleImpl
source · #[repr(C)]pub struct JoinHandleImpl<'j>(/* private fields */);
Trait Implementations§
source§impl<'j> Debug for JoinHandleImpl<'j>
impl<'j> Debug for JoinHandleImpl<'j>
source§impl<'j> JoinHandle<SchedulerImpl<'j>> for JoinHandleImpl<'j>
impl<'j> JoinHandle<SchedulerImpl<'j>> for JoinHandleImpl<'j>
source§impl<'s> Scheduler<'s, JoinHandleImpl<'s>> for SchedulerImpl<'s>
impl<'s> Scheduler<'s, JoinHandleImpl<'s>> for SchedulerImpl<'s>
source§fn get_stack_size(&self) -> usize
fn get_stack_size(&self) -> usize
Get the default stack stack size for the coroutines in this scheduler.
If it has not been set, it will be
crate::constant::DEFAULT_STACK_SIZE
.source§fn set_stack_size(&self, stack_size: usize)
fn set_stack_size(&self, stack_size: usize)
Set the default stack stack size for the coroutines in this scheduler.
If it has not been set, it will be
crate::constant::DEFAULT_STACK_SIZE
.source§fn submit_raw_co(&self, coroutine: SchedulableCoroutine<'static>) -> Result<()>
fn submit_raw_co(&self, coroutine: SchedulableCoroutine<'static>) -> Result<()>
Submit a closure to create new coroutine, then the coroutine will be push into ready queue. Read more
source§fn try_resume(&self, co_name: &str) -> Result<()>
fn try_resume(&self, co_name: &str) -> Result<()>
Resume a coroutine from the system call table to the ready queue,
it’s generally only required for framework level crates. Read more
source§fn try_timeout_schedule(&self, timeout_time: u64) -> Result<u64>
fn try_timeout_schedule(&self, timeout_time: u64) -> Result<u64>
Attempt to schedule the coroutines before the
timeout_time
timestamp. Read moresource§fn try_get_co_result(
&self,
co_name: &str
) -> Option<Result<Option<usize>, &'s str>>
fn try_get_co_result( &self, co_name: &str ) -> Option<Result<Option<usize>, &'s str>>
Attempt to obtain coroutine result with the given
co_name
.source§fn add_listener(&mut self, listener: impl Listener + 's)
fn add_listener(&mut self, listener: impl Listener + 's)
Add a listener to this scheduler.
source§fn submit_co(
&self,
f: impl FnOnce(&dyn Suspender<'_, Resume = (), Yield = ()>, ()) -> Option<usize> + UnwindSafe + 'static,
stack_size: Option<usize>
) -> Result<Join>
fn submit_co( &self, f: impl FnOnce(&dyn Suspender<'_, Resume = (), Yield = ()>, ()) -> Option<usize> + UnwindSafe + 'static, stack_size: Option<usize> ) -> Result<Join>
Submit a closure to create new coroutine, then the coroutine will be push into ready queue. Read more
Auto Trait Implementations§
impl<'j> !RefUnwindSafe for JoinHandleImpl<'j>
impl<'j> !Send for JoinHandleImpl<'j>
impl<'j> !Sync for JoinHandleImpl<'j>
impl<'j> Unpin for JoinHandleImpl<'j>
impl<'j> !UnwindSafe for JoinHandleImpl<'j>
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