Struct mqtt::control::fixed_header::FixedHeader
[−]
[src]
pub struct FixedHeader { pub packet_type: PacketType, pub remaining_length: u32, }
Fixed header for each MQTT control packet
Format:
7 3 0
+--------------------------+--------------------------+
| MQTT Control Packet Type | Flags for each type |
+--------------------------+--------------------------+
| Remaining Length ... |
+-----------------------------------------------------+
Fields
packet_type: PacketType
Packet Type
remaining_length: u32
The Remaining Length is the number of bytes remaining within the current packet, including data in the variable header and the payload. The Remaining Length does not include the bytes used to encode the Remaining Length.
Methods
impl FixedHeader
[src]
fn new(packet_type: PacketType, remaining_length: u32) -> FixedHeader
Trait Implementations
impl PartialEq for FixedHeader
[src]
fn eq(&self, __arg_0: &FixedHeader) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &FixedHeader) -> bool
This method tests for !=
.
impl Eq for FixedHeader
[src]
impl Copy for FixedHeader
[src]
impl Clone for FixedHeader
[src]
fn clone(&self) -> FixedHeader
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more