pub struct PduHeader {
pub protocol_version: ProtocolVersion,
pub exercise_id: u8,
pub pdu_type: PduType,
pub protocol_family: ProtocolFamily,
pub time_stamp: u32,
pub pdu_length: u16,
pub pdu_status: Option<PduStatus>,
pub padding: u16,
}Expand description
6.2.66 PDU Header record
Fields§
§protocol_version: ProtocolVersion§exercise_id: u8§pdu_type: PduType§protocol_family: ProtocolFamily§time_stamp: u32§pdu_length: u16§pdu_status: Option<PduStatus>§padding: u16Implementations§
Source§impl PduHeader
impl PduHeader
pub fn new( protocol_version: ProtocolVersion, exercise_id: u8, pdu_type: PduType, ) -> Self
pub fn new_v6(exercise_id: u8, pdu_type: PduType) -> Self
pub fn new_v7(exercise_id: u8, pdu_type: PduType) -> Self
pub fn with_pdu_type(self, pdu_type: PduType) -> Self
pub fn with_time_stamp(self, time_stamp: impl Into<u32>) -> Self
pub fn with_length(self, body_length: u16) -> Self
pub fn with_pdu_status(self, pdu_status: PduStatus) -> Self
Trait Implementations§
impl Copy for PduHeader
impl StructuralPartialEq for PduHeader
Auto Trait Implementations§
impl Freeze for PduHeader
impl RefUnwindSafe for PduHeader
impl Send for PduHeader
impl Sync for PduHeader
impl Unpin for PduHeader
impl UnwindSafe for PduHeader
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