Skip to main content

Boxable

Trait Boxable 

Source
pub trait Boxable:
    Session<SendStream: Send + Sync + SendStream<Group: Send + Sync, Offset: Send + Sync>, RecvStream: Send + Sync>
    + Send
    + Sync { }
Expand description

A transport that the async client and server can box: the session, its streams, send groups, and errors are thread-safe. Implemented automatically.

Boxing is what compiles the session code once per binary rather than once per transport.

Dyn Compatibility§

This trait is not dyn compatible.

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

Implementors§

Source§

impl<S> Boxable for S
where S: Session<SendStream: Send + Sync + SendStream<Group: Send + Sync, Offset: Send + Sync>, RecvStream: Send + Sync> + Send + Sync,