Struct mqtt::packet::disconnect::DisconnectPacket
source · pub struct DisconnectPacket { /* private fields */ }
Expand description
DISCONNECT
packet
Implementations§
source§impl DisconnectPacket
impl DisconnectPacket
pub fn new() -> DisconnectPacket
Trait Implementations§
source§impl Clone for DisconnectPacket
impl Clone for DisconnectPacket
source§fn clone(&self) -> DisconnectPacket
fn clone(&self) -> DisconnectPacket
Returns a copy 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 moresource§impl Debug for DisconnectPacket
impl Debug for DisconnectPacket
source§impl DecodablePacket for DisconnectPacket
impl DecodablePacket for DisconnectPacket
type DecodePacketError = Infallible
source§fn decode_packet<R: Read>(
_reader: &mut R,
fixed_header: FixedHeader
) -> Result<Self, PacketError<Self>>
fn decode_packet<R: Read>( _reader: &mut R, fixed_header: FixedHeader ) -> Result<Self, PacketError<Self>>
Decode packet given a
FixedHeader
source§impl Default for DisconnectPacket
impl Default for DisconnectPacket
source§fn default() -> DisconnectPacket
fn default() -> DisconnectPacket
Returns the “default value” for a type. Read more
source§impl EncodablePacket for DisconnectPacket
impl EncodablePacket for DisconnectPacket
source§fn fixed_header(&self) -> &FixedHeader
fn fixed_header(&self) -> &FixedHeader
Get a reference to
FixedHeader
. All MQTT packet must have a fixed header.source§fn encode_packet<W: Write>(&self, writer: &mut W) -> Result<()>
fn encode_packet<W: Write>(&self, writer: &mut W) -> Result<()>
Encodes packet data after fixed header, including variable headers and payload
source§fn encoded_packet_length(&self) -> u32
fn encoded_packet_length(&self) -> u32
Length in bytes for data after fixed header, including variable headers and payload
source§impl From<DisconnectPacket> for VariablePacket
impl From<DisconnectPacket> for VariablePacket
source§fn from(pk: DisconnectPacket) -> VariablePacket
fn from(pk: DisconnectPacket) -> VariablePacket
Converts to this type from the input type.
source§impl PartialEq for DisconnectPacket
impl PartialEq for DisconnectPacket
source§fn eq(&self, other: &DisconnectPacket) -> bool
fn eq(&self, other: &DisconnectPacket) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.impl Eq for DisconnectPacket
impl StructuralPartialEq for DisconnectPacket
Auto Trait Implementations§
impl Freeze for DisconnectPacket
impl RefUnwindSafe for DisconnectPacket
impl Send for DisconnectPacket
impl Sync for DisconnectPacket
impl Unpin for DisconnectPacket
impl UnwindSafe for DisconnectPacket
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