Description:
This class reads packets from a given istream. Note that it will only read packets of a single type specified in the constructor.
When you pull a packet out of a PacketReader, it reads a new packet from the istream. If you push a packet into a PacketReader it will come out the other side like a straight pipe. This might be useful in some cases but isn't the sort of thing you want in general.
See SwiftTypedPacketReader for a more sophisticated reader which can produce different types of packets depending on APID.
Data Fields | ||
private | Reader* | r |
private | CCSDSPacket* | p |
Constructors / Destructor | |
public | PacketReader(istream* in, CCSDSPacket* p)Constructor. You must specify an istream and a prototype packet cast as a generic CCSDSPacket. The reader will use that packet to read from the istream. |
public | ~PacketReader() |
Methods | |||
public | virtual | CCSDSPacket* | pullOut()Read a packet from the underlying istream. |
public | virtual | void | pump()Read all the packets and send them down the pipe. |
Operators |