pub struct NormCommonHeader {
pub version: u8,
pub message_type: NormMessageType,
pub sequence: u16,
pub source_id: u32,
}Expand description
The NORM common message header (RFC 5740 §4.1, Figure 1): 8 bytes carrying
version | type | hdr_len | sequence | source_id.
hdr_len is not stored: it is recomputed on serialize from the typed
message body so the round-trip is field-driven.
Fields§
§version: u8Protocol version (version, 4 bits). RFC 5740 = NORM_VERSION (1).
message_type: NormMessageTypeMessage type (type, 4 bits).
sequence: u16Sequence number (16 bits).
source_id: u32Originator’s NormNodeId (source_id, 32 bits).
Implementations§
Trait Implementations§
Source§impl Clone for NormCommonHeader
impl Clone for NormCommonHeader
Source§fn clone(&self) -> NormCommonHeader
fn clone(&self) -> NormCommonHeader
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreimpl Copy for NormCommonHeader
Source§impl Debug for NormCommonHeader
impl Debug for NormCommonHeader
impl Eq for NormCommonHeader
Source§impl PartialEq for NormCommonHeader
impl PartialEq for NormCommonHeader
Source§impl Serialize for NormCommonHeader
Available on crate feature serde only.
impl Serialize for NormCommonHeader
Available on crate feature
serde only.impl StructuralPartialEq for NormCommonHeader
Auto Trait Implementations§
impl Freeze for NormCommonHeader
impl RefUnwindSafe for NormCommonHeader
impl Send for NormCommonHeader
impl Sync for NormCommonHeader
impl Unpin for NormCommonHeader
impl UnsafeUnpin for NormCommonHeader
impl UnwindSafe for NormCommonHeader
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