Connector

Trait Connector 

Source
pub trait Connector {
    type Output;

    // Required method
    fn connect(&mut self) -> PinFut<Result<Self::Output, Error>>;

    // Provided method
    fn reconnect(&mut self) -> PinFut<Result<Self::Output, Error>> { ... }
}
Expand description

Represents an I/O source capable of reconnecting

This trait is implemented for a number of types in the library, with the implementations placed behind feature flags

Required Associated Types§

Required Methods§

Source

fn connect(&mut self) -> PinFut<Result<Self::Output, Error>>

Initializes the connection to the I/O source

Provided Methods§

Source

fn reconnect(&mut self) -> PinFut<Result<Self::Output, Error>>

Re-establishes the connection to the I/O source

Implementors§