pub struct QoSType<const ID: u8> { /* private fields */ }Expand description
7 6 5 4 3 2 1 0
+-+-+-+-+-+-+-+-+
|Z|0_1| ID |
+-+-+-+---------+
%0|r|F|E|D|prio %
+---------------+
- prio: Priority class
- D: Don't drop. Don't drop the message for congestion control.
- E: Express. Don't batch this message.
- F: Don't drop the first message for congestion control.
- r: ReservedImplementations§
Source§impl<const ID: u8> QoSType<ID>
impl<const ID: u8> QoSType<ID>
pub const DEFAULT: Self
pub const DECLARE: Self
pub const PUSH: Self
pub const REQUEST: Self
pub const RESPONSE: Self
pub const RESPONSE_FINAL: Self
pub const OAM: Self
pub const fn new( priority: Priority, congestion_control: CongestionControl, is_express: bool, ) -> Self
pub fn set_priority(&mut self, priority: Priority)
pub const fn get_priority(&self) -> Priority
pub fn set_congestion_control(&mut self, cctrl: CongestionControl)
pub const fn get_congestion_control(&self) -> CongestionControl
pub fn set_is_express(&mut self, is_express: bool)
pub const fn is_express(&self) -> bool
Trait Implementations§
impl<const ID: u8> Copy for QoSType<ID>
impl<const ID: u8> Eq for QoSType<ID>
impl<const ID: u8> StructuralPartialEq for QoSType<ID>
Auto Trait Implementations§
impl<const ID: u8> Freeze for QoSType<ID>
impl<const ID: u8> RefUnwindSafe for QoSType<ID>
impl<const ID: u8> Send for QoSType<ID>
impl<const ID: u8> Sync for QoSType<ID>
impl<const ID: u8> Unpin for QoSType<ID>
impl<const ID: u8> UnwindSafe for QoSType<ID>
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§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more