PcapPlusPlus
Next
|
#include <PcapFileDevice.h>
Public Member Functions | |
std::string | getFileName () const |
void | close () override |
Close the file. | |
bool | isOpened () const override |
void | getStatistics (PcapStats &stats) const override |
Get the statistics for this device. More... | |
![]() | |
bool | setFilter (std::string filterAsString) override |
bool | clearFilter () override |
virtual bool | setFilter (GeneralFilter &filter) |
virtual bool | setFilter (std::string filterAsString)=0 |
![]() | |
virtual bool | open ()=0 |
![]() | |
virtual bool | setFilter (GeneralFilter &filter) |
![]() | |
PcapStats | getStatistics () const |
Get statistics from the device. More... | |
Protected Member Functions | |
void | reportPacketProcessed (uint64_t numPackets=1) |
Report that packets were processed (read or written, depending on the device type). More... | |
void | reportPacketDropped (uint64_t numPackets=1) |
Report that packets were dropped (not read or not written, depending on the device type). More... | |
void | resetStatisticCounters () |
Reset the internal statistic counters to zero. | |
Additional Inherited Members | |
![]() | |
static std::string | getPcapLibVersionInfo () |
static bool | matchPacketWithFilter (GeneralFilter &filter, RawPacket *rawPacket) |
An abstract class (cannot be instantiated, has a private c'tor) which is the parent class for all file devices
std::string pcpp::IFileDevice::getFileName | ( | ) | const |
|
overridevirtual |
Get the statistics for this device.
The PcapStats structure will hold the following:
[out] | stats | The stats object to fill in. |
Implements pcpp::IPcapStatisticsProvider.
|
inlineoverridevirtual |
Implements pcpp::IDevice.
|
inlineprotected |
Report that packets were dropped (not read or not written, depending on the device type).
numPackets | The number of packets dropped. Default is 1. |
|
inlineprotected |
Report that packets were processed (read or written, depending on the device type).
numPackets | The number of packets processed. Default is 1. |