CSIPURI Class Reference

class CSIPURI : public CBase

Class provides functions for setting and getting fields and parameters in the SIP-URI or SIPS-URI structure.

sipcodec.lib

Inherits from

Public Member Functions
~CSIPURI()
IMPORT_C voidAddURIHeaderL(const TDesC8 &, const TDesC8 &)
IMPORT_C CSIPURI *DecodeL(const TDesC8 &)
voidDeleteAllURIHeaders()
IMPORT_C voidDeleteParam(RStringF)
IMPORT_C voidDeletePassword()
IMPORT_C voidDeleteUserInfo()
IMPORT_C TBoolHasParam(RStringF)
IMPORT_C TBoolHasParams()
IMPORT_C TBoolHasURIHeaders(const TDesC8 &)
IMPORT_C const CSIPHostPort &HostPort()
IMPORT_C CSIPHostPort &HostPort()
IMPORT_C TBoolIsSIPSURI()
IMPORT_C RStringFParamValue(RStringF)
IMPORT_C const TDesC8 &Password()
IMPORT_C voidSetHostPortL(CSIPHostPort *)
IMPORT_C voidSetParamL(RStringF)
IMPORT_C voidSetParamL(RStringF, RStringF)
IMPORT_C voidSetPasswordL(const TDesC8 &)
IMPORT_C voidSetSIPS(TBool)
IMPORT_C voidSetTtlParamL(TInt)
IMPORT_C voidSetUserL(const TDesC8 &)
IMPORT_C HBufC8 *ToTextL()
IMPORT_C TIntTtlParam()
IMPORT_C CPtrC8Array *URIHeaderValuesL(const TDesC8 &)
IMPORT_C const TDesC8 &User()
IMPORT_C TBooloperator==(const CSIPURI &)
Private Member Functions
CSIPURI(TBool)
voidConstructL()
voidConstructL(const CSIPURI &)
voidLocateSeparatorL(const TDesC8 &, TChar, TInt &)
CSIPURI *NewL()
CSIPURI *NewL(const CSIPURI &)
CSIPURI *NewLC()
CSIPURI *NewLC(const CSIPURI &)
voidParseL(const TDesC8 &)
TPtrC8 ParseSipSchemeL(const TDesC8 &)
voidParseUserInfoL(const TDesC8 &)
voidSetURIHeaders(CSIPURIHeaders *)
voidSetURIParams(CSIPURIParams *)
Inherited Functions
CBase::CBase()
CBase::Delete(CBase *)
CBase::Extension_(TUint,TAny *&,TAny *)
CBase::operator new(TUint)
CBase::operator new(TUint,TAny *)
CBase::operator new(TUint,TLeave)
CBase::operator new(TUint,TLeave,TUint)
CBase::operator new(TUint,TUint)
CBase::~CBase()
Private Attributes
TBool iHasPassword
TBool iHasUser
CSIPHostPort *iHostPort
TBool iIsSIPSURI
HBufC8 *iPassword
CSIPURIHeaders *iURIHeaders
CSIPURIParams *iURIParams
HBufC8 *iUser

Constructor & Destructor Documentation

CSIPURI(TBool)

CSIPURI(TBoolaIsSIPSUri = EFalse)[private]

Parameters

TBool aIsSIPSUri = EFalse

~CSIPURI()

IMPORT_C~CSIPURI()

Destructor, deletes the resources of CSIPURI.

Member Functions Documentation

AddURIHeaderL(const TDesC8 &, const TDesC8 &)

IMPORT_C voidAddURIHeaderL(const TDesC8 &aName,
const TDesC8 &aValue
)

Adds a new URI header

Parameters

const TDesC8 & aNamethe name of a URI header
const TDesC8 & aValuethe value of a URI header

ConstructL()

voidConstructL()[private]

ConstructL(const CSIPURI &)

voidConstructL(const CSIPURI &aSIPURI)[private]

Parameters

const CSIPURI & aSIPURI

DecodeL(const TDesC8 &)

IMPORT_C CSIPURI *DecodeL(const TDesC8 &aValue)[static]

Constructs a CSIPURI from textual representation

Parameters

const TDesC8 & aValueSIP-URI or SIPS-URI as text

DeleteAllURIHeaders()

voidDeleteAllURIHeaders()

DeleteParam(RStringF)

IMPORT_C voidDeleteParam(RStringFaName)

Deletes a URI parameter

Parameters

RStringF aName

DeletePassword()

IMPORT_C voidDeletePassword()

Deletes the password part of userinfo structure

DeleteUserInfo()

IMPORT_C voidDeleteUserInfo()

Deletes the userinfo (user+password)

HasParam(RStringF)

IMPORT_C TBoolHasParam(RStringFaName)const

Checks if a URI parameter is present

Parameters

RStringF aNamethe name of the URI parameter

HasParams()

IMPORT_C TBoolHasParams()const

Checks if any parameters are present

HasURIHeaders(const TDesC8 &)

IMPORT_C TBoolHasURIHeaders(const TDesC8 &aName)const

Checks if named URI headers are present

Parameters

const TDesC8 & aNamethe name of the URI headers

HostPort()

IMPORT_C const CSIPHostPort &HostPort()const

Gets the hostport as const

HostPort()

IMPORT_C CSIPHostPort &HostPort()

Gets the hostport

IsSIPSURI()

IMPORT_C TBoolIsSIPSURI()const

Checks the scheme of this CSIPURI

LocateSeparatorL(const TDesC8 &, TChar, TInt &)

voidLocateSeparatorL(const TDesC8 &aValue,
TCharaSeparator,
TInt &aPosition
)const [private]

Parameters

const TDesC8 & aValue
TChar aSeparator
TInt & aPosition

NewL()

CSIPURI *NewL()[private, static]

NewL(const CSIPURI &)

CSIPURI *NewL(const CSIPURI &aSIPURI)[private, static]

Parameters

const CSIPURI & aSIPURI

NewLC()

CSIPURI *NewLC()[private, static]

NewLC(const CSIPURI &)

CSIPURI *NewLC(const CSIPURI &aSIPURI)[private, static]

Parameters

const CSIPURI & aSIPURI

ParamValue(RStringF)

IMPORT_C RStringFParamValue(RStringFaName)const
Gets the value of a URI parameter
Pre-condition
HasParam(aName) == ETrue

Parameters

RStringF aName

ParseL(const TDesC8 &)

voidParseL(const TDesC8 &aValue)[private]

Parameters

const TDesC8 & aValue

ParseSipSchemeL(const TDesC8 &)

TPtrC8 ParseSipSchemeL(const TDesC8 &aValue)[private]

Parameters

const TDesC8 & aValue

ParseUserInfoL(const TDesC8 &)

voidParseUserInfoL(const TDesC8 &aValue)[private]

Parameters

const TDesC8 & aValue

Password()

IMPORT_C const TDesC8 &Password()const

Gets the password part of userinfo structure

SetHostPortL(CSIPHostPort *)

IMPORT_C voidSetHostPortL(CSIPHostPort *aHostPort)
Sets the hostport
Pre-condition
aHostPort != 0

Parameters

CSIPHostPort * aHostPortthe ownership is transferred

SetParamL(RStringF)

IMPORT_C voidSetParamL(RStringFaName)

Sets a new URI parameter that does not have a value

Parameters

RStringF aNamethe name of a URI parameter

SetParamL(RStringF, RStringF)

IMPORT_C voidSetParamL(RStringFaName,
RStringFaValue
)

Sets a new URI parameter with a name and a value

Parameters

RStringF aNamethe name of a URI parameter
RStringF aValuethe value of a URI parameter

SetPasswordL(const TDesC8 &)

IMPORT_C voidSetPasswordL(const TDesC8 &aPassword)

Sets the password part of userinfo structure

Parameters

const TDesC8 & aPasswordthe password to set

SetSIPS(TBool)

IMPORT_C voidSetSIPS(TBoolaSIPS)

Sets the URI scheme to "sips"

Parameters

TBool aSIPSIf ETrue the scheme is set to "sips", if EFalse the scheme is set to "sip".

SetTtlParamL(TInt)

IMPORT_C voidSetTtlParamL(TIntaValue)
Sets the value of the "ttl" parameter
Pre-condition
aValue >= 0

Parameters

TInt aValuethe value of the "ttl" parameter

SetURIHeaders(CSIPURIHeaders *)

voidSetURIHeaders(CSIPURIHeaders *aURIHeaders)[private]

Parameters

CSIPURIHeaders * aURIHeaders

SetURIParams(CSIPURIParams *)

voidSetURIParams(CSIPURIParams *aURIParams)[private]

Parameters

CSIPURIParams * aURIParams

SetUserL(const TDesC8 &)

IMPORT_C voidSetUserL(const TDesC8 &aUser)

Sets the user part of userinfo structure

Parameters

const TDesC8 & aUserthe user to set

ToTextL()

IMPORT_C HBufC8 *ToTextL()const

Encodes the object into a textual representation.

TtlParam()

IMPORT_C TIntTtlParam()const

Gets the value of the "ttl" parameter

URIHeaderValuesL(const TDesC8 &)

IMPORT_C CPtrC8Array *URIHeaderValuesL(const TDesC8 &aName)const

Returns an array of URI headers with the given name. The header values are copies of the actual header values in the SIP-URI thus the actual values cannot be modified through the given array. Note that removing a header value from the array does NOT remove it from the SIP URI.

Parameters

const TDesC8 & aNamethe name of the URI headers

User()

IMPORT_C const TDesC8 &User()const

Gets the user part of userinfo structure

operator==(const CSIPURI &)

IMPORT_C TBooloperator==(const CSIPURI &aURI)const

Compares this object to another instance of CSIPURI

Parameters

const CSIPURI & aURIa SIP URI to compare to

Member Data Documentation

TBool iHasPassword

TBool iHasPassword[private]

TBool iHasUser

TBool iHasUser[private]

CSIPHostPort * iHostPort

CSIPHostPort *iHostPort[private]

TBool iIsSIPSURI

TBool iIsSIPSURI[private]

HBufC8 * iPassword

HBufC8 *iPassword[private]

CSIPURIHeaders * iURIHeaders

CSIPURIHeaders *iURIHeaders[private]

CSIPURIParams * iURIParams

CSIPURIParams *iURIParams[private]

HBufC8 * iUser

HBufC8 *iUser[private]