Main Page | Modules | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

SDESSchedule Class Reference

#include <MNRTPdefs.h>

Inheritance diagram for SDESSchedule:

Inheritance graph
[legend]
Collaboration diagram for SDESSchedule:

Collaboration graph
[legend]
List of all members.

Public Member Functions

 SDESSchedule ()
 ~SDESSchedule ()
 Delete all items in the least.
void * first ()
void next (void *&pix)
sdes_list_itemoperator() (void *pix)
void append (sdes_list_item *p)
void clear ()
void del (void *pix)
void lock ()
 Reserve access to this object.
void unlock ()
 Release to this object.
void decrease_send_counters ()
size_t get_sdes_send_number (size_t &bytecount)
void set_default_cname ()
void set_sdes (rtcp_sdes_type_t type, char *text, int prio)

Detailed Description

RTCP sender's SDES schedule.
Only the CNAME SDES message must be included in every RTCP report. All others should be sent less often to save bandwidth. This class implements the schedule for the MNRTCP class.


Constructor & Destructor Documentation

SDESSchedule::SDESSchedule  ) 
 

Do the basic initializations, e.g. adding the default CNAME item

SDESSchedule::~SDESSchedule  ) 
 

Delete all items in the least.


Member Function Documentation

void SDESSchedule::append sdes_list_item p  )  [inline]
 

Reimplemented from MNList< sdes_list_item * >.

void SDESSchedule::clear  )  [inline]
 

Reimplemented from MNList< sdes_list_item * >.

void SDESSchedule::decrease_send_counters  ) 
 

Reduce all members' send counter.
Not all SDES items are included in each RTCP message. The send counter in the items is used to determine when an item is sent. With each RTCP message sent, this send counter is decreased.

void SDESSchedule::del void *  pix  )  [inline]
 

void* SDESSchedule::first  )  [inline]
 

size_t SDESSchedule::get_sdes_send_number size_t &  bytecount  ) 
 

Return the number of SDES items that can be sent.
This is identical with number of entries with send value 0. The result should always be 1 or greater, since CNAME can always be sent. As a side effect, the number of bytes that must be sent is calculated.

Parameters:
bytecount An OUT value indicating the number of bytes that are ready to sent.
Returns:
number of SDES messages that are ready to send (send == 0)

void SDESSchedule::lock  ) 
 

Reserve access to this object.

void SDESSchedule::next void *&  pix  )  [inline]
 

sdes_list_item* SDESSchedule::operator() void *  pix  )  [inline]
 

void SDESSchedule::set_default_cname  ) 
 

Add the default CNAME SDES item, or reset the existing CNAME item.
The default CNAME SDES is always set in the constructor. The name that is proposed in the RFC has the form user (eg bla@maschine.tu-darmstadt.de). If the user can not be determined, it is set to UNKNOWN. For single user operating systems, it is allowed to set the CNAME to the host only.

void SDESSchedule::set_sdes rtcp_sdes_type_t  type,
char *  text,
int  prio
 

Add the given SDES item to the list, or reset an existing item of the same type.
Of each type, only one SDES item can exist in the list. The given type is either added, or it replaces an existing item. The priority exists to allow the transmission of SDES types at different priorities, e.g. every fifth packet is proposed for the mail address. The SDES item SDES_END is not inserted. It must be sent manually with every RTCP message to terminate the sequence of SDES items. An empty text message is not processed (previous SDES item remains in the schedule).

Parameters:
type SDES type, according to RFC1889 or MNRTPNetTypes.h
text The message, at most 255 characters without the trailing zero.
prio The priority, counting the number of RTCP messages that are sent without this message type before it is sent once.

void SDESSchedule::unlock  ) 
 

Release to this object.


The documentation for this class was generated from the following file:
Generated on Sun Mar 6 13:36:16 2005 for Komssys by doxygen 1.3.8