CSIPClientConnection Class Reference

class CSIPClientConnection : public CBase

Class provides functions for sending and receiving SIP requests and SIP responses. This class also provides functions for creating and destroying SIP dialogs, sending and receiving SIP requests and responses within SIP dialogs, canceling the SIP requests.

All SIP messages will be sent/received using connection (defined using IAP Id) given by the user.

If the preconditions or postconditions are not met the function will leave with KErrArgument error code.

Inherits from

  • CSIPClientConnection
Public Member Functions
~CSIPClientConnection()
CSIPFromHeader *AorL(TUint32)
CSIPCallIDHeader *CallIDL(TUint32)
TInt ConnectionErrorL()
CSIPContactHeader *ContactL(TUint32)
voidDetachClient()
voidFetchRegistrationsL(const CSIPRequestElements &, TUint32 &)
voidGetLocalAddrL(TInetAddr &)
TUint32 IapId()
RStringF LocalTagL(TUint32)
CSIPClientConnection *NewL(CSIPClient &, MSIPClientConnectionObserver &, TUint32)
CSIPClientConnection *NewLC(CSIPClient &, MSIPClientConnectionObserver &, TUint32)
CSIPRouteHeader *OutboundProxyL(TUint32)
voidRefreshConnection()
TUint RefreshIntervalL(TUint32)
TInt RemoveOutboundProxy(TUint32)
TInt ResetDialogState(TUint32)
voidSendAckL(TUint32, TUint32, const CSIPMessageElements *)
voidSendCancelL(TUint32, TUint32 &)
voidSendRegisterL(TUint32 &, const CSIPToHeader &, const CSIPFromHeader &, const CSIPMessageElements &, const CUri8 *, const CSIPRouteHeader *, TBool, TBool, TBool)
voidSendRequestAndCreateDialogL(TUint32 &, TUint32 &, TUint32 &, RStringF, const CUri8 &, const CSIPFromHeader *, const CSIPMessageElements *, const CSIPToHeader *, TUint32, TBool)
voidSendRequestAndTerminateRefreshL(TUint32, TUint32 &, const CSIPMessageElements *)
voidSendRequestAndUpdateRefreshL(TUint32, TUint32 &, const CSIPMessageElements *)
voidSendRequestL(const CSIPRequestElements &, TUint32 &, TUint32, TBool)
voidSendRequestWithinDialogL(TUint32, TUint32 &, TUint32 &, RStringF, const CSIPMessageElements *, TBool, TBool)
voidSendRequestWithinDialogL(TUint32, TUint32, TUint32 &, const CSIPMessageElements *)
voidSendResponseAndCreateDialogL(const CSIPResponseElements &, TUint32, TUint32 &, TUint32)
voidSendResponseL(const CSIPResponseElements &, TUint32)
voidSendResponseWithinDialogL(const CSIPResponseElements &, TUint32, TUint32, TBool)
voidSetOptL(TUint, TUint, const TDesC8 &)
voidSetOptL(TUint, TUint, TInt)
voidSetOutboundProxyL(TUint32, const CSIPRouteHeader &)
voidSetRefreshIntervalL(TUint32, TUint)
CSIPConnection::TState State()
TInt TerminateDialog(TUint32)
TInt TerminateDialogRefresh(TUint32, TUint32)
TInt TerminateRefresh(TUint32)
TInt TerminateRegistration(TUint32)
voidUnregisterL(TUint32, TUint32 &, const CSIPMessageElements *)
voidUpdateRegistrationL(TUint32, TUint32 &, const CSIPMessageElements *)
Private Member Functions
CSIPClientConnection(CSIPClient &, MSIPClientConnectionObserver &, TUint32)
voidCheckContactExpiresL(const CSIPMessageElements &)
voidCheckContactL(const CSIPMessageElements *)
voidCheckContactL(const CSIPMessageElements &)
voidCheckDialogCreationRequestL(const CSIPToHeader *, const CSIPFromHeader *, const CSIPMessageElements *, TUint32, TBool)
voidCheckExpiresHeaderL(const CSIPMessageElements *, TBool)
voidCheckExpiresHeaderL(const CSIPMessageElements &, TBool)
voidConstructL()
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 iAdded
CSIPClient &iClient
RSIPConnection *iConnection
RStringF iContactHeaderName
RStringF iExpiresHeaderName
TUint32 iIapId
MSIPClientConnectionObserver &iObserver
CSIPClientConnectionReceiver *iReceiver
CSIPITCSender *iSender
RStringF iTag

Constructor & Destructor Documentation

CSIPClientConnection(CSIPClient &, MSIPClientConnectionObserver &, TUint32)

CSIPClientConnection(CSIPClient &aClient,
MSIPClientConnectionObserver &aObserver,
TUint32aIapId
)[private]

Parameters

CSIPClient & aClient
MSIPClientConnectionObserver & aObserver
TUint32 aIapId

~CSIPClientConnection()

~CSIPClientConnection()

Destructor

Member Functions Documentation

AorL(TUint32)

CSIPFromHeader *AorL(TUint32aRegistrationId)

Gets the AOR for a given registration id. Leaves on failure with a system wide or a SIP stack specific error code.

Parameters

TUint32 aRegistrationIdthe value of the registration-Id that was returned in a response to an earlier REGISTER request. This value is used to identify the binding for which the AOR is to be fetched.

CallIDL(TUint32)

CSIPCallIDHeader *CallIDL(TUint32aDialogId)

Gets the Call-ID for a given dialog id. Leaves on failure with a system wide or a SIP stack specific error code.

Parameters

TUint32 aDialogIda dialog id

CheckContactExpiresL(const CSIPMessageElements &)

voidCheckContactExpiresL(const CSIPMessageElements &aElements)const [private]

Parameters

const CSIPMessageElements & aElements

CheckContactL(const CSIPMessageElements *)

voidCheckContactL(const CSIPMessageElements *aElements)const [private]

Parameters

const CSIPMessageElements * aElements

CheckContactL(const CSIPMessageElements &)

voidCheckContactL(const CSIPMessageElements &aElements)const [private]

Parameters

const CSIPMessageElements & aElements

CheckDialogCreationRequestL(const CSIPToHeader *, const CSIPFromHeader *, const CSIPMessageElements *, TUint32, TBool)

voidCheckDialogCreationRequestL(const CSIPToHeader *aTo,
const CSIPFromHeader *aFrom,
const CSIPMessageElements *aElements,
TUint32aRegistrationId,
TBoolaRefresh = EFalse
)[private]

Parameters

const CSIPToHeader * aTo
const CSIPFromHeader * aFrom
const CSIPMessageElements * aElements
TUint32 aRegistrationId
TBool aRefresh = EFalse

CheckExpiresHeaderL(const CSIPMessageElements *, TBool)

voidCheckExpiresHeaderL(const CSIPMessageElements *aElements,
TBoolaZeroAllowed = EFalse
)const [private]

Parameters

const CSIPMessageElements * aElements
TBool aZeroAllowed = EFalse

CheckExpiresHeaderL(const CSIPMessageElements &, TBool)

voidCheckExpiresHeaderL(const CSIPMessageElements &aElements,
TBoolaZeroAllowed = EFalse
)const [private]

Parameters

const CSIPMessageElements & aElements
TBool aZeroAllowed = EFalse

ConnectionErrorL()

TInt ConnectionErrorL()const

Returns the connection error code

ConstructL()

voidConstructL()[private]

ContactL(TUint32)

CSIPContactHeader *ContactL(TUint32aRegistrationId)

Gets the Contact-header that has been registered with the given registration id.

Parameters

TUint32 aRegistrationIdthe value of the registration-Id that was returned in a response to an earlier REGISTER request. This value is used to identify the binding for which the Contact-header is to be fetched.

DetachClient()

voidDetachClient()

Clear the link from CSIPClientConnection to CSIPClient.

FetchRegistrationsL(const CSIPRequestElements &, TUint32 &)

voidFetchRegistrationsL(const CSIPRequestElements &aElements,
TUint32 &aRequestId
)

Creates SIP REGISTER request and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. User must NOT set any expires values to the request (aMessageOptionalElements).

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
!aElements.RemoteURI()->HasUser()
aElements.ToHeader().SIPAddress().URI().HasUser()
"Contact-headers".Count() == 0

Parameters

const CSIPRequestElements & aElementscontains remote address and optionally SIP message headers and body.
TUint32 & aRequestIdthe returned request Id, to be used to match a response to this request.

GetLocalAddrL(TInetAddr &)

voidGetLocalAddrL(TInetAddr &aAddr)const
Gets the local IP address used for this CSIPClientConnection when sending SIP messages to the network.
Pre-condition
State() == EActive
leave
A system-wide error codes

Parameters

TInetAddr & aAddrlocal IP for this CSIPClientConnection.

IapId()

TUint32 IapId()const

Gets the IAP id of this connection

LocalTagL(TUint32)

RStringF LocalTagL(TUint32aDialogId)

Gets the local tag for a given dialog id. Leaves on failure with a system wide or a SIP stack specific error code.

Parameters

TUint32 aDialogIda dialog id

NewL(CSIPClient &, MSIPClientConnectionObserver &, TUint32)

CSIPClientConnection *NewL(CSIPClient &aClient,
MSIPClientConnectionObserver &aObserver,
TUint32aIapId
)[static]

Constructs an instance of CSIPClientConnection The connection using IAP-Id is initialized during construction.

Parameters

CSIPClient & aClienta handle to SIP server session
MSIPClientConnectionObserver & aObserveran observer for receiving notifications
TUint32 aIapIdIAP Id that will be used for the connection.

NewLC(CSIPClient &, MSIPClientConnectionObserver &, TUint32)

CSIPClientConnection *NewLC(CSIPClient &aClient,
MSIPClientConnectionObserver &aObserver,
TUint32aIapId
)[static]

Constructs an instance of CSIPClientConnection and adds a pointer to it to the CleanupStack The connection using IAP-Id is initialized during construction.

Parameters

CSIPClient & aClienta handle to SIP server session
MSIPClientConnectionObserver & aObserveran observer for receiving notifications
TUint32 aIapIdIAP Id that will be used for the connection.

OutboundProxyL(TUint32)

CSIPRouteHeader *OutboundProxyL(TUint32aRegistrationId)

Gets the Outbound Proxy as set by any application for an AOR. Leaves on failure with a system wide or a SIP stack specific error code. Applications should retrieve this value first and examine if outbound proxy address, for the particular AOR, is suitable before sending SIP requests to the sip stack. If not suitable, the application may add a Route-header to the SIP Request in order to override this setting for that particular request.

Parameters

TUint32 aRegistrationIdthe value of the registration-Id that was returned in a response to an earlier REGISTER request. This value is used to identify the binding for which the outbound proxy setting is to be fetched.

RefreshConnection()

voidRefreshConnection()const

Refreshes the connection

RefreshIntervalL(TUint32)

TUint RefreshIntervalL(TUint32aRefreshId)

Parameters

TUint32 aRefreshId

RemoveOutboundProxy(TUint32)

TInt RemoveOutboundProxy(TUint32aRegistrationId)

Removes the outbound proxy which was used for the particular AOR.

Parameters

TUint32 aRegistrationIdthe value of the registration-Id that was returned in a response to an earlier REGISTER request. This value is used to identify the binding for which the outbound proxy setting is to be removed.

ResetDialogState(TUint32)

TInt ResetDialogState(TUint32aDialogId)

Parameters

TUint32 aDialogId

SendAckL(TUint32, TUint32, const CSIPMessageElements *)

voidSendAckL(TUint32aDialogId,
TUint32aRequestId,
const CSIPMessageElements *aElements = 0
)

Creates SIP ACK request within a dialog and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code.

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
aElements.OptionalElements()->ContactHeaders().Count() == 0

Parameters

TUint32 aDialogIdthe value of the Dialog-Id that was returned in a response to an earlier INVITE, that created the dialog.
TUint32 aRequestIdthe value of the INVITE Request-Id.
const CSIPMessageElements * aElements = 0contains optional SIP message headers and body.

SendCancelL(TUint32, TUint32 &)

voidSendCancelL(TUint32aInviteRequestId,
TUint32 &aCancelRequestId
)

Creates SIP CANCEL request for an existing INVITE request and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code.

Parameters

TUint32 aInviteRequestIdthe id of the INVITE request to be cancelled.
TUint32 & aCancelRequestIdthe id to be created for the CANCEL request.

SendRegisterL(TUint32 &, const CSIPToHeader &, const CSIPFromHeader &, const CSIPMessageElements &, const CUri8 *, const CSIPRouteHeader *, TBool, TBool, TBool)

voidSendRegisterL(TUint32 &aRequestId,
const CSIPToHeader &aTo,
const CSIPFromHeader &aFrom,
const CSIPMessageElements &aElements,
const CUri8 *aRemoteUri = 0,
const CSIPRouteHeader *aOutboundProxy = 0,
TBoolaRefresh = EFalse,
TBoolaSendWithExpires = ETrue,
TBoolaCacheOutboundProxyIP = EFalse
)

Creates SIP REGISTER request and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code This function call creates a registration binding. The Registration-Id for this REGISTER is returned with a future 2xx response received for this REGISTER. A 2xx response to this REGISTER creates a binding. There MUST NOT be more than one Contact-header and it MUST NOT be set to STAR.

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
aTo.SIPAddress().URI().HasUser()
!aTo.HasTag()
!aFrom.HasTag()
aRemoteUri->IsSIPURI()

Parameters

TUint32 & aRequestIdthe returned request Id, to be used to match a response to this request.
const CSIPToHeader & aToa From-header
const CSIPFromHeader & aFrom
const CSIPMessageElements & aElementscontains optional SIP message headers and body.
const CUri8 * aRemoteUri = 0a remote-URI. The ownership is NOT transferred.
const CSIPRouteHeader * aOutboundProxy = 0the outbound proxy address. The ownership is NOT transferred.
TBool aRefresh = EFalserefresh flag. Refreshing of this REGISTER is requested from the SIP Stack by setting this flag to ETrue.
TBool aSendWithExpires = ETruewhen set to EFalse REGISTER message is sent without expires value
TBool aCacheOutboundProxyIP = EFalsewhen set to ETrue outbound proxy IP of REGISTER message is cached in registration context

SendRequestAndCreateDialogL(TUint32 &, TUint32 &, TUint32 &, RStringF, const CUri8 &, const CSIPFromHeader *, const CSIPMessageElements *, const CSIPToHeader *, TUint32, TBool)

voidSendRequestAndCreateDialogL(TUint32 &aRequestId,
TUint32 &aRefreshId,
TUint32 &aDialogId,
RStringFaMethod,
const CUri8 &aRemoteUri,
const CSIPFromHeader *aFrom,
const CSIPMessageElements *aElements = 0,
const CSIPToHeader *aTo = 0,
TUint32aRegistrationId = 0,
TBoolaRefresh = EFalse
)

Creates a SIP request and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. The Dialog-Id for this request is returned with a future 2xx response received for this request. This provokes the Non-invite state machine The registration Id is used to select the outbound proxy. There MUST NOT be more than one Contact-header and it MUST NOT be set to STAR.

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
aMethod.Length() > 0
aMethod != "REGISTER" | "OPTIONS" | "BYE" | "CANCEL" | "ACK" | "NOTIFY" | "MESSAGE" | "PRACK" | "UPDATE"
aRemoteUri->IsSIPURI()
!aTo->HasTag()
!aFrom.HasTag()

Parameters

TUint32 & aRequestIdthe returned request Id, to be used to match a response to this request.
TUint32 & aRefreshIdif the request is refresh, contains on return the id of the created refresh.
TUint32 & aDialogIdthe returned dialog Id of the establishing dialog
RStringF aMethodthe method
const CUri8 & aRemoteUria remote-URI.
const CSIPFromHeader * aFroma From-header. If not given, aRegistrationId must be given, so that the stack can fill in the From-header based on it. The ownership is NOT transferred.
const CSIPMessageElements * aElements = 0contains optional SIP message headers and body.
const CSIPToHeader * aTo = 0a To-header. The ownership is NOT transferred.
TUint32 aRegistrationId = 0registration id for the sender's AOR
TBool aRefresh = EFalserefresh flag. Refreshing of this SIP request is requested from the SIP Stack by setting this flag to ETrue.

SendRequestAndTerminateRefreshL(TUint32, TUint32 &, const CSIPMessageElements *)

voidSendRequestAndTerminateRefreshL(TUint32aRefreshId,
TUint32 &aNewRequestId,
const CSIPMessageElements *aElements = 0
)

Sends a SIP request and terminates the refresh after sending the request. The method and To- and From-headers from the original request will be used. Leaves on failure with a system wide or a SIP stack specific error code. Any SIP response (2xx - 6xx) to this request terminates a refresh.

Parameters

TUint32 aRefreshIdthe value of the refresh-Id that was returned in a response to an earlier request that created the refresh.
TUint32 & aNewRequestIdthe returned request Id, to be used to match a response to this request.
const CSIPMessageElements * aElements = 0contains optional SIP message headers and body.

SendRequestAndUpdateRefreshL(TUint32, TUint32 &, const CSIPMessageElements *)

voidSendRequestAndUpdateRefreshL(TUint32aRefreshId,
TUint32 &aNewRequestId,
const CSIPMessageElements *aElements = 0
)
Sends a SIP request and updates an existing refresh. The method and To- and From-headers from the original request will be used. Leaves on failure with a system wide or a SIP stack specific error code.
Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.

Parameters

TUint32 aRefreshIdthe value of the refresh-Id that was returned in a response to an earlier request that created the refresh.
TUint32 & aNewRequestIdthe returned request Id, to be used to match a response to this request.
const CSIPMessageElements * aElements = 0contains optional SIP message headers and body.

SendRequestL(const CSIPRequestElements &, TUint32 &, TUint32, TBool)

voidSendRequestL(const CSIPRequestElements &aElements,
TUint32 &aRequestId,
TUint32aRegistrationId = 0,
TBoolaRefresh = EFalse
)

Creates SIP request and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. Function returns an error if a SIP request with a known method as defined in preconditions is sent. This provokes the Non-invite state machine. The registration Id is used to select the outbound proxy.

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
aRequestElements.Method() != "REGISTER" | "OPTIONS" | "INVITE" | "BYE" | "CANCEL" | "ACK" | "SUBSCRIBE" | "NOTIFY" | "REFER" | "MESSAGE".

Parameters

const CSIPRequestElements & aElementscontains local and remote addresses, optional SIP message headers and body.
TUint32 & aRequestIdthe returned request Id, to be used to match a response to this request.
TUint32 aRegistrationId = 0registration id for the sender's AOR
TBool aRefresh = EFalserefresh flag. Refreshing of the SIP request is requested from the SIP Stack by setting this flag to ETrue.

SendRequestWithinDialogL(TUint32, TUint32 &, TUint32 &, RStringF, const CSIPMessageElements *, TBool, TBool)

voidSendRequestWithinDialogL(TUint32aDialogId,
TUint32 &aNewRequestId,
TUint32 &aRefreshId,
RStringFaMethod,
const CSIPMessageElements *aElements = 0,
TBoolaTargetRefresh = EFalse,
TBoolaRefresh = EFalse
)

Creates a SIP request within a dialog and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. Contact header SHOULD NOT be created unless user intends to redirect the future requests within this dialog to a different remote target. Contact-header MUST NOT be set if aTargetRefresh flag is EFalse. This provokes the Non-invite state machine

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
aMethod.Length() > 0
aMethod != "REGISTER" | "CANCEL" | "ACK"

Parameters

TUint32 aDialogIdthe value of the Dialog-Id that was returned in a response to an earlier request that created the dialog.
TUint32 & aNewRequestIdthe returned request Id, to be used to match a response to this request.
TUint32 & aRefreshIdif the request is refresh, contains on return the id of the created refresh.
RStringF aMethodthe method of the request
const CSIPMessageElements * aElements = 0contains optional SIP message headers and body.
TBool aTargetRefresh = EFalseindicates if an unknown request is a target refresh request.
TBool aRefresh = EFalserefresh flag. Refreshing of this SIP request is requested from the SIP Stack by setting this flag to ETrue.

SendRequestWithinDialogL(TUint32, TUint32, TUint32 &, const CSIPMessageElements *)

voidSendRequestWithinDialogL(TUint32aDialogId,
TUint32aRefreshId,
TUint32 &aNewRequestId,
const CSIPMessageElements *aElements
)

Creates a SIP request within a dialog and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. Contact-header MUST NOT be set. pdates an existing refresh within a dialog. This function can also be used to terminate an existing refresh by setting the Expires-header's value to zero. Expires header is mandatory.

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
aMethod.Length() > 0

Parameters

TUint32 aDialogIdthe value of the Dialog-Id that was returned in a response to an earlier request that created the dialog.
TUint32 aRefreshIdthe value of the Refresh-Id that was returned in a response to an earlier request that created the refresh.
TUint32 & aNewRequestIdthe returned request Id, to be used to match a response to this request.
const CSIPMessageElements * aElementscontains optional SIP message headers and body.

SendResponseAndCreateDialogL(const CSIPResponseElements &, TUint32, TUint32 &, TUint32)

voidSendResponseAndCreateDialogL(const CSIPResponseElements &aElements,
TUint32aRequestId,
TUint32 &aDialogId,
TUint32aRegistrationId
)

Creates SIP response and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. This response creates a dialog.

Parameters

const CSIPResponseElements & aElementscontains Status Code, optional Reason Phrase and optional SIP message headers and body.
TUint32 aRequestIdthe value of the request id as returned by an earlier received request. This value is used to identify the request to which this response is for.
TUint32 & aDialogIda dialog id of the dialog that this response creates.
TUint32 aRegistrationIdregistration id

SendResponseL(const CSIPResponseElements &, TUint32)

voidSendResponseL(const CSIPResponseElements &aElements,
TUint32aRequestId
)

Creates SIP response and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. This response does not create a dialog. This function MUST be used only if the request received had no Dialog-Id.

Parameters

const CSIPResponseElements & aElementscontains Status Code, optional Reason Phrase and optional SIP message headers and body.
TUint32 aRequestIdthe value of the request id as returned by an earlier request. The value is used to identify the request to which this response is for.

SendResponseWithinDialogL(const CSIPResponseElements &, TUint32, TUint32, TBool)

voidSendResponseWithinDialogL(const CSIPResponseElements &aElements,
TUint32aRequestId,
TUint32aDialogId,
TBoolaTargetRefresh = EFalse
)

Creates SIP response to a request that is within a dialog and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. Contact-header MUST NOT be set if aTargetRefresh flag is EFalse.

Parameters

const CSIPResponseElements & aElementscontains Status Code, optional Reason Phrase and optional SIP message headers and body.
TUint32 aRequestIdthe value of the request id as returned by an earlier received request. This value identifies the request to which this response is for.
TUint32 aDialogIdthe value of the dialog id as returned by an earlier received response. This value identifies the dialog to which this response is for.
TBool aTargetRefresh = EFalseindicates if a received request sent within a dialog was a target refresh request.

SetOptL(TUint, TUint, const TDesC8 &)

voidSetOptL(TUintaOptionName,
TUintaOptionLevel,
const TDesC8 &aOption =  KNullDesC8
)
Sets a RSocket option used for all the sockets used for sending SIP requests and responses in this CSIPConnection.
Pre-condition
State() == EActive
leave
A system-wide error code

Parameters

TUint aOptionNameAn integer constant which identifies an option.
TUint aOptionLevelAn integer constant which identifies level of an option.
const TDesC8 & aOption =  KNullDesC8 Option value packaged in a descriptor.

SetOptL(TUint, TUint, TInt)

voidSetOptL(TUintaOptionName,
TUintaOptionLevel,
TIntaOption
)
Sets a RSocket option used for all the sockets used for sending SIP requests and responses in this CSIPConnection.
Pre-condition
State() == EActive
leave
A system-wide error codes

Parameters

TUint aOptionNameAn integer constant which identifies an option.
TUint aOptionLevelAn integer constant which identifies level of an option.
TInt aOptionOption value as an integer.

SetOutboundProxyL(TUint32, const CSIPRouteHeader &)

voidSetOutboundProxyL(TUint32aRegistrationId,
const CSIPRouteHeader &aOutboundProxy
)

Sets the Outbound Proxy for a registration binding.

Parameters

TUint32 aRegistrationIdthe value of the registration-Id that was returned in a response to an earlier REGISTER request. This value is used to identify the binding for which the outbound proxy setting is to be set.
const CSIPRouteHeader & aOutboundProxyan outbound proxy.

SetRefreshIntervalL(TUint32, TUint)

voidSetRefreshIntervalL(TUint32aRefreshId,
TUintaInterval
)

Parameters

TUint32 aRefreshId
TUint aInterval

State()

CSIPConnection::TState State()const

Gets the current state of the connection

TerminateDialog(TUint32)

TInt TerminateDialog(TUint32aDialogId)

Terminates a dialog. This function can be used to terminate a dialog abnormally or when the dialog does not have any more associations (E.g. After receiving a final response to a BYE request).

Parameters

TUint32 aDialogIddialog id for the dialog to be terminated.

TerminateDialogRefresh(TUint32, TUint32)

TInt TerminateDialogRefresh(TUint32aDialogId,
TUint32aRefreshId
)

Parameters

TUint32 aDialogId
TUint32 aRefreshId

TerminateRefresh(TUint32)

TInt TerminateRefresh(TUint32aRefreshId)

Terminates a refresh abnormally.

Parameters

TUint32 aRefreshIdrefresh id of the refresh to be terminated.

TerminateRegistration(TUint32)

TInt TerminateRegistration(TUint32aId)

Parameters

TUint32 aId

UnregisterL(TUint32, TUint32 &, const CSIPMessageElements *)

voidUnregisterL(TUint32aRegistrationId,
TUint32 &aNewRequestId,
const CSIPMessageElements *aElements = 0
)

Creates SIP (un)REGISTER request and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. User must NOT set any expires values in the SIP REGISTER request (aSIPMessageOptionalElements). Any SIP response (2xx - 6xx) to this request removes a binding.

Pre-condition
CSIPConnection::State() == CSIPConnection::EActive.
"Contact-headers".Count() == 0

Parameters

TUint32 aRegistrationIdthe value of the registration-Id that was returned in a response, to an earlier REGISTER, that created the binding. This value is used to identify the binding to be removed.
TUint32 & aNewRequestIdthe returned request Id, to be used to match a response to this request.
const CSIPMessageElements * aElements = 0contains optional SIP message headers and body.

UpdateRegistrationL(TUint32, TUint32 &, const CSIPMessageElements *)

voidUpdateRegistrationL(TUint32aRegistrationId,
TUint32 &aNewRequestId,
const CSIPMessageElements *aElements = 0
)

Creates SIP (update) REGISTER request and sends it to the given destination. Leaves on failure with a system wide or a SIP stack specific error code. User of this function does not need to, but can, set a new expires values in the expires-param of the SIP REGISTER request. This is done to update the refresh interval. A 2xx response to this request updates a binding as well as the refresh interval.

Parameters

TUint32 aRegistrationIdthe value of the registration-Id that was returned in a response, to an earlier REGISTER, that created the binding. This value is used to identify the binding to be updated.
TUint32 & aNewRequestIdthe returned request Id, to be used to match a response to this request.
const CSIPMessageElements * aElements = 0contains optional SIP message headers and body.

Member Data Documentation

TBool iAdded

TBool iAdded[private]

CSIPClient & iClient

CSIPClient &iClient[private]

RSIPConnection * iConnection

RSIPConnection *iConnection[private]

RStringF iContactHeaderName

RStringF iContactHeaderName[private]

RStringF iExpiresHeaderName

RStringF iExpiresHeaderName[private]

TUint32 iIapId

TUint32 iIapId[private]

MSIPClientConnectionObserver & iObserver

MSIPClientConnectionObserver &iObserver[private]

CSIPClientConnectionReceiver * iReceiver

CSIPClientConnectionReceiver *iReceiver[private]

CSIPITCSender * iSender

CSIPITCSender *iSender[private]

RStringF iTag

RStringF iTag[private]