pub struct MessageInfo {
pub flags: PublishFlags,
pub packet_id: u16,
}Expand description
A simple struct containing the flags used by the broker to transmit the message, as well as the packet ID (if applicable).
Fields§
§flags: PublishFlagsThe flags used by the broker to transmit the message to the client. This can be used to know if the message is a duplicate, if the message was retained and what quality of service was used to transmit it.
For more information, see PublishFlags.
packet_id: u16The packet ID used by the broker for this message. Note
that this value is invalid when using QoS::AtMostOnce,
and thus will be zero.
Trait Implementations§
Source§impl Clone for PublishPacketInfo
impl Clone for PublishPacketInfo
Source§fn clone(&self) -> PublishPacketInfo
fn clone(&self) -> PublishPacketInfo
Returns a duplicate 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 moreimpl Copy for PublishPacketInfo
Auto Trait Implementations§
impl Freeze for PublishPacketInfo
impl RefUnwindSafe for PublishPacketInfo
impl Send for PublishPacketInfo
impl Sync for PublishPacketInfo
impl Unpin for PublishPacketInfo
impl UnwindSafe for PublishPacketInfo
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