#include <mw/mtclreg.h>
class CClientMtmRegistry : public CObserverRegistry, public CObserverRegistry, public CObserverRegistry |
Public Member Functions | |
---|---|
~CClientMtmRegistry() | |
IMPORT_C CClientMtmRegistry * | NewL(CMsvSession &, TTimeIntervalMicroSeconds32) |
IMPORT_C CBaseMtm * | NewMtmL(TUid) |
Protected Member Functions | |
---|---|
CClientMtmRegistry(CMsvSession &, TTimeIntervalMicroSeconds32) | |
void | ConstructL() |
Inherited Enumerations | |
---|---|
MMsvSessionObserver:TMsvSessionEvent |
Accesses the Client-side MTM registry.
This registry holds details of the all the Client-side MTMs currently available on the system. Message client applications use this class to get a CBaseMtm-derived object by which to access Client-side MTM functionality.
Note that the base class CMtmDllRegistry provides functions for discovering what MTMs are present in the registry.
CClientMtmRegistry | ( | CMsvSession & | aMsvSession, |
TTimeIntervalMicroSeconds32 | aTimeoutMicroSeconds32 | ||
) | [protected] |
void | ConstructL | ( | ) | [protected] |
Reimplemented from CObserverRegistry::ConstructL()
Second-phase constructor.
IMPORT_C CClientMtmRegistry * | NewL | ( | CMsvSession & | aMsvSession, |
TTimeIntervalMicroSeconds32 | aTimeoutMicroSeconds32 = TTimeIntervalMicroSeconds32(30000000) | |||
) | [static] |
Gets a CClientMtmRegistry object. The client should delete this object when it is no longer required.
The registry keeps a reference count of the number of instances of each MTM in use. When that reference count falls to zero, the DLL that provides the MTM is unloaded. However, this is not done immediately, but only after the time specified in aTimeoutMicroSeconds32. This increases efficiency in cases where the DLL is required again shortly.
Parameters | |
---|---|
aMsvSession | The client's Message Server session |
aTimeoutMicroSeconds32 | Time to wait before unloading MTM DLLs |
Leave Codes | |
---|---|
KErrNoMemory | A memory allocation failed |
Creates a Client-side MTM object for the specified MTM UID.
The client should delete the returned object when it is no longer required.
Parameters | |
---|---|
aMtmTypeUid | UID of MTM to obtain |
Leave Codes | |
---|---|
KErrNotFound | aMtmTypeUid does not specify a registered MTM |
KErrNoMemory | A memory allocation failed |
KErrBadLibraryEntryPoint | Malformed MTM: a library entry point was not of the required type |
DLL | loading error codes The DLL that provides the MTM cannot be loaded |