pub struct Codec { /* private fields */ }Expand description
Mqtt v3.1.1 protocol codec
Implementations§
Source§impl Codec
impl Codec
Sourcepub fn set_max_size(&self, size: u32)
pub fn set_max_size(&self, size: u32)
Set max inbound frame size.
If max size is set to 0, size is unlimited.
By default max size is set to 0
Sourcepub fn set_min_chunk_size(&self, size: u32)
pub fn set_min_chunk_size(&self, size: u32)
Set min payload chunk size.
If the minimum size is set to 0, incoming payload chunks
will be processed immediately. Otherwise, the codec will
accumulate chunks until the total size reaches the specified minimum.
By default min size is set to 0
Trait Implementations§
Source§impl Decoder for Codec
impl Decoder for Codec
Auto Trait Implementations§
impl !Freeze for Codec
impl !RefUnwindSafe for Codec
impl Send for Codec
impl !Sync for Codec
impl Unpin for Codec
impl UnwindSafe for Codec
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