Struct libp2p_swarm::protocols_handler::multi::IntoMultiHandler[][src]

pub struct IntoMultiHandler<K, H> { /* fields omitted */ }

A IntoProtocolsHandler for multiple other IntoProtocolsHandlers.

Implementations

impl<K, H> IntoMultiHandler<K, H> where
    K: Hash + Eq,
    H: IntoProtocolsHandler
[src]

pub fn try_from_iter<I>(iter: I) -> Result<Self, DuplicateProtonameError> where
    I: IntoIterator<Item = (K, H)>, 
[src]

Create and populate an IntoMultiHandler from the given iterator.

It is an error for any two protocols handlers to share the same protocol name.

Trait Implementations

impl<K: Clone, H: Clone> Clone for IntoMultiHandler<K, H>[src]

impl<K, H> Debug for IntoMultiHandler<K, H> where
    K: Debug + Eq + Hash,
    H: Debug
[src]

impl<K, H> IntoProtocolsHandler for IntoMultiHandler<K, H> where
    K: Clone + Eq + Hash + Send + 'static,
    H: IntoProtocolsHandler
[src]

type Handler = MultiHandler<K, H::Handler>

The protocols handler.

Auto Trait Implementations

impl<K, H> RefUnwindSafe for IntoMultiHandler<K, H> where
    H: RefUnwindSafe,
    K: RefUnwindSafe

impl<K, H> Send for IntoMultiHandler<K, H> where
    H: Send,
    K: Send

impl<K, H> Sync for IntoMultiHandler<K, H> where
    H: Sync,
    K: Sync

impl<K, H> Unpin for IntoMultiHandler<K, H> where
    H: Unpin,
    K: Unpin

impl<K, H> UnwindSafe for IntoMultiHandler<K, H> where
    H: UnwindSafe,
    K: UnwindSafe

Blanket Implementations

impl<T> Any for T where
    T: 'static + ?Sized
[src]

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> From<T> for T[src]

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> Same<T> for T[src]

type Output = T

Should always be Self

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<V, T> VZip<V> for T where
    V: MultiLane<T>, 
[src]