PIP 5.6.1
Platform-Independent Primitives
Classes | Typedefs
pipacketextractor.h File Reference

Packet extraction helper for byte-stream devices. More...

#include "piiodevice.h"

Classes

class  PIPacketExtractor
 Extracts packets from data produced by a child PIIODevice. The PIPacketExtractor class provides packet recognition from data stream using various algorithms. More...
 

Typedefs

typedef std::function< int(const uchar *, const uchar *, int)> PacketExtractorHeaderFunc
 Callback for header validation and payload size detection. Receives source header, received header and header size. Returns payload size or -1 when the header does not match.
 
typedef std::function< bool(const uchar *, int)> PacketExtractorPayloadFunc
 Callback for payload validation. Receives payload pointer and payload size. Returns true when the payload should be accepted.
 
typedef std::function< bool(const uchar *, const uchar *, int)> PacketExtractorFooterFunc
 Callback for footer validation. Receives source footer, received footer and footer size. Returns true when the footer matches.
 

Detailed Description

Packet extraction helper for byte-stream devices.