pub struct ReceivedMessage {
pub topic: String,
pub payload: Vec<u8>,
pub qos: u8,
pub subscription_id: usize,
pub response_topic: Option<String>,
pub content_type: Option<String>,
pub correlation_data: Option<Vec<u8>>,
pub user_properties: HashMap<String, String>,
}Expand description
A message received from a subscription.
This is delivered to subscribers via the mpsc::Sender<ReceivedMessage> registered
when calling MqttierClient::subscribe.
Fields§
§topic: String§payload: Vec<u8>§qos: u8§subscription_id: usize§response_topic: Option<String>§content_type: Option<String>§correlation_data: Option<Vec<u8>>§user_properties: HashMap<String, String>User properties from the MQTT5 publish properties. Keys and values are strings.
Trait Implementations§
Source§impl Clone for ReceivedMessage
impl Clone for ReceivedMessage
Source§fn clone(&self) -> ReceivedMessage
fn clone(&self) -> ReceivedMessage
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 moreAuto Trait Implementations§
impl Freeze for ReceivedMessage
impl RefUnwindSafe for ReceivedMessage
impl Send for ReceivedMessage
impl Sync for ReceivedMessage
impl Unpin for ReceivedMessage
impl UnwindSafe for ReceivedMessage
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