Struct raptorq::EncodingPacket
source · pub struct EncodingPacket { /* private fields */ }
Expand description
Contains encoding symbols generated from a source block.
As defined in section 4.4.2.
Implementations§
source§impl EncodingPacket
impl EncodingPacket
pub fn new(payload_id: PayloadId, data: Vec<u8>) -> EncodingPacket
pub fn deserialize(data: &[u8]) -> EncodingPacket
pub fn serialize(&self) -> Vec<u8>
sourcepub fn payload_id(&self) -> &PayloadId
pub fn payload_id(&self) -> &PayloadId
Retrieves packet payload ID.
Trait Implementations§
source§impl Clone for EncodingPacket
impl Clone for EncodingPacket
source§fn clone(&self) -> EncodingPacket
fn clone(&self) -> EncodingPacket
Returns a copy 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 moresource§impl Debug for EncodingPacket
impl Debug for EncodingPacket
source§impl Hash for EncodingPacket
impl Hash for EncodingPacket
source§impl Ord for EncodingPacket
impl Ord for EncodingPacket
source§fn cmp(&self, other: &EncodingPacket) -> Ordering
fn cmp(&self, other: &EncodingPacket) -> Ordering
1.21.0 · source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
source§impl PartialEq for EncodingPacket
impl PartialEq for EncodingPacket
source§fn eq(&self, other: &EncodingPacket) -> bool
fn eq(&self, other: &EncodingPacket) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl PartialOrd for EncodingPacket
impl PartialOrd for EncodingPacket
source§fn partial_cmp(&self, other: &EncodingPacket) -> Option<Ordering>
fn partial_cmp(&self, other: &EncodingPacket) -> Option<Ordering>
1.0.0 · source§fn le(&self, other: &Rhs) -> bool
fn le(&self, other: &Rhs) -> bool
This method tests less than or equal to (for
self
and other
) and is used by the <=
operator. Read moreimpl Eq for EncodingPacket
impl StructuralPartialEq for EncodingPacket
Auto Trait Implementations§
impl Freeze for EncodingPacket
impl RefUnwindSafe for EncodingPacket
impl Send for EncodingPacket
impl Sync for EncodingPacket
impl Unpin for EncodingPacket
impl UnwindSafe for EncodingPacket
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