pub struct Frame<M> {
pub from: String,
pub msg: M,
}Expand description
A broadcast-channel frame: the sender’s per-session tag plus the protocol message.
Referenced by broadcast-style transports at runtime; it lives here so the envelope contract is verified once for every transport that shares the channel (native tests included).
Fields§
§from: StringRandom per-session tag; a frame carrying OUR tag is our own echo.
msg: MThe link protocol message.
Implementations§
Trait Implementations§
Source§impl<'de, M> Deserialize<'de> for Frame<M>where
M: Deserialize<'de>,
impl<'de, M> Deserialize<'de> for Frame<M>where
M: Deserialize<'de>,
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl<M: Eq> Eq for Frame<M>
impl<M: PartialEq> StructuralPartialEq for Frame<M>
Auto Trait Implementations§
impl<M> Freeze for Frame<M>where
M: Freeze,
impl<M> RefUnwindSafe for Frame<M>where
M: RefUnwindSafe,
impl<M> Send for Frame<M>where
M: Send,
impl<M> Sync for Frame<M>where
M: Sync,
impl<M> Unpin for Frame<M>where
M: Unpin,
impl<M> UnsafeUnpin for Frame<M>where
M: UnsafeUnpin,
impl<M> UnwindSafe for Frame<M>where
M: 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