|
reSIProcate
SIP stack, Dialog Usage Manager and related libraries
|
process m= (media announcement) blocks More...
#include <SdpContents.hxx>
Public Types | |
| typedef std::list< Codec > | CodecContainer |
Public Member Functions | |
| Medium () | |
| Medium (const Medium &rhs) | |
| Medium (const Data &name, unsigned long port, unsigned long multicast, const Data &protocol) | |
| Constructor. | |
| Medium & | operator= (const Medium &rhs) |
| void | parse (ParseBuffer &pb) |
| EncodeStream & | encode (EncodeStream &) const |
| void | addFormat (const Data &format) |
| add a format identifier to the m= line | |
| void | setConnection (const Connection &connection) |
| set the media connection line. | |
| void | addConnection (const Connection &connection) |
| add a media connection line. | |
| void | setBandwidth (const Bandwidth &bandwidth) |
| void | addBandwidth (const Bandwidth &bandwidth) |
| void | addAttribute (const Data &key, const Data &value=Data::Empty) |
| add a media attribute line | |
| const Data & | name () const |
| return the media type | |
| Data & | name () |
| return the media type | |
| int | port () const |
| return the base port | |
| unsigned long & | port () |
| return the base port | |
| void | setPort (int port) |
| change the base port | |
| int | firstRtcpPort () const |
| get the value of the first specified RTCP port or if no rtcp: attribute found, the default port() value. | |
| int | multicast () const |
| get the number of transport port pairs | |
| unsigned long & | multicast () |
| get the number of transport port pairs | |
| const Data & | protocol () const |
| return the transport protocol | |
| Data & | protocol () |
| return the transport protocol | |
| const CodecContainer & | codecs () const |
| preferred codec/format interface | |
| CodecContainer & | codecs () |
| void | clearCodecs () |
| remove all codecs from SDP | |
| void | addCodec (const Codec &codec) |
| add a codec to the m= line | |
| const std::list< Data > & | getFormats () const |
| return a list of codec formats | |
| const Data & | information () const |
| get optional i= (information) line contents | |
| Data & | information () |
| get optional i= (information) line contents | |
| const std::list< Bandwidth > & | bandwidths () const |
| get a list of bandwidth lines | |
| std::list< Bandwidth > & | bandwidths () |
| const std::list< Connection > | getConnections () const |
| get a list of Connection objects, including the Session's c= line. | |
| const std::list< Connection > & | getMediumConnections () const |
| get a list of Connection objects from the m= section. | |
| std::list< Connection > & | getMediumConnections () |
| const Encryption & | getEncryption () const |
| const Encryption & | encryption () const |
| Encryption & | encryption () |
| bool | exists (const Data &key) const |
| tests if an a= key is present in the media section | |
| const std::list< Data > & | getValues (const Data &key) const |
| get the attribute values corresponding to the key - returns the attributes set on this medium, with fallback to the session | |
| std::list< Data > | getMergedValues (const Data &key) const |
| get the attribute values corresponding to the key - returns both the attributes set on this medium, and those set on the session. | |
| void | clearAttribute (const Data &key) |
| erase all attributes for a given key | |
| const Codec & | findFirstMatchingCodecs (const CodecContainer &codecs, Codec *pMatchingCodec=0) const |
| const Codec & | findFirstMatchingCodecs (const Medium &medium, Codec *pMatchingCodec=0) const |
| const Codec & | findTelephoneEventPayloadCodec () const |
| finds the telephone-event codec | |
| int | findTelephoneEventPayloadType () const |
| finds the telephone-event payload type | |
| const Direction & | getDirection () const |
| const Direction & | getDirection (const Direction &sessionDefault) const |
Friends | |
| class | Session |
process m= (media announcement) blocks
Definition at line 635 of file SdpContents.hxx.
| typedef std::list<Codec> resip::SdpContents::Session::Medium::CodecContainer |
Definition at line 745 of file SdpContents.hxx.
| SdpContents::Session::Medium::Medium | ( | ) |
Definition at line 1531 of file SdpContents.cxx.
| SdpContents::Session::Medium::Medium | ( | const Medium & | rhs | ) |
Definition at line 1538 of file SdpContents.cxx.
| SdpContents::Session::Medium::Medium | ( | const Data & | name, |
| unsigned long | port, | ||
| unsigned long | multicast, | ||
| const Data & | protocol | ||
| ) |
Constructor.
| name | media type (audio, video, application, data, etc.) |
| port | UDP port that will receive RTP |
| multicast | a misnomer. If multicast > 1, the next (multicast) even ports will convey RTP and the next (multicast) odd ports will convey corresponding RTCP |
| protocol | the transport used to convey the media. Usually "RTP/AVP" for SIP. |
Definition at line 1519 of file SdpContents.cxx.
| void SdpContents::Session::Medium::addAttribute | ( | const Data & | key, |
| const Data & | value = Data::Empty |
||
| ) |
add a media attribute line
| key | attribute key |
| value | attribute value |
Definition at line 1833 of file SdpContents.cxx.
| void SdpContents::Session::Medium::addBandwidth | ( | const Bandwidth & | bandwidth | ) |
Definition at line 1827 of file SdpContents.cxx.
| void SdpContents::Session::Medium::addCodec | ( | const Codec & | codec | ) |
add a codec to the m= line
| codec | codec to add |
Definition at line 1923 of file SdpContents.cxx.
| void SdpContents::Session::Medium::addConnection | ( | const Connection & | connection | ) |
add a media connection line.
Optional if main SDP has c= line.
| connection | connection line to use |
Definition at line 1814 of file SdpContents.cxx.
| void SdpContents::Session::Medium::addFormat | ( | const Data & | format | ) |
add a format identifier to the m= line
This will need to be called for each codec used in the SDP.
| format | format identifier |
Definition at line 1801 of file SdpContents.cxx.
|
inline |
Definition at line 789 of file SdpContents.hxx.
|
inline |
get a list of bandwidth lines
Definition at line 788 of file SdpContents.hxx.
| void SdpContents::Session::Medium::clearAttribute | ( | const Data & | key | ) |
erase all attributes for a given key
| key | key to clear |
Definition at line 1904 of file SdpContents.cxx.
| void SdpContents::Session::Medium::clearCodecs | ( | ) |
remove all codecs from SDP
Definition at line 1914 of file SdpContents.cxx.
| SdpContents::Session::Medium::CodecContainer & SdpContents::Session::Medium::codecs | ( | ) |
Definition at line 1937 of file SdpContents.cxx.
| const SdpContents::Session::Medium::CodecContainer & SdpContents::Session::Medium::codecs | ( | ) | const |
preferred codec/format interface
Definition at line 1931 of file SdpContents.cxx.
| EncodeStream & SdpContents::Session::Medium::encode | ( | EncodeStream & | s | ) | const |
Definition at line 1718 of file SdpContents.cxx.
|
inline |
Definition at line 806 of file SdpContents.hxx.
|
inline |
Definition at line 805 of file SdpContents.hxx.
| bool SdpContents::Session::Medium::exists | ( | const Data & | key | ) | const |
tests if an a= key is present in the media section
| key | key to check |
Definition at line 1857 of file SdpContents.cxx.
| const Codec & SdpContents::Session::Medium::findFirstMatchingCodecs | ( | const CodecContainer & | codecs, |
| Codec * | pMatchingCodec = 0 |
||
| ) | const |
Definition at line 2009 of file SdpContents.cxx.
| const Codec & SdpContents::Session::Medium::findFirstMatchingCodecs | ( | const Medium & | medium, |
| Codec * | pMatchingCodec = 0 |
||
| ) | const |
Definition at line 2034 of file SdpContents.cxx.
| const Codec & SdpContents::Session::Medium::findTelephoneEventPayloadCodec | ( | ) | const |
finds the telephone-event codec
Definition at line 2047 of file SdpContents.cxx.
| int SdpContents::Session::Medium::findTelephoneEventPayloadType | ( | ) | const |
finds the telephone-event payload type
Definition at line 2061 of file SdpContents.cxx.
|
inline |
get the value of the first specified RTCP port or if no rtcp: attribute found, the default port() value.
RFC 3605.
Definition at line 719 of file SdpContents.hxx.
| const list< SdpContents::Session::Connection > SdpContents::Session::Medium::getConnections | ( | ) | const |
get a list of Connection objects, including the Session's c= line.
If the media's c= line is empty, use the Session's c= line.
Definition at line 1843 of file SdpContents.cxx.
| const SdpContents::Session::Direction & SdpContents::Session::Medium::getDirection | ( | ) | const |
Definition at line 1264 of file SdpContents.cxx.
| const SdpContents::Session::Direction & SdpContents::Session::Medium::getDirection | ( | const Direction & | sessionDefault | ) | const |
Definition at line 1286 of file SdpContents.cxx.
|
inline |
Definition at line 804 of file SdpContents.hxx.
|
inline |
return a list of codec formats
These formats correspond to RTP payload type identifiers
Definition at line 772 of file SdpContents.hxx.
|
inline |
Definition at line 803 of file SdpContents.hxx.
|
inline |
get a list of Connection objects from the m= section.
Does not include session c= line.
Definition at line 802 of file SdpContents.hxx.
get the attribute values corresponding to the key - returns both the attributes set on this medium, and those set on the session.
Attributes from this medium will be returned first in the list, followed by those from the session.
| key | key to check |
Definition at line 1883 of file SdpContents.cxx.
get the attribute values corresponding to the key - returns the attributes set on this medium, with fallback to the session
| key | key to check |
Definition at line 1867 of file SdpContents.cxx.
|
inline |
get optional i= (information) line contents
Definition at line 783 of file SdpContents.hxx.
|
inline |
get optional i= (information) line contents
Definition at line 778 of file SdpContents.hxx.
|
inline |
get the number of transport port pairs
Definition at line 732 of file SdpContents.hxx.
|
inline |
get the number of transport port pairs
Definition at line 727 of file SdpContents.hxx.
|
inline |
|
inline |
| SdpContents::Session::Medium & SdpContents::Session::Medium::operator= | ( | const Medium & | rhs | ) |
Definition at line 1559 of file SdpContents.cxx.
| void SdpContents::Session::Medium::parse | ( | ParseBuffer & | pb | ) |
Definition at line 1595 of file SdpContents.cxx.
|
inline |
|
inline |
|
inline |
return the transport protocol
Definition at line 742 of file SdpContents.hxx.
|
inline |
return the transport protocol
Definition at line 737 of file SdpContents.hxx.
| void SdpContents::Session::Medium::setBandwidth | ( | const Bandwidth & | bandwidth | ) |
Definition at line 1820 of file SdpContents.cxx.
| void SdpContents::Session::Medium::setConnection | ( | const Connection & | connection | ) |
set the media connection line.
Optional if main SDP has c= line.
| connection | connection line to use |
Definition at line 1807 of file SdpContents.cxx.
| void SdpContents::Session::Medium::setPort | ( | int | port | ) |
|
friend |
Definition at line 883 of file SdpContents.hxx.