#[repr(u8)]pub enum QoS {
AtMostOnce = 0,
AtLeastOnce = 1,
ExactlyOnce = 2,
}
Expand description
Quality of Service
Variants§
AtMostOnce = 0
At most once delivery
The message is delivered according to the capabilities of the underlying network. No response is sent by the receiver and no retry is performed by the sender. The message arrives at the receiver either once or not at all.
AtLeastOnce = 1
At least once delivery
This quality of service ensures that the message arrives at the receiver at least once. A QoS 1 PUBLISH Packet has a Packet Identifier in its variable header and is acknowledged by a PUBACK Packet.
ExactlyOnce = 2
Exactly once delivery
This is the highest quality of service, for use when neither loss nor duplication of messages are acceptable. There is an increased overhead associated with this quality of service.
Trait Implementations§
source§impl<'de> Deserialize<'de> for QoS
impl<'de> Deserialize<'de> for QoS
source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl Ord for QoS
impl Ord for QoS
source§impl PartialOrd for QoS
impl PartialOrd for QoS
impl Copy for QoS
impl Eq for QoS
impl StructuralPartialEq for QoS
Auto Trait Implementations§
impl Freeze for QoS
impl RefUnwindSafe for QoS
impl Send for QoS
impl Sync for QoS
impl Unpin for QoS
impl UnwindSafe for QoS
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
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
🔬This is a nightly-only experimental API. (
clone_to_uninit
)