pub trait ConnectHandler: Send + Sync {
    // Required method
    fn connect<'life0, 'life1, 'life2, 'life3, 'async_trait>(
        &'life0 self,
        destination: &'life1 Destination,
        options: &'life2 Map,
        authenticator: &'life3 mut dyn Authenticator
    ) -> Pin<Box<dyn Future<Output = Result<UntypedClient>> + Send + 'async_trait>>
       where Self: 'async_trait,
             'life0: 'async_trait,
             'life1: 'async_trait,
             'life2: 'async_trait,
             'life3: 'async_trait;
}
Expand description

Represents an interface to perform a connection to some remote destination.

  • destination is the location of the server to connect to.
  • options is provided to include extra information needed to establish the connection.
  • authenticator is provided to support a challenge-based authentication while connecting.

Returns an UntypedClient representing the connection.

Required Methods§

source

fn connect<'life0, 'life1, 'life2, 'life3, 'async_trait>( &'life0 self, destination: &'life1 Destination, options: &'life2 Map, authenticator: &'life3 mut dyn Authenticator ) -> Pin<Box<dyn Future<Output = Result<UntypedClient>> + Send + 'async_trait>>where Self: 'async_trait, 'life0: 'async_trait, 'life1: 'async_trait, 'life2: 'async_trait, 'life3: 'async_trait,

Implementors§

source§

impl<F, R> ConnectHandler for Fwhere F: Fn(&Destination, &Map, &mut dyn Authenticator) -> R + Send + Sync + 'static, R: Future<Output = Result<UntypedClient>> + Send + 'static,