pub trait Connector {
// Required methods
fn new_outgoing_connection<'life0, 'life1, 'async_trait>(
&'life0 mut self,
locator: &'life1 Peer,
) -> Pin<Box<dyn Future<Output = Result<Connection>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait;
fn accept_incoming_connection<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Option<Connection>>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Required Methods§
Sourcefn new_outgoing_connection<'life0, 'life1, 'async_trait>(
&'life0 mut self,
locator: &'life1 Peer,
) -> Pin<Box<dyn Future<Output = Result<Connection>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
fn new_outgoing_connection<'life0, 'life1, 'async_trait>(
&'life0 mut self,
locator: &'life1 Peer,
) -> Pin<Box<dyn Future<Output = Result<Connection>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
'life1: 'async_trait,
Create a new outgoing connection to the peer locator given.
Sourcefn accept_incoming_connection<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Option<Connection>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn accept_incoming_connection<'life0, 'async_trait>(
&'life0 mut self,
) -> Pin<Box<dyn Future<Output = Result<Option<Connection>>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Accept incoming connections to this peer’s netlayer location.