Trait massa_bootstrap::client::BSConnector

source ·
pub trait BSConnector {
    // Required method
    fn connect_timeout(
        &self,
        addr: SocketAddr,
        duration: Option<MassaTime>,
    ) -> Result<TcpStream>;
}
Expand description

Specifies a common interface that can be used by standard, or mockers

Required Methods§

source

fn connect_timeout( &self, addr: SocketAddr, duration: Option<MassaTime>, ) -> Result<TcpStream>

The client attempts to connect to the given address. If a duration is provided, the attempt will be timed out after the given duration.

Implementors§