pub trait BlockOn:
Clone
+ Send
+ Sync
+ 'static {
// Required method
fn block_on<F: Future>(&self, future: F) -> F::Output;
}
Expand description
Trait for a runtime that can block on a future.
Required Methods§
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.
Implementations on Foreign Types§
Source§impl BlockOn for AsyncStd
Available on (crate features native-tls
or rustls
) and (crate features async-std
or tokio
) and crate feature async-std
only.
impl BlockOn for AsyncStd
Available on (crate features
native-tls
or rustls
) and (crate features async-std
or tokio
) and crate feature async-std
only.Implementors§
impl BlockOn for AsyncStdNativeTlsRuntime
Available on (crate features
native-tls
or rustls
) and crate feature async-std
only.impl BlockOn for AsyncStdRustlsRuntime
Available on (crate features
native-tls
or rustls
) and crate feature async-std
only.impl BlockOn for PreferredRuntime
impl BlockOn for TokioNativeTlsRuntime
Available on (crate features
native-tls
or rustls
) and crate feature tokio
only.impl BlockOn for TokioRustlsRuntime
Available on (crate features
native-tls
or rustls
) and crate feature tokio
only.