CMceEvent Class Reference

class CMceEvent : public CBase

Base class for MCE events, inherited by both CMceInEvent and CMceOutEvent .

CMceEvent represents peer-to-peer connection made with remote terminal. This connection is also known as dialog and it is set up using SIP SUBSCRIBE method.

MCE events are typically used for queurying state of some parameter of remote terminal. The queuried parameter is known as event header. The changes of this parameter are notified to another terminal by sending SIP NOTIFY messages.

The event can be finally terminated by either endpoints.

If for any reason instance of this class is deleted while in active state, event is automatically terminated by MCE server.

mceclient.lib

Inherits from

Public Member Functions
~CMceEvent ()
IMPORT_C RPointerArray < CMceEvent > * AssociatedEventsL ()
IMPORT_C RPointerArray < CMceRefer > * AssociatedRefersL ()
IMPORT_C CMceSession * AssociatedSession ()
TUint32 DialogId ()
void ErrorOccuredL ( TInt )
IMPORT_C const TDesC8 & EventHeader ()
void EventReceivedL ( TMceIds &)
void EventReceivedL ( TMceIds &, CMceMsgBase &)
void EventReceivedL ( TMceIds &, CMceMsgBase &, HBufC8 *)
CMceItcSender & ITCSender ()
TUint32 Id ()
TBool IsInEvent ()
CMceManager & Manager ()
IMPORT_C const TDesC8 & Originator ()
TUint32 ProfileId ()
IMPORT_C const TDesC8 & Recipient ()
IMPORT_C TState State ()
IMPORT_C void TerminateL ( CDesC8Array *, HBufC8 *, HBufC8 *)
Protected Member Functions
CMceEvent ( CMceManager &, TUint32 , TUint32 , TUint32 )
void ConstructL ( HBufC8 *, HBufC8 *, HBufC8 *, TUint32 , CDesC8Array *)
void PrepareForITC ( TMceIds &)
Private Member Functions
void EventReceivedL ( TMceEvent &)
void HandleEventL ( TMceEvent &)
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()
Public Member Enumerations
enum TState { EIdle , EPending , EActive , ETerminated }
Protected Attributes
TUint32 iDialogId
HBufC8 * iEventHeader
TUint32 iId
CMceManager & iManager
HBufC8 * iOriginator
TUint32 iProfileId
CMceEventReceiver * iReceiver
HBufC8 * iRecipient
TUint32 iRefreshInterval
CMceItcSender * iSender
TState iState
Private Attributes
TAny * iReserved

Constructor & Destructor Documentation

CMceEvent(CMceManager &, TUint32, TUint32, TUint32)

CMceEvent ( CMceManager & aManager,
TUint32 aProfileId,
TUint32 aDialogId,
TUint32 aRefreshInterval
) [protected]

C++ default constructor.

Parameters

CMceManager & aManager
TUint32 aProfileId
TUint32 aDialogId
TUint32 aRefreshInterval

~CMceEvent()

~CMceEvent ( ) [virtual]

Destructor.

Member Functions Documentation

AssociatedEventsL()

IMPORT_C RPointerArray < CMceEvent > * AssociatedEventsL ( ) const

Returns the associated events, if any.

AssociatedRefersL()

IMPORT_C RPointerArray < CMceRefer > * AssociatedRefersL ( ) const

Returns the associated refers, if any.

AssociatedSession()

IMPORT_C CMceSession * AssociatedSession ( ) const

Returns the associated session, if any.

ConstructL(HBufC8 *, HBufC8 *, HBufC8 *, TUint32, CDesC8Array *)

void ConstructL ( HBufC8 * aEventHeader,
HBufC8 * aRecipient,
HBufC8 * aOriginator,
TUint32 aDialogType,
CDesC8Array * aParams
) [protected]

second-phase constructor

Parameters

HBufC8 * aEventHeader
HBufC8 * aRecipient
HBufC8 * aOriginator
TUint32 aDialogType
CDesC8Array * aParams

DialogId()

TUint32 DialogId ( ) const

Dialog ID

ErrorOccuredL(TInt)

void ErrorOccuredL ( TInt aError )

Handling of error

Parameters

TInt aError the error

EventHeader()

IMPORT_C const TDesC8 & EventHeader ( ) const

Returns the Event header.

EventReceivedL(TMceIds &)

void EventReceivedL ( TMceIds & aId )

Handles reception of event update

Parameters

TMceIds & aId id of object whose state is needed to be updated

EventReceivedL(TMceIds &, CMceMsgBase &)

void EventReceivedL ( TMceIds & aId,
CMceMsgBase & aMessage
)

Handles reception of event update

Parameters

TMceIds & aId id of object whose state is needed to be updated
CMceMsgBase & aMessage the message

EventReceivedL(TMceIds &, CMceMsgBase &, HBufC8 *)

void EventReceivedL ( TMceIds & aId,
CMceMsgBase & aMessage,
HBufC8 * aContent
)

Handles reception of event update

Parameters

TMceIds & aId id of object whose state is needed to be updated
CMceMsgBase & aMessage the message
HBufC8 * aContent the content

EventReceivedL(TMceEvent &)

void EventReceivedL ( TMceEvent & aEvent ) [private]

Traversal event handler

Parameters

TMceEvent & aEvent the event

HandleEventL(TMceEvent &)

void HandleEventL ( TMceEvent & aEvent ) [private]

Handles event

Parameters

TMceEvent & aEvent the event

ITCSender()

CMceItcSender & ITCSender ( )

Gets sender for ITC.

Id()

TUint32 Id ( ) const

ID

IsInEvent()

TBool IsInEvent ( ) const [pure virtual]

Gets the type of the event

Manager()

CMceManager & Manager ( )

Gets manager

Originator()

IMPORT_C const TDesC8 & Originator ( ) const

Returns the address of the originator

PrepareForITC(TMceIds &)

void PrepareForITC ( TMceIds & aId ) [protected]

Prepares ids for ITC

Parameters

TMceIds & aId ITC ids

ProfileId()

TUint32 ProfileId ( ) const

Gets SIP profile id.

Recipient()

IMPORT_C const TDesC8 & Recipient ( ) const

Returns the address of the recipient

State()

IMPORT_C TState State ( ) const

Returns the state of the event.

TerminateL(CDesC8Array *, HBufC8 *, HBufC8 *)

IMPORT_C void TerminateL ( CDesC8Array * aHeaders = 0,
HBufC8 * aContentType = 0,
HBufC8 * aContent = 0
)
Terminates the event.
Pre-condition
State() == CMceEvent::EActive
Post-condition
State() == CMCEvent::EPending
leave
KErrNotSupported if event cannot be terminated (e.g. event attached to a CMceOutRefer )

Parameters

CDesC8Array * aHeaders = 0
HBufC8 * aContentType = 0
HBufC8 * aContent = 0

Member Enumerations Documentation

Enum TState

Enumerators

EIdle
EPending
EActive
ETerminated

Member Data Documentation

TUint32 iDialogId

TUint32 iDialogId [protected]

dialog id

HBufC8 * iEventHeader

HBufC8 * iEventHeader [protected]

The event header

TUint32 iId

TUint32 iId [protected]

ID

CMceManager & iManager

CMceManager & iManager [protected]

Event manager,not owned

HBufC8 * iOriginator

HBufC8 * iOriginator [protected]

The originator

TUint32 iProfileId

TUint32 iProfileId [protected]

SIP profile id

CMceEventReceiver * iReceiver

CMceEventReceiver * iReceiver [protected]

Event receiver, owned

HBufC8 * iRecipient

HBufC8 * iRecipient [protected]

The recipient

TUint32 iRefreshInterval

TUint32 iRefreshInterval [protected]

The refresh interval

TAny * iReserved

TAny * iReserved [private]

CMceItcSender * iSender

CMceItcSender * iSender [protected]

Sender, owned

TState iState

TState iState [protected]