pub struct Map<T, F> { /* private fields */ }Implementations§
Trait Implementations§
Source§impl<T, D, TMap> Transport for Map<T, TMap>
impl<T, D, TMap> Transport for Map<T, TMap>
type Output = D
type Error = <T as Transport>::Error
type Dial = MapFuture<<T as Transport>::Dial, TMap>
type Incoming = MapFuture<<T as Transport>::Incoming, TMap>
type Listener = MapListener<T, TMap>
fn dial( &self, addr: Multiaddr, ) -> Result<Self::Dial, TransportError<Self::Error>>
fn listen( &self, addr: Multiaddr, ) -> Result<Self::Listener, TransportError<Self::Error>>
fn and_then<D, TMap, TMapFut>(self, map: TMap) -> AndThen<Self, TMap>
fn map<D, TMap>(self, map: TMap) -> Map<Self, TMap>
fn map_err<TErr, F>(self, map: F) -> MapErr<Self, F>
fn apply<C, D, E, U>(self, upgrade: U) -> UpgradeApply<Self, U>where
Self: Sized + Transport<Output = C>,
U: InboundConnectionUpgrade<Negotiated<C>, Output = D, Error = E> + OutboundConnectionUpgrade<Negotiated<C>, Output = D, Error = E>,
E: Error,
fn choice<B>(self, other: B) -> Choice<Self, B>
fn timeout(self, timeout: Duration) -> Timeout<Self>where
Self: Sized,
fn boxed(self) -> Boxed<Self::Output>
fn upgrade(self) -> Builder<Self>
impl<T: Copy, F: Copy> Copy for Map<T, F>
Auto Trait Implementations§
impl<T, F> Freeze for Map<T, F>
impl<T, F> RefUnwindSafe for Map<T, F>where
T: RefUnwindSafe,
F: RefUnwindSafe,
impl<T, F> Send for Map<T, F>
impl<T, F> Sync for Map<T, F>
impl<T, F> Unpin for Map<T, F>
impl<T, F> UnsafeUnpin for Map<T, F>where
T: UnsafeUnpin,
F: UnsafeUnpin,
impl<T, F> UnwindSafe for Map<T, F>where
T: UnwindSafe,
F: UnwindSafe,
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more