MTransactionUser Class Reference

class MTransactionUser

Transaction user interface for sending SIP messages, retrieving state of a particular transaction and detaching from transaction.

Constructor & Destructor Documentation

~MTransactionUser()

~MTransactionUser()[inline, virtual]

Member Functions Documentation

ClearTransactionOwner(TTransactionId)

TInt ClearTransactionOwner(TTransactionIdaTransactionId)const [pure virtual]

The transaction with the specified transaction id clears its MTransactionOwner callback and won't send any more events. Transaction won't be stopped prematurely, it runs silently to completion.

This function doesn't leave in case of error, as it is thought this function is usually also called from destructors.

Pre-condition
aTransactionId != KSIPEmptyTransactionId

Parameters

TTransactionId aTransactionIdIdentifies the transaction

ClearTransactionOwner(MTransactionOwner *)

TInt ClearTransactionOwner(MTransactionOwner *aObserver)const [pure virtual]

Transactions using the specified callback clear their MTransactionOwner callback and won't send any more events. Transactions won't be stopped prematurely, they run silently to completion.

This function doesn't leave in case of error, as it is thought this function is usually also called from destructors.

Pre-condition
aObserver != NULL

Parameters

MTransactionOwner * aObserverIN: Callback address. Ownership isn't transferred.

FreeResources(MSIPNATBindingObserver &)

voidFreeResources(MSIPNATBindingObserver &aSIPNATBindingObserver)[pure virtual]

Frees all the resources reserved for the observer.

Parameters

MSIPNATBindingObserver & aSIPNATBindingObservera observer

GetLocalAddress(TUint32, TInetAddr &)

voidGetLocalAddress(TUint32aIapId,
TInetAddr &aAddr
)const [pure virtual]

Obtain the local address associated with the given IAP identifier.

Parameters

TUint32 aIapIdIAP identifier
TInetAddr & aAddrLocal address will be written here

MakeTagL(TDes8 &)

voidMakeTagL(TDes8 &aTag)const [pure virtual]

Fills the descriptor with random characters.

Parameters

TDes8 & aTagDescriptor into which the random characters are added. The existing characters are not overwritten. Adds as many characters as there is space left in the aTag.

NextHopIP(const TTransactionId &, TInetAddr &)

TInt NextHopIP(const TTransactionId &aTransactionId,
TInetAddr &aAddr
)[pure virtual]

Obtains the next hop address associated with the given transaction id.

Parameters

const TTransactionId & aTransactionIdtransaction identifier
TInetAddr & aAddrLocal address will be written here

SendAndGetHeadersL(TTransactionId &, TRegistrationId, CSIPRequest *, MTransactionOwner *, CURIContainer &, const TSIPTransportParams &, TBool)

MTransactionHeaders *SendAndGetHeadersL(TTransactionId &aTransactionId,
TRegistrationIdaRegistrationId,
CSIPRequest *aRequest,
MTransactionOwner *aObserver,
CURIContainer &aRemoteTarget,
const TSIPTransportParams &aTransportParams,
TBoolaDeleteRequest
)[pure virtual]

Send a SIP request message. In case of error, function leaves and the ownership of the SIP Request isn't transferred.

Pre-condition
aRequest!=NULL
aObserver!=NULL

Parameters

TTransactionId & aTransactionIdIN: If the request is ACK, this parameter should be a TransactionId of the INVITE transaction. OUT: If the request is not ACK, a new transaction is created and its TransactionId is filled here.
TRegistrationId aRegistrationIdIN: a registration id by which TU tries to find an outbound proxy for the request.
CSIPRequest * aRequestIN: SIP request message. Ownership is transferred.
MTransactionOwner * aObserverIN: Callback where the transaction will send events. Ownership isn't transferred.
CURIContainer & aRemoteTargetIN: Remote target of the request.
const TSIPTransportParams & aTransportParamsIN: Transport parameters to be used when handing the request to SIP Connection Mgr.
TBool aDeleteRequestIf ETrue, TransactionUser will delete aRequest when the transaction ends. If EFalse, aRequest is not deleted by TransactionUser.

SendCancelL(TTransactionId, TTransactionId &, MTransactionOwner *)

voidSendCancelL(TTransactionIdaInviteTaId,
TTransactionId &aCancelTaId,
MTransactionOwner *aObserver
)[pure virtual]

Send a CANCEL request. In case of error, function leaves and the ownership of the aCancel isn't transferred. CANCEL can only be sent when the INVITE client transaction has received a provisional response, but hasn't yet received a final response.

Pre-condition
aCancel!=NULL
aObserver!=NULL

Parameters

TTransactionId aInviteTaIdTransactionId of the INVITE client transaction to be canceled.
TTransactionId & aCancelTaIdOUT: TransactionId of the transaction sending CANCEL
MTransactionOwner * aObserverIN: Callback where the CANCEL transaction will send events. Ownership isn't transferred.

SendL(TTransactionId &, TRegistrationId, CSIPRequest *, MTransactionOwner *, CURIContainer &, const TSIPTransportParams &, TBool)

voidSendL(TTransactionId &aTransactionId,
TRegistrationIdaRegistrationId,
CSIPRequest *aRequest,
MTransactionOwner *aObserver,
CURIContainer &aRemoteTarget,
const TSIPTransportParams &aTransportParams,
TBoolaDeleteRequest
)[pure virtual]

Send a SIP request message. In case of error, function leaves and the ownership of the SIP Request isn't transferred.

Pre-condition
aRequest!=NULL
aObserver!=NULL

Parameters

TTransactionId & aTransactionIdIN: If the request is ACK, this parameter should be a TransactionId of the INVITE transaction. OUT: If the request is not ACK, a new transaction is created and its TransactionId is filled here.
TRegistrationId aRegistrationIdIN: a registration id by which TU tries to find an outbound proxy for the request.
CSIPRequest * aRequestIN: SIP request message. Ownership is transferred.
MTransactionOwner * aObserverIN: Callback where the transaction will send events. Ownership isn't transferred.
CURIContainer & aRemoteTargetIN: Remote target of the request.
const TSIPTransportParams & aTransportParamsIN: Transport parameters to be used when handing the request to SIP Connection Mgr.
TBool aDeleteRequestIf ETrue, TransactionUser will delete aRequest when the transaction ends. If EFalse, aRequest is not deleted by TransactionUser.

SendL(TTransactionId, CSIPResponse *, const TSIPTransportParams &)

voidSendL(TTransactionIdaTransactionId,
CSIPResponse *aResponse,
const TSIPTransportParams &aTransportParams
)const [pure virtual]

Send a SIP response message, using an existing transaction. Fills From- and To-header and other transaction related headers if they are missing. In case of error, function leaves and the ownership of aResponse is NOT transferred.

Pre-condition
transaction identified by aTransactionId exists,
aResponse!=NULL

Parameters

TTransactionId aTransactionIdIdentifies the transaction
CSIPResponse * aResponseIN: SIP response message. The ownership is transferred.
const TSIPTransportParams & aTransportParamsIN: Transport parameters to be used when handing the response to SIP Connection Mgr.

SendL(TTransactionId, CSIPResponse *, MTransactionOwner *, const TSIPTransportParams &)

voidSendL(TTransactionIdaTransactionId,
CSIPResponse *aResponse,
MTransactionOwner *aNewObserver,
const TSIPTransportParams &aTransportParams
)const [pure virtual]

Send a SIP response using an existing transaction and specify a new callback for the transaction to use. Fills From- and To-header and other transaction related headers if they are missing. In case of error, function leaves and the ownership of aResponse is NOT transferred.

Pre-condition
transaction identified by aTransactionId exists
aResponse!=NULL
aNewObserver!=NULL

Parameters

TTransactionId aTransactionIdIdentifies the transaction
CSIPResponse * aResponseIN: SIP response message. Ownership transferred.
MTransactionOwner * aNewObserverIN: New callback replacing the existing callback used by the the transaction. Ownership isn't transferred.
const TSIPTransportParams & aTransportParamsIN: Transport parameters to be used when handing the response to SIP Connection Mgr.

TransactionHeadersL(TTransactionId)

MTransactionHeaders *TransactionHeadersL(TTransactionIdaTransactionId)const [pure virtual]

Retrieve the transaction related headers of the SIP message that created the transaction. Leaves if memory allocation for the requested headers fails.

Parameters

TTransactionId aTransactionIdthe transaction whose SIP headers are requested.

Member Enumerations Documentation

Enum TRandomStringLength

Enumerators

KTagLength = 20
KCallIDLength = 30