33 #ifndef PTLIB_PCAPFILE_H
34 #define PTLIB_PCAPFILE_H
42 #include <ptlib/sockets.h>
53 bool Open(
const PFilePath & filename, OpenMode mode = ReadOnly);
56 void PrintOn(ostream & strm)
const;
58 bool WriteFrame(
const PEthSocket::Frame & frame);
61 int GetIP(PBYTEArray & payload);
62 int GetTCP(PBYTEArray & payload);
63 int GetUDP(PBYTEArray & payload);
74 const PIPSocket::Address & ip
79 const PIPSocket::Address & ip
120 void PrintOn(ostream & strm)
const;
128 const PString & format = PString::Empty()
133 const PString & format = PString::Empty()
164 class Frame :
public PEthSocket::Frame {
170 PINDEX packetSize = P_MAX_INDEX
187 #endif // PTLIB_PCAPFILE_H