# SDPMediaDescription Class Reference

`#include <sdp.h>`

Inheritance diagram for SDPMediaDescription:

List of all members.

## Public Types

enum | Direction { Undefined = -1, Inactive, RecvOnly, SendOnly, SendRecv }

## Public Member Functions

| SDPMediaDescription (const OpalTransportAddress &address)
virtual void | PrintOn (ostream &strm) const
virtual void | PrintOn (const OpalTransportAddress &commonAddr, ostream &str) const
virtual bool | Decode (const PStringArray &tokens)
virtual bool | Decode (char key, const PString &value)
virtual bool | PostDecode ()
virtual PString | GetSDPMediaType () const=0
virtual PCaselessString | GetSDPTransportType () const=0
virtual const SDPMediaFormatList & | GetSDPMediaFormats () const
virtual OpalMediaFormatList | GetMediaFormats () const
virtual void | AddSDPMediaFormat (SDPMediaFormat *sdpMediaFormat)
virtual void | AddMediaFormat (const OpalMediaFormat &mediaFormat)
virtual void | AddMediaFormats (const OpalMediaFormatList &mediaFormats, const OpalMediaType &mediaType)
virtual void | SetAttribute (const PString &attr, const PString &value)
virtual void | SetDirection (const Direction &d)
virtual Direction | GetDirection () const
virtual const OpalTransportAddress & | GetTransportAddress () const
virtual PBoolean | SetTransportAddress (const OpalTransportAddress &t)
virtual WORD | GetPort () const
virtual OpalMediaType | GetMediaType () const
virtual unsigned | GetBandwidth (const PString &type) const
virtual void | SetBandwidth (const PString &type, unsigned value)
virtual void | RemoveSDPMediaFormat (const SDPMediaFormat &sdpMediaFormat)
virtual SDPMediaFormat * | CreateSDPMediaFormat (const PString &portString)=0
virtual PString | GetSDPPortList () const=0
virtual void | ProcessMediaOptions (SDPMediaFormat &sdpFormat, const OpalMediaFormat &mediaFormat)

## Protected Member Functions

virtual bool | PrintOn (ostream &strm, const PString &str) const
virtual SDPMediaFormat * | FindFormat (PString &str) const
virtual void | SetPacketTime (const PString &optionName, const PString &value)

## Protected Attributes

OpalTransportAddress | transportAddress
Direction | direction
WORD | port
WORD | portCount
OpalMediaType | mediaType
SDPMediaFormatList | formats
SDPBandwidth | bandwidth

## Member Enumeration Documentation

enum SDPMediaDescription::Direction

Enumerator:

  Undefined |
  Inactive |
  RecvOnly |
  SendOnly |
  SendRecv |

## Constructor & Destructor Documentation

SDPMediaDescription::SDPMediaDescription | ( | const OpalTransportAddress & | address | ) |

## Member Function Documentation

virtual void SDPMediaDescription::PrintOn | ( | ostream & | strm | ) | const`[virtual]`

virtual void SDPMediaDescription::PrintOn | ( | const OpalTransportAddress & | commonAddr,
|  | ostream & | str |
| ) |  |  | const`[virtual]`

virtual bool SDPMediaDescription::Decode | ( | const PStringArray & | tokens | ) | `[virtual]`

virtual bool SDPMediaDescription::Decode | ( | char | key,
|  | const PString & | value |
| ) |  |  | `[virtual]`

virtual bool SDPMediaDescription::PostDecode | ( |  | ) | `[virtual]`

virtual PString SDPMediaDescription::GetSDPMediaType | ( |  | ) | const`[pure virtual]`

Implemented in SDPAudioMediaDescription, SDPVideoMediaDescription, and SDPApplicationMediaDescription.

virtual PCaselessString SDPMediaDescription::GetSDPTransportType | ( |  | ) | const`[pure virtual]`

Implemented in SDPRTPAVPMediaDescription, and SDPApplicationMediaDescription.

virtual const SDPMediaFormatList& SDPMediaDescription::GetSDPMediaFormats | ( |  | ) | const`[inline, virtual]`

virtual OpalMediaFormatList SDPMediaDescription::GetMediaFormats | ( |  | ) | const`[virtual]`

virtual void SDPMediaDescription::AddSDPMediaFormat | ( | SDPMediaFormat * | sdpMediaFormat | ) | `[virtual]`

virtual void SDPMediaDescription::AddMediaFormat | ( | const OpalMediaFormat & | mediaFormat | ) | `[virtual]`

virtual void SDPMediaDescription::AddMediaFormats | ( | const OpalMediaFormatList & | mediaFormats,
|  | const OpalMediaType & | mediaType |
| ) |  |  | `[virtual]`

virtual void SDPMediaDescription::SetAttribute | ( | const PString & | attr,
|  | const PString & | value |
| ) |  |  | `[virtual]`

Reimplemented in SDPRTPAVPMediaDescription, and SDPAudioMediaDescription.

virtual void SDPMediaDescription::SetDirection | ( | const Direction & | d | ) | `[inline, virtual]`

virtual Direction SDPMediaDescription::GetDirection | ( |  | ) | const`[inline, virtual]`

virtual const OpalTransportAddress& SDPMediaDescription::GetTransportAddress | ( |  | ) | const`[inline, virtual]`

virtual PBoolean SDPMediaDescription::SetTransportAddress | ( | const OpalTransportAddress & | t | ) | `[virtual]`

virtual WORD SDPMediaDescription::GetPort | ( |  | ) | const`[inline, virtual]`

virtual OpalMediaType SDPMediaDescription::GetMediaType | ( |  | ) | const`[inline, virtual]`

virtual unsigned SDPMediaDescription::GetBandwidth | ( | const PString & | type | ) | const`[inline, virtual]`

virtual void SDPMediaDescription::SetBandwidth | ( | const PString & | type,
|  | unsigned | value |
| ) |  |  | `[inline, virtual]`

virtual void SDPMediaDescription::RemoveSDPMediaFormat | ( | const SDPMediaFormat & | sdpMediaFormat | ) | `[virtual]`

virtual SDPMediaFormat* SDPMediaDescription::CreateSDPMediaFormat | ( | const PString & | portString | ) | `[pure virtual]`

Implemented in SDPRTPAVPMediaDescription, and SDPApplicationMediaDescription.

virtual PString SDPMediaDescription::GetSDPPortList | ( |  | ) | const`[pure virtual]`

Implemented in SDPRTPAVPMediaDescription, and SDPApplicationMediaDescription.

virtual void SDPMediaDescription::ProcessMediaOptions | ( | SDPMediaFormat & | sdpFormat,
|  | const OpalMediaFormat & | mediaFormat |
| ) |  |  | `[virtual]`

virtual bool SDPMediaDescription::PrintOn | ( | ostream & | strm,
|  | const PString & | str |
| ) |  |  | const`[protected, virtual]`

Reimplemented in SDPRTPAVPMediaDescription, and SDPAudioMediaDescription.

virtual SDPMediaFormat* SDPMediaDescription::FindFormat | ( | PString & | str | ) | const`[protected, virtual]`

virtual void SDPMediaDescription::SetPacketTime | ( | const PString & | optionName,
|  | const PString & | value |
| ) |  |  | `[protected, virtual]`

## Member Data Documentation

OpalTransportAddress SDPMediaDescription::transportAddress `[protected]`

Direction SDPMediaDescription::direction `[protected]`

WORD SDPMediaDescription::port `[protected]`

WORD SDPMediaDescription::portCount `[protected]`

OpalMediaType SDPMediaDescription::mediaType `[protected]`

SDPMediaFormatList SDPMediaDescription::formats `[protected]`

SDPBandwidth SDPMediaDescription::bandwidth `[protected]`

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

- sdp.h