Symbian
Symbian OS Library

SYMBIAN OS V9.3

[Index] [Spacer] [Previous] [Next]



Location: SdpRtpmapValue.h
Link against: sdpcodec.lib

Class TSdpRtpmapValue

class TSdpRtpmapValue;

Description

Utility class for manipulating the value of an rtpmap-attribute.

The normative reference for correct formatting and values is draft-ietf-mmusic-sdp-new-14 unless specified otherwise in member documentation. The implementation supports this normative reference, but does not enforce it fully.

sdpcodec.lib

Members

Defined in TSdpRtpmapValue:
DecodeL(), EncodeL(), TSdpRtpmapValue()


Construction and destruction


TSdpRtpmapValue()

IMPORT_C TSdpRtpmapValue(const TPtrC8 &aEncodingName, const TPtrC8 &aClockrate, const TPtrC8 &aEncodingParameters);

Description

Initializes the instance to refer to the given rtpmap components. The parameters must stay in scope as long as this instance exists. Otherwise, the member variables of this class will point to a released memory.

Parameters

const TPtrC8 &aEncodingName

Valid rtpmap encoding name value.

const TPtrC8 &aClockrate

Valid rtpmap clockrate value.

const TPtrC8 &aEncodingParameters

Valid rtpmap encoding parameter list.

[Top]


Member functions


DecodeL()

static IMPORT_C TSdpRtpmapValue DecodeL(const TDesC8 &aText);

Description

Tries to parse a string as an rtpmap attribute value up to the end of the string or CRLF, whichever comes first, and set pointers to the components found. The parameter must stay in scope as long as this instance exists. Otherwise, the member variables of this class will point to a released memory.

Parameters

const TDesC8 &aText

String containing the value of an rtpmap attribute.

Return value

TSdpRtpmapValue

a new instance

Leave codes

KErrArgument

if parsing fails.


EncodeL()

IMPORT_C HBufC8 *EncodeL() const;

Description

Outputs the attribute value formatted according to SDP syntax. The field terminating CRLF is not included in the output. When constructing CSdpFmtAttributeField, return value of this function can be used as aValue in CSdpFmtAttributeField::NewL (RStringF aAttribute, const TDesC8& aFormat, const TDesC8& aValue) function.

Return value

HBufC8 *

Encoded value. Ovnership of buffer is changed to caller.