pub trait MessageConnector:
Send
+ Sync
+ 'static {
type Transport: MessageTransport;
// Required method
fn connect(&self) -> impl Future<Output = Result<Self::Transport>> + Send;
}Expand description
A factory that creates new message-based connections on demand.
Used by connect_framed() for reconnection with transports that
already provide message framing (like WebSocket).
Required Associated Types§
Sourcetype Transport: MessageTransport
type Transport: MessageTransport
The message transport type (e.g., WsTransport).
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.