pub trait Connector: StreamTypes {
// Required method
fn open(
&self,
) -> impl Future<Output = Result<(Self::SendSink, Self::RecvStream), Self::OpenError>> + Send;
// Provided methods
fn map<In1, Out1>(self) -> MappedConnector<In1, Out1, Self>
where In1: TryFrom<Self::In>,
Self::Out: From<Out1> { ... }
fn boxed(self) -> BoxedConnector<Self::In, Self::Out>
where Self: BoxableConnector<Self::In, Self::Out> + Sized + 'static { ... }
}
Expand description
A connection to a specific remote machine
A connection can be used to open bidirectional typed channels using Connector::open
.
Required Methods§
Provided Methods§
Sourcefn map<In1, Out1>(self) -> MappedConnector<In1, Out1, Self>
fn map<In1, Out1>(self) -> MappedConnector<In1, Out1, Self>
Map the input and output types of this connection
Sourcefn boxed(self) -> BoxedConnector<Self::In, Self::Out>
fn boxed(self) -> BoxedConnector<Self::In, Self::Out>
Box the connection
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.