pub struct TransportMessage {
pub sender: PeerId,
pub data: Vec<u8>,
pub protocol: String,
pub received_at: Instant,
}Expand description
Message received from transport
Fields§
§sender: PeerIdSender peer ID
data: Vec<u8>Message data
protocol: StringProtocol identifier
received_at: InstantTimestamp when received
Trait Implementations§
Source§impl Clone for TransportMessage
impl Clone for TransportMessage
Source§fn clone(&self) -> TransportMessage
fn clone(&self) -> TransportMessage
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for TransportMessage
impl RefUnwindSafe for TransportMessage
impl Send for TransportMessage
impl Sync for TransportMessage
impl Unpin for TransportMessage
impl UnwindSafe for TransportMessage
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