SDRAngel
4.11.5
Developer docs for <a href="https://github.com/f4exb/sdrangel">SDRangel<\a>, an Open Source Qt5 / OpenGL 3.0+ SDR and signal analyzer frontend to various hardware.
|
#include <rtpcollisionlist.h>
Classes | |
class | AddressAndTime |
Public Member Functions | |
RTPCollisionList () | |
~RTPCollisionList () | |
void | Clear () |
int | UpdateAddress (const RTPAddress *addr, const RTPTime &receivetime, bool *created) |
bool | HasAddress (const RTPAddress *addr) const |
void | Timeout (const RTPTime ¤ttime, const RTPTime &timeoutdelay) |
Private Attributes | |
std::list< AddressAndTime > | addresslist |
This class represents a list of addresses from which SSRC collisions were detected.
Definition at line 54 of file rtpcollisionlist.h.
qrtplib::RTPCollisionList::RTPCollisionList | ( | ) |
Constructs an instance, optionally installing a memory manager.
Definition at line 39 of file rtpcollisionlist.cpp.
References qrtplib::RTPTimeInitializerObject::Dummy(), and qrtplib::timeinit.
|
inline |
Definition at line 59 of file rtpcollisionlist.h.
void qrtplib::RTPCollisionList::Clear | ( | ) |
Clears the list of addresses.
Definition at line 44 of file rtpcollisionlist.cpp.
References addresslist.
Referenced by qrtplib::RTPSession::BYEDestroy(), and qrtplib::RTPSession::Destroy().
bool qrtplib::RTPCollisionList::HasAddress | ( | const RTPAddress * | addr | ) | const |
Returns true}
if the address addr
appears in the list.
Definition at line 79 of file rtpcollisionlist.cpp.
References addresslist.
void qrtplib::RTPCollisionList::Timeout | ( | const RTPTime & | currenttime, |
const RTPTime & | timeoutdelay | ||
) |
Assuming that the current time is given by currenttime
, this function times out entries which haven't been updated in the previous time interval specified by timeoutdelay
.
Definition at line 92 of file rtpcollisionlist.cpp.
References addresslist.
Referenced by qrtplib::RTPSession::ProcessPolledData().
int qrtplib::RTPCollisionList::UpdateAddress | ( | const RTPAddress * | addr, |
const RTPTime & | receivetime, | ||
bool * | created | ||
) |
Updates the entry for address addr
to indicate that a collision was detected at time receivetime
. Updates the entry for address addr
to indicate that a collision was detected at time receivetime
. If the entry did not exist yet, the flag created
is set to true
, otherwise it is set to false
.
Definition at line 53 of file rtpcollisionlist.cpp.
References addresslist, qrtplib::RTPAddress::CreateCopy(), ERR_RTP_COLLISIONLIST_BADADDRESS, and ERR_RTP_OUTOFMEM.
Referenced by qrtplib::RTPSession::ProcessPolledData().
|
private |
Definition at line 94 of file rtpcollisionlist.h.
Referenced by Clear(), HasAddress(), Timeout(), and UpdateAddress().