Bayonne2 / Common C++ 2 Framework
Data Structures | Public Member Functions | Protected Member Functions | Protected Attributes | Static Protected Attributes | Private Member Functions | Private Attributes
MembershipBookkeeping Class Reference
Generic RTP input queues.

Controls the group membership in the current session. More...

#include <iqueue.h>

Inheritance diagram for MembershipBookkeeping:
Inheritance graph
[legend]
Collaboration diagram for MembershipBookkeeping:
Collaboration graph
[legend]

Data Structures

struct   IncomingRTPPktLink
  Incoming RTP data packets control structure within the incoming packet queue class. More...
 
struct   SyncSourceLink
  Synchronization Source internal handler within the incoming packets queue. More...
 

Public Member Functions

 
void  setLink (SyncSource &source, void *link)
 
void  setParticipant (SyncSource &source, Participant &p)
 
void  setState (SyncSource &source, SyncSource::State ns)
 
void  setSender (SyncSource &source, bool active)
 
 
 
void  setNetworkAddress (SyncSource &source, InetAddress addr)
 
void  setSDESItem (Participant *part, SDESItemType item, const std::string &val)
 
void  setPRIVPrefix (Participant *part, const std::string val)
 
 
 
 
 
 
void  addConflict (const InetAddress &na, tpport_t dtp, tpport_t ctp)
 

Protected Member Functions

  The initial size is a hint to allocate the resources needed in order to keep the members' identifiers and associated information. More...
 
  Purges all RTPSource structures created during the session, as well as the hash table and the list of sources. More...
 
SyncSourceLinkgetLink (const SyncSource &source) const
 
bool  isMine (const SyncSource &source) const
  Get whether a synchronization source is recorded in this membership controller. More...
 
bool  isRegistered (uint32 ssrc)
  Returns whether there is already a synchronizacion source with "ssrc" SSRC identifier. More...
 
SyncSourceLinkgetSourceBySSRC (uint32 ssrc, bool &created)
  Get the description of a source by its ssrc identifier. More...
 
bool  BYESource (uint32 ssrc)
  Mark the source identified by ssrc as having sent a BYE packet. More...
 
bool  removeSource (uint32 ssrc)
  Remove the description of the source identified by ssrc More...
 
 
 
uint32  getMembersCount ()
 
void  setMembersCount (uint32 n)
 
uint32  getSendersCount ()
 

Protected Attributes

 
 

Static Protected Attributes

static const size_t  defaultMembersHashSize
 
static const uint32  SEQNUMMOD
 

Private Member Functions

 
 
void  endMembers ()
  Purge all RTPSource structures, the hash table and the list of sources. More...
 
 
 
uint32  getMembersCount () const
 
void  setSendersCount (uint32 n)
 
 
 
uint32  getSendersCount () const
 

Private Attributes

uint32  sourceBucketsNum
 
 
 
 

Detailed Description

Controls the group membership in the current session.

For now, this class implements only a hash table of members, but its design and relation with other classes is intented to support group membership sampling in case scalability problems arise.

Author
Federico Montesino Pouzols fedem.nosp@m.p@al.nosp@m.tern..nosp@m.org

Definition at line 301 of file iqueue.h.

Constructor & Destructor Documentation

MembershipBookkeeping::MembershipBookkeeping ( uint32  initialSize = defaultMembersHashSize )
protected

The initial size is a hint to allocate the resources needed in order to keep the members' identifiers and associated information.

Although ccRTP will reallocate resources when it becomes necessary, a good hint may save a lot of unpredictable time penalties.

Parameters
initialSize an estimation of how many participants the session will consist of.
virtual MembershipBookkeeping::~MembershipBookkeeping ( )
inlineprotectedvirtual

Purges all RTPSource structures created during the session, as well as the hash table and the list of sources.

Definition at line 334 of file iqueue.h.

MembershipBookkeeping::MembershipBookkeeping ( const MembershipBookkeepingo )
private

Member Function Documentation

void ConflictHandler::addConflict ( const InetAddressna,
tpport_t  dtp,
tpport_t  ctp 
)
inherited
void ApplicationHandler::addParticipant ( RTPApplicationapp,
Participantpart 
)
inlineinherited

Definition at line 212 of file iqueue.h.

bool MembershipBookkeeping::BYESource ( uint32  ssrc )
protected

Mark the source identified by ssrc as having sent a BYE packet.

It is not deleted until a timeout expires, so that in case some packets from this source arrive a bit later the source is not inserted again in the table of known sources.

Returns
true if the source had been previously identified. false if it was not in the table of known sources.
void Members::decreaseMembersCount ( )
inlineinherited

Definition at line 82 of file iqueue.h.

void Members::decreaseSendersCount ( )
inlineinherited

Definition at line 98 of file iqueue.h.

void MembershipBookkeeping::endMembers ( )
private

Purge all RTPSource structures, the hash table and the list of sources.

size_t MembershipBookkeeping::getDefaultMembersHashSize ( )
inline

Definition at line 309 of file iqueue.h.

SyncSourceLink* MembershipBookkeeping::getFirst ( void  )
inlineprotected

Definition at line 836 of file iqueue.h.

SyncSourceLink* MembershipBookkeeping::getLast ( void  )
inlineprotected

Definition at line 839 of file iqueue.h.

SyncSourceLink* MembershipBookkeeping::getLink ( const SyncSourcesource ) const
inlineprotected

Definition at line 339 of file iqueue.h.

uint32 Members::getMembersCount ( ) const
inlineinherited

Definition at line 86 of file iqueue.h.

uint32 MembershipBookkeeping::getMembersCount ( )
inlineprotected

Definition at line 843 of file iqueue.h.

uint32 Members::getSendersCount ( ) const
inlineinherited

Definition at line 102 of file iqueue.h.

uint32 MembershipBookkeeping::getSendersCount ( )
inlineprotected

Definition at line 851 of file iqueue.h.

SyncSourceLink* MembershipBookkeeping::getSourceBySSRC ( uint32  ssrc,
bool &  created 
)
protected

Get the description of a source by its ssrc identifier.

Parameters
ssrc SSRC identifier, in host order.
created whether a new source has been created.
Returns
Pointer to the SyncSource object identified by ssrc.
void Members::increaseMembersCount ( )
inlineinherited

Definition at line 78 of file iqueue.h.

void Members::increaseSendersCount ( )
inlineinherited

Definition at line 94 of file iqueue.h.

bool MembershipBookkeeping::isMine ( const SyncSourcesource ) const
inlineprotected

Get whether a synchronization source is recorded in this membership controller.

Definition at line 345 of file iqueue.h.

bool MembershipBookkeeping::isRegistered ( uint32  ssrc )
protected

Returns whether there is already a synchronizacion source with "ssrc" SSRC identifier.

MembershipBookkeeping& MembershipBookkeeping::operator= ( const MembershipBookkeepingo )
private
void ApplicationHandler::removeParticipant ( RTPApplicationapp,
)
inlineinherited

Definition at line 216 of file iqueue.h.

bool MembershipBookkeeping::removeSource ( uint32  ssrc )
protected

Remove the description of the source identified by ssrc

Returns
whether the source has been actually removed or it did not exist.
ConflictingTransportAddress* ConflictHandler::searchControlConflict ( InetAddress  na,
tpport_t  ctp 
)
inherited
Parameters
na Inet network address.
ctp Data transport port.
ConflictingTransportAddress* ConflictHandler::searchDataConflict ( InetAddress  na,
tpport_t  dtp 
)
inherited
Parameters
na Inet network address.
dtp Data transport port.
void SyncSourceHandler::setControlTransportPort ( SyncSourcesource,
tpport_t  p 
)
inlineinherited

Definition at line 161 of file iqueue.h.

void SyncSourceHandler::setDataTransportPort ( SyncSourcesource,
tpport_t  p 
)
inlineinherited

Definition at line 157 of file iqueue.h.

void SyncSourceHandler::setLink ( SyncSourcesource,
void *  link 
)
inlineinherited

Definition at line 141 of file iqueue.h.

void MembershipBookkeeping::setMembersCount ( uint32  n )
inlineprotected

Definition at line 847 of file iqueue.h.

void SyncSourceHandler::setNetworkAddress ( SyncSourcesource,
InetAddress  addr 
)
inlineinherited

Definition at line 165 of file iqueue.h.

void SyncSourceHandler::setParticipant ( SyncSourcesource,
Participantp 
)
inlineinherited

Definition at line 145 of file iqueue.h.

void ParticipantHandler::setPRIVPrefix ( Participantpart,
const std::string  val 
)
inlineinherited

Definition at line 191 of file iqueue.h.

void ParticipantHandler::setSDESItem ( Participantpart,
SDESItemType  item,
const std::string &  val 
)
inlineinherited

Definition at line 186 of file iqueue.h.

void SyncSourceHandler::setSender ( SyncSourcesource,
bool  active 
)
inlineinherited

Definition at line 153 of file iqueue.h.

void Members::setSendersCount ( uint32  n )
inlineinherited

Definition at line 90 of file iqueue.h.

void SyncSourceHandler::setState ( SyncSourcesource,
)
inlineinherited

Definition at line 149 of file iqueue.h.

void ConflictHandler::updateConflict ( ConflictingTransportAddressca )
inlineinherited

Definition at line 276 of file iqueue.h.

Field Documentation

const size_t MembershipBookkeeping::defaultMembersHashSize
staticprotected

Definition at line 854 of file iqueue.h.

SyncSourceLink* MembershipBookkeeping::first
private

Definition at line 874 of file iqueue.h.

ConflictingTransportAddress* ConflictHandler::firstConflict
protectedinherited

Definition at line 288 of file iqueue.h.

SyncSourceLink * MembershipBookkeeping::last
private

Definition at line 874 of file iqueue.h.

ConflictingTransportAddress * ConflictHandler::lastConflict
protectedinherited

Definition at line 288 of file iqueue.h.

const uint32 MembershipBookkeeping::SEQNUMMOD
staticprotected

Definition at line 855 of file iqueue.h.

uint32 MembershipBookkeeping::sourceBucketsNum
private

Definition at line 871 of file iqueue.h.

SyncSourceLink** MembershipBookkeeping::sourceLinks
private

Definition at line 872 of file iqueue.h.


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

Generated on Dec 21, 2017 for commoncpp2-1.8.1, ccrtp-1.7.2, libzrtpcpp-2.3.4, ccscript3-1.1.7, ccaudio2-1.0.0 and bayonne2-2.3.2 (after installation in /usr/local/) by   doxygen 1.8.6

AltStyle によって変換されたページ (->オリジナル) /