Skip to main content

JoinSetProvider

Trait JoinSetProvider 

Source
pub trait JoinSetProvider:
    Clone
    + Send
    + Sync
    + 'static {
    type JoinSet<T: Send + Sync + 'static>: JoinSet<T>;

    // Required method
    fn new_join_set<T>(&self) -> Self::JoinSet<T>
       where T: Send + Sync + 'static;
}
Expand description

Trait for a runtime that can create JoinSets.

Required Associated Types§

Source

type JoinSet<T: Send + Sync + 'static>: JoinSet<T>

The JoinSet type of this runtime.

Required Methods§

Source

fn new_join_set<T>(&self) -> Self::JoinSet<T>
where T: Send + Sync + 'static,

Create a new JoinSet for use with this runtime.

Important: the resulting JoinSet should only be used from the context of the runtime it was created for. Using the JoinSet with a different runtime can lead to panics, or erroneous behavior.

Dyn Compatibility§

This trait is not dyn compatible.

In older versions of Rust, dyn compatibility was called "object safety".

Implementations on Foreign Types§

Source§

impl JoinSetProvider for AsyncStd

Available on crate feature async-std and (crate features async-std or smol or tokio) and (crate features native-tls or rustls) only.
Source§

type JoinSet<T: Send + Sync + 'static> = FuturesJoinSet<T, AsyncStd>

Source§

fn new_join_set<T>(&self) -> Self::JoinSet<T>
where T: Send + Sync + 'static,

Implementors§

Source§

impl JoinSetProvider for AsyncStdNativeTlsRuntime

Available on crate feature async-std and (crate features native-tls or rustls) only.
Source§

impl JoinSetProvider for AsyncStdRustlsRuntime

Available on crate feature async-std and (crate features native-tls or rustls) only.
Source§

impl JoinSetProvider for PreferredRuntime

Source§

impl JoinSetProvider for SmolNativeTlsRuntime

Available on crate feature smol and (crate features native-tls or rustls) only.
Source§

type JoinSet<T: Send + Sync + 'static> = <CompoundRuntime<SmolRuntime, SmolRuntime, RealCoarseTimeProvider, SmolRuntime, SmolRuntime, NativeTlsProvider, SmolRuntime> as JoinSetProvider>::JoinSet<T>

Source§

impl JoinSetProvider for SmolRustlsRuntime

Available on crate feature smol and (crate features native-tls or rustls) only.
Source§

type JoinSet<T: Send + Sync + 'static> = <CompoundRuntime<SmolRuntime, SmolRuntime, RealCoarseTimeProvider, SmolRuntime, SmolRuntime, RustlsProvider, SmolRuntime> as JoinSetProvider>::JoinSet<T>

Source§

impl JoinSetProvider for TokioNativeTlsRuntime

Available on crate feature tokio and (crate features native-tls or rustls) only.
Source§

type JoinSet<T: Send + Sync + 'static> = <CompoundRuntime<TokioRuntimeHandle, TokioRuntimeHandle, RealCoarseTimeProvider, TokioRuntimeHandle, TokioRuntimeHandle, NativeTlsProvider, TokioRuntimeHandle> as JoinSetProvider>::JoinSet<T>

Source§

impl JoinSetProvider for TokioRustlsRuntime

Available on crate feature tokio and (crate features native-tls or rustls) only.
Source§

type JoinSet<T: Send + Sync + 'static> = <CompoundRuntime<TokioRuntimeHandle, TokioRuntimeHandle, RealCoarseTimeProvider, TokioRuntimeHandle, TokioRuntimeHandle, RustlsProvider, TokioRuntimeHandle> as JoinSetProvider>::JoinSet<T>

Source§

impl<TaskR, SleepR, CoarseTimeR, TcpR, UnixR, TlsR, UdpR> JoinSetProvider for CompoundRuntime<TaskR, SleepR, CoarseTimeR, TcpR, UnixR, TlsR, UdpR>
where UdpR: Send + Sync + 'static, TaskR: JoinSetProvider + Send + Sync + 'static, SleepR: Send + Sync + 'static, CoarseTimeR: Send + Sync + 'static, TcpR: Send + Sync + 'static, UnixR: Clone + Send + Sync + 'static, TlsR: Send + Sync + 'static,

Source§

type JoinSet<T: Send + Sync + 'static> = <TaskR as JoinSetProvider>::JoinSet<T>