#[repr(C)]
pub struct JoinHandleImpl<'j>(/* private fields */);

Trait Implementations§

source§

impl<'j> Debug for JoinHandleImpl<'j>

source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
source§

impl<'j> JoinHandle<SchedulerImpl<'j>> for JoinHandleImpl<'j>

source§

fn new(pool: *const SchedulerImpl<'j>, name: &str) -> Self

create JoinHandle instance.
source§

fn get_name(&self) -> Result<&str>

get the task name. Read more
source§

fn timeout_at_join( &self, timeout_time: u64 ) -> Result<Result<Option<usize>, &str>>

join with timeout. Read more
source§

fn err() -> Self
where Self: Sized,

create JoinHandle instance.
source§

fn timeout_join(&self, dur: Duration) -> Result<Result<Option<usize>, &str>>

join with Duration. Read more
source§

fn join(&self) -> Result<Result<Option<usize>, &str>>

join. Read more
source§

impl<'s> Scheduler<'s, JoinHandleImpl<'s>> for SchedulerImpl<'s>

source§

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)

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<()>

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<()>

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>

Attempt to schedule the coroutines before the timeout_time timestamp. Read more
source§

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 size(&self) -> usize

Returns the number of coroutines owned by this scheduler.
source§

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>

Submit a closure to create new coroutine, then the coroutine will be push into ready queue. Read more
source§

fn try_schedule(&self) -> Result<()>

Schedule the coroutines. Read more
source§

fn try_timed_schedule(&self, dur: Duration) -> Result<u64>

Try scheduling the coroutines for up to dur. Read more
source§

fn is_empty(&self) -> bool

Returns true if the ready queue, suspend queue, and syscall queue are all empty.

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> Any for T
where T: 'static + ?Sized,

source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
source§

impl<T> Borrow<T> for T
where T: ?Sized,

source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
source§

impl<T> From<T> for T

source§

fn from(t: T) -> T

Returns the argument unchanged.

source§

impl<T, U> Into<U> for T
where U: From<T>,

source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

§

impl<T> Pointable for T

§

const ALIGN: usize = _

The alignment of pointer.
§

type Init = T

The type for initializers.
§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
§

impl<V, T> VZip<V> for T
where V: MultiLane<T>,

§

fn vzip(self) -> V