Struct agnostic_lite::async_std::AsyncStdRuntime
source · pub struct AsyncStdRuntime;Available on crate feature
async-std only.Expand description
Concrete RuntimeLite implementation based on async_std runtime.
Trait Implementations§
source§impl Clone for AsyncStdRuntime
impl Clone for AsyncStdRuntime
source§fn clone(&self) -> AsyncStdRuntime
fn clone(&self) -> AsyncStdRuntime
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 moresource§impl Debug for AsyncStdRuntime
impl Debug for AsyncStdRuntime
source§impl Display for AsyncStdRuntime
impl Display for AsyncStdRuntime
source§impl RuntimeLite for AsyncStdRuntime
impl RuntimeLite for AsyncStdRuntime
§type Spawner = AsyncStdSpawner
type Spawner = AsyncStdSpawner
The spawner type for this runtime
§type LocalSpawner = AsyncStdSpawner
type LocalSpawner = AsyncStdSpawner
The local spawner type for this runtime
§type BlockingSpawner = AsyncStdSpawner
type BlockingSpawner = AsyncStdSpawner
The blocking spawner type for this runtime
§type AfterSpawner = AsyncStdSpawner
type AfterSpawner = AsyncStdSpawner
Available on crate feature
time only.The after spawner type for this runtime
§type LocalAfterSpawner = AsyncStdSpawner
type LocalAfterSpawner = AsyncStdSpawner
Available on crate feature
time only.The local after spawner type for this runtime
§type LocalInterval = Timer
type LocalInterval = Timer
Available on crate feature
time only.The local interval type for this runtime
§type LocalSleep = AsyncIoSleep
type LocalSleep = AsyncIoSleep
Available on crate feature
time only.The local sleep type for this runtime
§type Delay<F> = Delay<F, AsyncIoSleep>
where
F: Future + Send
type Delay<F> = Delay<F, AsyncIoSleep> where F: Future + Send
Available on crate feature
time only.The delay type for this runtime
§type LocalDelay<F> = Delay<F, AsyncIoSleep>
where
F: Future
type LocalDelay<F> = Delay<F, AsyncIoSleep> where F: Future
Available on crate feature
time only.The local delay type for this runtime
§type Timeout<F> = AsyncIoTimeout<F>
where
F: Future + Send
type Timeout<F> = AsyncIoTimeout<F> where F: Future + Send
Available on crate feature
time only.The timeout type for this runtime
§type LocalTimeout<F> = AsyncIoTimeout<F>
where
F: Future
type LocalTimeout<F> = AsyncIoTimeout<F> where F: Future
Available on crate feature
time only.The local timeout type for this runtime
source§fn interval(interval: Duration) -> Self::Interval
fn interval(interval: Duration) -> Self::Interval
Available on crate feature
time only.Create a new interval that starts at the current time and
yields every
period durationsource§fn interval_at(start: Instant, period: Duration) -> Self::Interval
fn interval_at(start: Instant, period: Duration) -> Self::Interval
Available on crate feature
time only.Create a new interval that starts at the given instant and
yields every
period durationsource§fn interval_local(interval: Duration) -> Self::LocalInterval
fn interval_local(interval: Duration) -> Self::LocalInterval
Available on crate feature
time only.Create a new interval that starts at the current time and
yields every
period durationsource§fn interval_local_at(start: Instant, period: Duration) -> Self::LocalInterval
fn interval_local_at(start: Instant, period: Duration) -> Self::LocalInterval
Available on crate feature
time only.Create a new interval that starts at the given instant and
yields every
period durationsource§fn sleep(duration: Duration) -> Self::Sleep
fn sleep(duration: Duration) -> Self::Sleep
Available on crate feature
time only.Create a new sleep future that completes after the given duration
has elapsed
source§fn sleep_until(instant: Instant) -> Self::Sleep
fn sleep_until(instant: Instant) -> Self::Sleep
Available on crate feature
time only.Create a new sleep future that completes at the given instant
has elapsed
source§fn sleep_local(duration: Duration) -> Self::LocalSleep
fn sleep_local(duration: Duration) -> Self::LocalSleep
Available on crate feature
time only.Create a new sleep future that completes after the given duration
has elapsed
source§fn sleep_local_until(instant: Instant) -> Self::LocalSleep
fn sleep_local_until(instant: Instant) -> Self::LocalSleep
Available on crate feature
time only.Create a new sleep future that completes at the given instant
has elapsed
source§fn delay<F>(duration: Duration, fut: F) -> Self::Delay<F>
fn delay<F>(duration: Duration, fut: F) -> Self::Delay<F>
Available on crate feature
time only.Create a new delay future that runs the
fut after the given duration
has elapsed. The Future will never be polled until the duration has
elapsed. Read moresource§fn delay_local<F>(duration: Duration, fut: F) -> Self::LocalDelay<F>where
F: Future,
fn delay_local<F>(duration: Duration, fut: F) -> Self::LocalDelay<F>where
F: Future,
Available on crate feature
time only.source§fn delay_at<F>(deadline: Instant, fut: F) -> Self::Delay<F>
fn delay_at<F>(deadline: Instant, fut: F) -> Self::Delay<F>
Available on crate feature
time only.Create a new timeout future that runs the
future after the given deadline.
The Future will never be polled until the deadline has reached. Read moresource§fn delay_local_at<F>(deadline: Instant, fut: F) -> Self::LocalDelay<F>where
F: Future,
fn delay_local_at<F>(deadline: Instant, fut: F) -> Self::LocalDelay<F>where
F: Future,
Available on crate feature
time only.source§fn spawn<F>(future: F) -> <Self::Spawner as AsyncSpawner>::JoinHandle<F::Output>where
F::Output: Send + 'static,
F: Future + Send + 'static,
<<Self::Spawner as AsyncSpawner>::JoinHandle<F> as Future>::Output: Send,
fn spawn<F>(future: F) -> <Self::Spawner as AsyncSpawner>::JoinHandle<F::Output>where
F::Output: Send + 'static,
F: Future + Send + 'static,
<<Self::Spawner as AsyncSpawner>::JoinHandle<F> as Future>::Output: Send,
Spawn a future onto the runtime
source§fn spawn_detach<F>(future: F)
fn spawn_detach<F>(future: F)
Spawn a future onto the runtime and detach it
source§fn spawn_local<F>(
future: F
) -> <Self::LocalSpawner as AsyncLocalSpawner>::JoinHandle<F::Output>
fn spawn_local<F>( future: F ) -> <Self::LocalSpawner as AsyncLocalSpawner>::JoinHandle<F::Output>
Spawn a future onto the local runtime
source§fn spawn_local_detach<F>(future: F)
fn spawn_local_detach<F>(future: F)
Spawn a future onto the local runtime and detach it
source§fn spawn_blocking<F, R>(
f: F
) -> <Self::BlockingSpawner as AsyncBlockingSpawner>::JoinHandle<R>
fn spawn_blocking<F, R>( f: F ) -> <Self::BlockingSpawner as AsyncBlockingSpawner>::JoinHandle<R>
Spawn a blocking function onto the runtime
source§fn spawn_blocking_detach<F, R>(f: F)
fn spawn_blocking_detach<F, R>(f: F)
Spawn a blocking function onto the runtime and detach it
source§fn spawn_after<F>(
duration: Duration,
future: F
) -> <Self::AfterSpawner as AsyncAfterSpawner>::JoinHandle<F::Output>
fn spawn_after<F>( duration: Duration, future: F ) -> <Self::AfterSpawner as AsyncAfterSpawner>::JoinHandle<F::Output>
Available on crate feature
time only.Spawn a future onto the runtime and run the given future after the given duration
source§fn spawn_after_at<F>(
at: Instant,
future: F
) -> <Self::AfterSpawner as AsyncAfterSpawner>::JoinHandle<F::Output>
fn spawn_after_at<F>( at: Instant, future: F ) -> <Self::AfterSpawner as AsyncAfterSpawner>::JoinHandle<F::Output>
Available on crate feature
time only.Spawn a future onto the runtime and run the given future after the given instant.
source§fn spawn_local_after<F>(
duration: Duration,
future: F
) -> <Self::LocalAfterSpawner as AsyncLocalAfterSpawner>::JoinHandle<F::Output>
fn spawn_local_after<F>( duration: Duration, future: F ) -> <Self::LocalAfterSpawner as AsyncLocalAfterSpawner>::JoinHandle<F::Output>
Available on crate feature
time only.source§fn spawn_local_after_at<F>(
at: Instant,
future: F
) -> <Self::LocalAfterSpawner as AsyncLocalAfterSpawner>::JoinHandle<F::Output>
fn spawn_local_after_at<F>( at: Instant, future: F ) -> <Self::LocalAfterSpawner as AsyncLocalAfterSpawner>::JoinHandle<F::Output>
Available on crate feature
time only.source§fn timeout<F>(duration: Duration, future: F) -> Self::Timeout<F>
fn timeout<F>(duration: Duration, future: F) -> Self::Timeout<F>
Available on crate feature
time only.Requires a
Future to complete before the specified duration has elapsed. Read moresource§fn timeout_at<F>(deadline: Instant, future: F) -> Self::Timeout<F>
fn timeout_at<F>(deadline: Instant, future: F) -> Self::Timeout<F>
Available on crate feature
time only.Requires a
Future to complete before the specified instant in time. Read moresource§fn timeout_local<F>(duration: Duration, future: F) -> Self::LocalTimeout<F>where
F: Future,
fn timeout_local<F>(duration: Duration, future: F) -> Self::LocalTimeout<F>where
F: Future,
Available on crate feature
time only.source§fn timeout_local_at<F>(deadline: Instant, future: F) -> Self::LocalTimeout<F>where
F: Future,
fn timeout_local_at<F>(deadline: Instant, future: F) -> Self::LocalTimeout<F>where
F: Future,
Available on crate feature
time only.Like
timeout_at, but does not requrie the future to be Send.
Requires a Future to complete before the specified duration has elapsed. Read moreimpl Copy for AsyncStdRuntime
Auto Trait Implementations§
impl Freeze for AsyncStdRuntime
impl RefUnwindSafe for AsyncStdRuntime
impl Send for AsyncStdRuntime
impl Sync for AsyncStdRuntime
impl Unpin for AsyncStdRuntime
impl UnwindSafe for AsyncStdRuntime
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