Struct Publish
pub struct Publish<'a> {
pub delivery: Delivery,
pub retain: bool,
pub destination: Destination<'a>,
pub properties: &'a PublishProperties,
pub payload: &'a Payload,
}Expand description
A PUBLISH to send.
The client manages topic aliases, so properties cannot
contain a Topic Alias. They also cannot contain a Subscription Identifier,
which a client must not send [MQTT-3.3.4-6]. A received PUBLISH is a
ReceivedPublish.
Fields§
§delivery: DeliveryQoS level, packet identifier and DUP flag.
retain: boolRetain flag.
destination: Destination<'a>Topic name, topic alias, or both.
properties: &'a PublishPropertiesPUBLISH properties.
payload: &'a PayloadApplication message payload.
Implementations§
§impl Publish<'_>
impl Publish<'_>
pub const fn flags_byte(&self) -> u8
pub const fn flags_byte(&self) -> u8
Returns the fixed-header flags byte for this PUBLISH.
Trait Implementations§
impl<'a> Eq for Publish<'a>
impl<'a> StructuralPartialEq for Publish<'a>
Auto Trait Implementations§
impl<'a> Freeze for Publish<'a>
impl<'a> RefUnwindSafe for Publish<'a>
impl<'a> Send for Publish<'a>
impl<'a> Sync for Publish<'a>
impl<'a> Unpin for Publish<'a>
impl<'a> UnsafeUnpin for Publish<'a>
impl<'a> UnwindSafe for Publish<'a>
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