pub struct Peer<P: ConnectionPeer> { /* private fields */ }
Expand description
Structure that stores peer’s id, and maybe peer as well.
Implementations§
Source§impl<P: ConnectionPeer> Peer<P>
impl<P: ConnectionPeer> Peer<P>
Sourcepub fn consolidate(&mut self, other: Self)
pub fn consolidate(&mut self, other: Self)
Consolidates given peer into Self
whilst consuming it.
See ConnectionPeer::consolidate for details.
Panics if ids are not matching.
Trait Implementations§
Auto Trait Implementations§
impl<P> Freeze for Peer<P>
impl<P> RefUnwindSafe for Peer<P>
impl<P> Send for Peer<P>
impl<P> Sync for Peer<P>
impl<P> Unpin for Peer<P>
impl<P> UnwindSafe for Peer<P>
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