pub fn drive_messages<H, T>(
handshake: H,
transport: &mut T,
) -> Result<Established<H::Output>, DriveError<H::Error>>where
H: Handshake,
T: MessageTransport,Expand description
Runs handshake to completion over a blocking message transport. Each message the
handshake sends is one transport message, and each received one is handed over whole,
for either Framing.
Use a transport that delivers messages reliably and in order; a handshake does not recover from a lost datagram.
ยงErrors
DriveError when the transport fails or the handshake refuses the peer.