Trait tauri::async_runtime::RuntimeHandle
pub trait RuntimeHandle: Debug + Clone + Sync + Sync {
fn spawn<F: Future>(&self, task: F) -> JoinHandle<F::Output>ⓘ
Notable traits for JoinHandle<T>
impl<T> Future for JoinHandle<T> type Output = Result<T>;
where
F: Future + Send + 'static,
F::Output: Send + 'static;
fn block_on<F: Future>(&self, task: F) -> F::Output;
}
Expand description
Runtime handle definition.
#
Required methodsspawn<F: Future>(&self, task: F) -> JoinHandle<F::Output>ⓘNotable traits for JoinHandle<T>impl<T> Future for JoinHandle<T>type Output = Result<T>;
where F: Future + Send + 'static, F::Output: Send + 'static,[src]#
fn Spawns a future onto the runtime.
block_on<F: Future>(&self, task: F) -> F::Output[src]#
fnRuns a future to completion on runtime.