Yate
Public Types | Public Member Functions | Static Public Member Functions | Public Attributes | Static Public Attributes

JGRtpCandidates Class Reference

A list of RTP transport candidates. More...

#include <yatejingle.h>

Inheritance diagram for JGRtpCandidates:
ObjList GenObject

List of all members.

Public Types

enum  Type { Unknown = -1, RtpIceUdp = 1, RtpRawUdp = 2 }

Public Member Functions

 JGRtpCandidates (Type t=Unknown)
const char * typeName () const
void generateIceAuth ()
void generateOldIceAuth ()
JGRtpCandidatefindByComponent (unsigned int component)
XMLElementtoXML (bool addCandidates, bool addAuth) const
void fromXML (XMLElement *element)

Static Public Member Functions

static void generateIceToken (String &dest, bool pwd, unsigned int max=0)
static void generateOldIceToken (String &dest)
static const char * typeName (int t, const char *defVal="unknown")

Public Attributes

Type m_type
String m_password
String m_ufrag

Static Public Attributes

static TokenDict s_type []

Detailed Description

A list of RTP transport candidates.

This class holds a list of jingle RTP transport candidates


Member Enumeration Documentation

enum Type

Enumeration of transport types


Constructor & Destructor Documentation

JGRtpCandidates ( Type  t = Unknown) [inline]

Constructor. Fill this object from an XML element

Parameters:
tThe transport type

Member Function Documentation

JGRtpCandidate* findByComponent ( unsigned int  component)

Find a candidate by its component value

Parameters:
componentThe value to search
Returns:
JGRtpCandidate pointer or 0
void fromXML ( XMLElement element)

Fill this object from a given element

Parameters:
elementThe element
void generateIceAuth ( ) [inline]

Fill password and ufrag data

static void generateIceToken ( String dest,
bool  pwd,
unsigned int  max = 0 
) [static]

Generate a random password or username to be used with ICE-UDP transport

Parameters:
destDestination string
pwdTrue to generate a password, false to generate an username (ufrag)
maxMaximum number of characters. The maxmimum value is 256. The minimum value is 22 for password and 4 for username
void generateOldIceAuth ( ) [inline]

Fill password and ufrag data using old transport restrictions (16 bytes length)

static void generateOldIceToken ( String dest) [static]

Generate a random password or username to be used with old ICE-UDP transport

Parameters:
destDestination string
XMLElement* toXML ( bool  addCandidates,
bool  addAuth 
) const

Create a 'transport' element from this object. Add candidates

Parameters:
addCandidatesTrue to add the candidate children
addAuthRtpIceUdp only: add auth data
Returns:
Valid XMLElement pointer
static const char* typeName ( int  t,
const char *  defVal = "unknown" 
) [inline, static]

Get the name associated with a list's type

Parameters:
tThe desired type
defValDefault value to return
Returns:
The name associated with a list's type

References TelEngine::lookup().

const char* typeName ( ) const [inline]

Get the name of this list's type

Returns:
The name of this list's type

References JGRtpCandidates::typeName().

Referenced by JGRtpCandidates::typeName().


Member Data Documentation

TokenDict s_type[] [static]

The list of type names


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