Trait fire_stream_api::message::PacketBytes
source · pub trait PacketBytes: Debug {
fn new(header_len: usize) -> Self;
fn header(&self) -> Bytes<'_>;
fn header_mut(&mut self) -> BytesMut<'_>;
fn full_header_mut(&mut self) -> BytesMut<'_>;
fn body(&self) -> BodyBytes<'_>;
fn body_mut(&mut self) -> BodyBytesMut<'_>;
fn full_body_mut(&mut self) -> BytesMut<'_>;
}Expand description
A trait that allows efficient allocation if encryption is used or not.
Required Methods§
sourcefn header_mut(&mut self) -> BytesMut<'_>
fn header_mut(&mut self) -> BytesMut<'_>
Returns the header mutably.
sourcefn full_header_mut(&mut self) -> BytesMut<'_>
fn full_header_mut(&mut self) -> BytesMut<'_>
sourcefn body_mut(&mut self) -> BodyBytesMut<'_>
fn body_mut(&mut self) -> BodyBytesMut<'_>
Returns the body mutably.