Abstract API for reading byte-streams and packets.
Abstract API for writing byte-streams and packets.
The "Dispatch" is a generic interface that knows how to read a designated protocol layer and sort inc...
void add(satcat5::net::Protocol *proto)
Register a Protocol object.
Dispatch()
Constructor and destructor access restricted to children.
virtual satcat5::io::Writeable * open_reply(const satcat5::net::Type &type, unsigned len)=0
Open a reply to the sender of the most recent message by writing frame header(s) and returning a stre...
satcat5::util::List< satcat5::net::Protocol > m_list
Linked list of Protocol objects.
~Dispatch()
Constructor and destructor access restricted to children.
bool deliver(const satcat5::net::Type &type, satcat5::io::Readable *src, unsigned len)
Deliver current message by calling Protocol::frame_rcvd(...).
void remove(satcat5::net::Protocol *proto)
Unregister a Protocol object.
bool bound(const satcat5::net::Type &type) const
Check if a given net::Type has a matching Protocol.
A net::Protocol is the counterpart to net::Dispatch that handles a particular data stream,...
void add(T *item)
Add new item to front or back, whichever is simpler.
void remove(T *item)
Remove the designated item from the list.
Templated functions for manipulating singly-linked lists.
Multipurpose filter for matching fields in network packets.
Basic type aliases and prototypes used throughout SatCat5.