SatCat5
satcat5::io::MultiPacket Struct Referencefinal

Detailed Description

A packet is a linked-list of memory blocks, plus metadata.

The m_user field is for additional packet metadata; it is not used by MultiBuffer, MultiReader, or MultiWriter, but may be used safely by children of those classes as they see fit.

See also
multi_buffer.h, io::MultiReader, io::MultiWriter.

Definition at line 91 of file multi_buffer.h.

#include <multi_buffer.h>

Collaboration diagram for satcat5::io::MultiPacket:
[legend]

Classes

class  Overwriter
 Barebones class for overwriting contents of a MultiPacket. More...
 
class  Reader
 Barebones class for reading data from a MultiPacket. More...
 

Public Member Functions

 MultiPacket (const MultiChunk &t)=delete
 
MultiPacketoperator= (const MultiChunk &t)=delete
 
bool is_deleted () const
 Has this packet been deleted?
 
satcat5::io::ArrayRead peek () const
 Peek at the first chunk, up to SATCAT5_MBUFF_CHUNK bytes.
 
bool copy_to (satcat5::io::Writeable *wr) const
 Copy the packet contents to the specified destination.
 

Public Attributes

satcat5::util::List< satcat5::io::MultiChunkm_chunks
 
unsigned m_length
 Packet length in bytes.
 
unsigned m_refct
 Reference counter.
 
u16 m_priority
 Packet priority.
 
u16 m_pcount
 Packet counter.
 
u32 m_user [SATCAT5_MBUFF_USER]
 Packet metadata.
 

Private Attributes

satcat5::io::MultiPacketm_next
 

The documentation for this struct was generated from the following files: