pub struct PublishOptions {
pub qos: Option<QoS>,
pub retain: Option<bool>,
pub user_properties: Option<HashMap<String, String>>,
pub content_type: Option<String>,
}Expand description
Configuration options to publish data.
Fields§
§qos: Option<QoS>Quality field of services is an agreement between the message sender and receiver that defines the level of delivery guarantee for a specific message.
retain: Option<bool>Retain make the broker store the last message and each client that subscribe will receive this last message immediately after they subscribe.
user_properties: Option<HashMap<String, String>>User-defined key-value pairs metadata to send with the MQTT message.
content_type: Option<String>String that describes the content of the application message.
Trait Implementations§
Source§impl Clone for PublishOptions
impl Clone for PublishOptions
Source§fn clone(&self) -> PublishOptions
fn clone(&self) -> PublishOptions
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 moreSource§impl Debug for PublishOptions
impl Debug for PublishOptions
Source§impl Default for PublishOptions
impl Default for PublishOptions
Source§fn default() -> PublishOptions
fn default() -> PublishOptions
Returns the “default value” for a type. Read more
Source§impl PartialEq for PublishOptions
impl PartialEq for PublishOptions
impl Eq for PublishOptions
impl StructuralPartialEq for PublishOptions
Auto Trait Implementations§
impl Freeze for PublishOptions
impl RefUnwindSafe for PublishOptions
impl Send for PublishOptions
impl Sync for PublishOptions
impl Unpin for PublishOptions
impl UnwindSafe for PublishOptions
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