Struct snocat::common::protocol::negotiation::NegotiationService [−][src]
pub struct NegotiationService<ServiceRegistry: ?Sized> { /* fields omitted */ }
Implementations
pub fn negotiate<'a, S: TunnelStream + Send + 'a>(
&self,
link: S,
tunnel_id: TunnelId
) -> BoxFuture<'a, Result<(S, RouteAddress, ArcService), NegotiationError>>
pub fn negotiate<'a, S: TunnelStream + Send + 'a>(
&self,
link: S,
tunnel_id: TunnelId
) -> BoxFuture<'a, Result<(S, RouteAddress, ArcService), NegotiationError>>
Performs negotiation, returning the stream if successful
If the negotiation task is dropped, the stream is dropped in an indeterminate state. In scenarios involving an owned stream, this will drop the stream, otherwise the other end of the stream may be at an unknown point in the protocol. As such, any timeout mechanism here must not expect to resume the stream after a ref drop.
Auto Trait Implementations
impl<ServiceRegistry: ?Sized> RefUnwindSafe for NegotiationService<ServiceRegistry> where
ServiceRegistry: RefUnwindSafe,
impl<ServiceRegistry: ?Sized> Send for NegotiationService<ServiceRegistry> where
ServiceRegistry: Send + Sync,
impl<ServiceRegistry: ?Sized> Sync for NegotiationService<ServiceRegistry> where
ServiceRegistry: Send + Sync,
impl<ServiceRegistry: ?Sized> Unpin for NegotiationService<ServiceRegistry>
impl<ServiceRegistry: ?Sized> UnwindSafe for NegotiationService<ServiceRegistry> where
ServiceRegistry: RefUnwindSafe,
Blanket Implementations
Mutably borrows from an owned value. Read more
Convert Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
. Read more
Convert Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
. Read more
Convert &Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s. Read more
Convert &mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
Instruments this type with the provided Span
, returning an
Instrumented
wrapper. Read more
pub fn vzip(self) -> V
Attaches the provided Subscriber
to this type, returning a
WithDispatch
wrapper. Read more
Attaches the current default Subscriber
to this type, returning a
WithDispatch
wrapper. Read more