OpalPCAPFile Class Reference

`#include <pcapfile.h>`

Inheritance diagram for OpalPCAPFile:

## Data Structures

struct | DiscoveredRTPInfo
class | DiscoveredRTPMap
struct | FileHeader
struct | RecordHeader

## Public Member Functions

| OpalPCAPFile ()
bool | Open (const PFilePath &filename)
bool | Restart ()
void | PrintOn (ostream &strm) const
bool | ReadRawPacket (PBYTEArray &payload)
int | GetDataLink (PBYTEArray &payload)
int | GetIP (PBYTEArray &payload)
int | GetUDP (PBYTEArray &payload)
int | GetRTP (RTP_DataFrame &rtp)
const PTime & | GetPacketTime () const
const PIPSocket::Address & | GetSrcIP () const
const PIPSocket::Address & | GetDstIP () const
unsigned | IsFragmentated () const
WORD | GetSrcPort () const
WORD | GetDstPort () const
void | SetFilterSrcIP (const PIPSocket::Address &ip)
const PIPSocket::Address & | GetFilterSrcIP () const
void | SetFilterDstIP (const PIPSocket::Address &ip)
const PIPSocket::Address & | GetFilterDstIP () const
void | SetFilterSrcPort (WORD port)
WORD | GetFilterSrcPort () const
void | SetFilterDstPort (WORD port)
WORD | GetFilterDstPort () const
bool | DiscoverRTP (DiscoveredRTPMap &discoveredRTPMap)
void | SetFilters (const DiscoveredRTPInfo &rtp, int dir)
bool | SetFilters (const DiscoveredRTPMap &rtp, size_t index)
bool | SetPayloadMap (RTP_DataFrame::PayloadTypes pt, const OpalMediaFormat &format)
OpalMediaFormat | GetMediaFormat (const RTP_DataFrame &rtp) const

## Protected Member Functions

PINDEX | GetNetworkLayerHeaderSize ()

## Protected Attributes

FileHeader | m_fileHeader
bool | m_otherEndian
PBYTEArray | m_rawPacket
PTime | m_packetTime
PIPSocket::Address | m_filterSrcIP
PIPSocket::Address | m_filterDstIP
PIPSocket::Address | m_packetSrcIP
PIPSocket::Address | m_packetDstIP
PBYTEArray | m_fragments
bool | m_fragmentated
unsigned | m_fragmentProto
WORD | m_filterSrcPort
WORD | m_filterDstPort
WORD | m_packetSrcPort
WORD | m_packetDstPort
std::map< RTP_DataFrame::PayloadTypes, OpalMediaFormat > | m_payloadType2mediaFormat

## Detailed Description

Class for a reading RTP from an Ethernet Capture (PCAP) file.

## Constructor & Destructor Documentation

OpalPCAPFile::OpalPCAPFile | ( |  | ) |

## Member Function Documentation

bool OpalPCAPFile::DiscoverRTP | ( | DiscoveredRTPMap & | discoveredRTPMap | ) |

int OpalPCAPFile::GetDataLink | ( | PBYTEArray & | payload | ) |

const PIPSocket::Address& OpalPCAPFile::GetDstIP | ( |  | ) | const

inline

References m_packetDstIP.

WORD OpalPCAPFile::GetDstPort | ( |  | ) | const

inline

References m_packetDstPort.

const PIPSocket::Address& OpalPCAPFile::GetFilterDstIP | ( |  | ) | const

inline

References m_filterDstIP.

WORD OpalPCAPFile::GetFilterDstPort | ( |  | ) | const

inline

References m_filterDstPort.

const PIPSocket::Address& OpalPCAPFile::GetFilterSrcIP | ( |  | ) | const

inline

References m_filterSrcIP.

WORD OpalPCAPFile::GetFilterSrcPort | ( |  | ) | const

inline

References m_filterSrcPort.

int OpalPCAPFile::GetIP | ( | PBYTEArray & | payload | ) |

OpalMediaFormat OpalPCAPFile::GetMediaFormat | ( | const RTP_DataFrame & | rtp | ) | const

PINDEX OpalPCAPFile::GetNetworkLayerHeaderSize | ( |  | ) |

protected

const PTime& OpalPCAPFile::GetPacketTime | ( |  | ) | const

inline

References m_packetTime.

int OpalPCAPFile::GetRTP | ( | RTP_DataFrame & | rtp | ) |

const PIPSocket::Address& OpalPCAPFile::GetSrcIP | ( |  | ) | const

inline

References m_packetSrcIP.

WORD OpalPCAPFile::GetSrcPort | ( |  | ) | const

inline

References m_packetSrcPort.

int OpalPCAPFile::GetUDP | ( | PBYTEArray & | payload | ) |

unsigned OpalPCAPFile::IsFragmentated | ( |  | ) | const

inline

References m_fragmentated.

bool OpalPCAPFile::Open | ( | const PFilePath & | filename | ) |

void OpalPCAPFile::PrintOn | ( | ostream & | strm | ) | const

bool OpalPCAPFile::ReadRawPacket | ( | PBYTEArray & | payload | ) |

bool OpalPCAPFile::Restart | ( |  | ) |

void OpalPCAPFile::SetFilterDstIP | ( | const PIPSocket::Address & | ip | ) |

inline

References m_filterDstIP.

void OpalPCAPFile::SetFilterDstPort | ( | WORD | port | ) |

inline

References m_filterDstPort.

void OpalPCAPFile::SetFilters | ( | const DiscoveredRTPInfo & | rtp,
|  | int | dir
| ) |  |

bool OpalPCAPFile::SetFilters | ( | const DiscoveredRTPMap & | rtp,
|  | size_t | index
| ) |  |

void OpalPCAPFile::SetFilterSrcIP | ( | const PIPSocket::Address & | ip | ) |

inline

References m_filterSrcIP.

void OpalPCAPFile::SetFilterSrcPort | ( | WORD | port | ) |

inline

References m_filterSrcPort.

bool OpalPCAPFile::SetPayloadMap | ( | RTP_DataFrame::PayloadTypes | pt,
|  | const OpalMediaFormat & | format
| ) |  |

## Field Documentation

FileHeader OpalPCAPFile::m_fileHeader

protected

PIPSocket::Address OpalPCAPFile::m_filterDstIP

protected

Referenced by GetFilterDstIP(), and SetFilterDstIP().

WORD OpalPCAPFile::m_filterDstPort

protected

Referenced by GetFilterDstPort(), and SetFilterDstPort().

PIPSocket::Address OpalPCAPFile::m_filterSrcIP

protected

Referenced by GetFilterSrcIP(), and SetFilterSrcIP().

WORD OpalPCAPFile::m_filterSrcPort

protected

Referenced by GetFilterSrcPort(), and SetFilterSrcPort().

bool OpalPCAPFile::m_fragmentated

protected

Referenced by IsFragmentated().

unsigned OpalPCAPFile::m_fragmentProto

protected

PBYTEArray OpalPCAPFile::m_fragments

protected

bool OpalPCAPFile::m_otherEndian

protected

PIPSocket::Address OpalPCAPFile::m_packetDstIP

protected

Referenced by GetDstIP().

WORD OpalPCAPFile::m_packetDstPort

protected

Referenced by GetDstPort().

PIPSocket::Address OpalPCAPFile::m_packetSrcIP

protected

Referenced by GetSrcIP().

WORD OpalPCAPFile::m_packetSrcPort

protected

Referenced by GetSrcPort().

PTime OpalPCAPFile::m_packetTime

protected

Referenced by GetPacketTime().

std::map<RTP_DataFrame::PayloadTypes, OpalMediaFormat> OpalPCAPFile::m_payloadType2mediaFormat

protected

PBYTEArray OpalPCAPFile::m_rawPacket

protected

The documentation for this class was generated from the following file:

- pcapfile.h