pub fn setup_outbound<PM, CMH, RMH, OMH, L, UMH, NS>(
    peer_manager: PM,
    their_node_id: PublicKey,
    stream: StdTcpStream
) -> impl Future<Output = ()>where
    PM: Deref<Target = PeerManager<SocketDescriptor, CMH, RMH, OMH, L, UMH, NS>> + 'static + Send + Sync + Clone,
    CMH: Deref + 'static + Send + Sync,
    RMH: Deref + 'static + Send + Sync,
    OMH: Deref + 'static + Send + Sync,
    L: Deref + 'static + Send + Sync,
    UMH: Deref + 'static + Send + Sync,
    NS: Deref + 'static + Send + Sync,
    CMH::Target: ChannelMessageHandler + Send + Sync,
    RMH::Target: RoutingMessageHandler + Send + Sync,
    OMH::Target: OnionMessageHandler + Send + Sync,
    L::Target: Logger + Send + Sync,
    UMH::Target: CustomMessageHandler + Send + Sync,
    NS::Target: NodeSigner + Send + Sync,
Expand description

Process incoming messages and feed outgoing messages on the provided socket generated by making an outbound connection which is expected to be accepted by a peer with the given public key. The relevant processing is set to run free (via tokio::spawn).

The returned future will complete when the peer is disconnected and associated handling futures are freed, though, because all processing futures are spawned with tokio::spawn, you do not need to poll the provided future in order to make progress.