class CMTPDataProviderController : public CActive |
Implements the MTP framework data provider controller singleton. This is a container class responsible for loading, storing, and managing CMTPDataProviderPlugin instances and their associated CMTPDataProvider bindings. The ECOM framework is used to load data CMTPDataProviderPlugin instances when instructed to do so by the MTP framework, either on start-up or when a mode switch occurs.
Public Member Functions | |
---|---|
~CMTPDataProviderController() | |
IMPORT_C TUint | Count() |
IMPORT_C CMTPDataProvider & | DataProviderByIndexL(TUint) |
IMPORT_C CMTPDataProvider & | DataProviderL(TUint) |
IMPORT_C TInt | DeviceDpId() |
IMPORT_C TInt | DpId(TUint) |
IMPORT_C TUint | EnumerateState() |
void | EnumerationStateChangedL(const CMTPDataProvider &) |
IMPORT_C void | ExecutePendingRequestL() |
IMPORT_C TInt | FileDpId() |
TBool | FreeEnumerationWaiter() |
IMPORT_C TBool | IsDataProviderLoaded(TUint) |
IMPORT_C void | LoadDataProvidersL() |
TMTPOperationalMode | Mode() |
IMPORT_C TBool | NeedEnumeratingPhase2() |
CMTPDataProviderController * | NewL() |
IMPORT_C void | NotifyDataProvidersL(TMTPNotification, const TAny *) |
IMPORT_C void | NotifyDataProvidersL(TUint, TMTPNotification, const TAny *) |
IMPORT_C TInt | ProxyDpId() |
IMPORT_C void | RegisterPendingRequestDP(TUint, TUint) |
IMPORT_C void | SetNeedEnumeratingPhase2(TBool) |
IMPORT_C TUint | StorageEnumerateState(TUint) |
IMPORT_C void | UnloadDataProviders() |
IMPORT_C void | WaitForEnumerationComplete() |
Private Member Functions | |
---|---|
CMTPDataProviderController() | |
void | CloseRegistrySessionAndEntryL() |
void | ConstructL() |
CMTPDataProviderConfig * | CreateConfigLC(const TDesC &) |
void | CreateRegistrySessionAndEntryL() |
void | DoCancel() |
void | EnumerateDataProviderObjectsL(TUint) |
void | EstablishDBSnapshotL(TUint32) |
void | ImplementationsCleanup(TAny *) |
TInt | ImplementationsLinearOrderUid(const TUid *, const CImplementationInformation &) |
TInt | ImplementationsLinearOrderUid(const CImplementationInformation &, const CImplementationInformation &) |
TBool | IsObjectsEnumerationNeededL(CMTPDataProvider &) |
TBool | LoadDataProviderL(const TDesC &) |
void | LoadInstalledDataProvidersL(const CImplementationInformation *) |
TBool | LoadROMDataProvidersL(const TDesC &, const RImplInfoPtrArray &) |
TInt | RunError(TInt) |
void | RunL() |
void | Schedule() |
TInt | Uid(const TDesC &, TUint &) |
Public Member Enumerations | |
---|---|
enum | TEnumerationStates { EUnenumerated = 0, EEnumerationStarting = 1, EEnumeratingFrameworkStorages = 2, EEnumeratingDataProviderStorages = 3, EEnumeratingFrameworkObjects = 4, EEnumeratingDataProviderObjects = 5, EEnumeratingPhaseOneDone = 6, EEnumeratingSubDirFiles = 7, EEnumeratingCleanDBSnapshot = 8, EEnumeratedFulllyCompleted = 9 } |
Inherited Enumerations | |
---|---|
CActive:TPriority |
Inherited Attributes | |
---|---|
CActive::iStatus |
void | ConstructL | ( | ) | [private] |
CMTPDataProviderConfig * | CreateConfigLC | ( | const TDesC & | aResourceFilename | ) | [private] |
const TDesC & aResourceFilename | The data provider configuration data resource filename. |
IMPORT_C CMTPDataProvider & | DataProviderByIndexL | ( | TUint | aIndex | ) |
Provides a reference to the data provider with the specified index.
TUint aIndex | The data provider index. |
IMPORT_C CMTPDataProvider & | DataProviderL | ( | TUint | aId | ) |
Provides a reference to the data provider with the specified identifier.
TUint aId | The data provider identifier. |
void | DoCancel | ( | ) | [private, virtual] |
Implements cancellation of an outstanding request.
This function is called as part of the active object's Cancel().
It must call the appropriate cancel function offered by the active object's asynchronous service provider. The asynchronous service provider's cancel is expected to act immediately.
DoCancel() must not wait for event completion; this is handled by Cancel().
IMPORT_C TInt | DpId | ( | TUint | aUid | ) |
Provides the identifier of the data provider with the specified implementation UID.
TUint aUid | The implementation UID. |
void | EnumerateDataProviderObjectsL | ( | TUint | aId | ) | [private] |
Requests that the given data provider enumerate its objects.
TUint aId | data provider ID |
void | EnumerationStateChangedL | ( | const CMTPDataProvider & | aDp | ) |
Data provider enumeration state change notification callback.
const CMTPDataProvider & aDp | The notifying data provider. |
void | EstablishDBSnapshotL | ( | TUint32 | aStorage | ) | [private] |
TUint32 aStorage |
void | ImplementationsCleanup | ( | TAny * | aData | ) | [private, static] |
TAny * aData |
TInt | ImplementationsLinearOrderUid | ( | const TUid * | aUid, |
const CImplementationInformation & | aObject | |||
) | [private, static] |
Implements a linear order relation for CImplementationInformation objects based on relative CImplementationInformation::ImplementationUid.
const TUid * aUid | The implementation UID object to match. |
const CImplementationInformation & aObject | The object instance to match. |
TInt | ImplementationsLinearOrderUid | ( | const CImplementationInformation & | aL, |
const CImplementationInformation & | aR | |||
) | [private, static] |
Implements a TLinearOrder for CImplementationInformation objects based on relative CImplementationInformation::ImplementationUid.
const CImplementationInformation & aL | The first object instance. |
const CImplementationInformation & aR | The second object instance. |
IMPORT_C TBool | IsDataProviderLoaded | ( | TUint | aId | ) | const |
Determine whether a data provider with the specified data provider id has been loaded
TUint aId | the id of the data provider to be checked |
TBool | IsObjectsEnumerationNeededL | ( | CMTPDataProvider & | dp | ) | [private] |
Check the necessity of objects enumeration as given the data provider
CMTPDataProvider & dp | CMTPDataProvider reference |
TBool | LoadDataProviderL | ( | const TDesC & | aResourceFilename | ) | [private] |
const TDesC & aResourceFilename |
IMPORT_C void | LoadDataProvidersL | ( | ) |
void | LoadInstalledDataProvidersL | ( | const CImplementationInformation * | aImplementations | ) | [private] |
const CImplementationInformation * aImplementations | The installed ECOM data provider implementations list (ordered by implementation UID). |
TBool | LoadROMDataProvidersL | ( | const TDesC & | aResourceFilename, |
const RImplInfoPtrArray & | aImplementations | |||
) | [private] |
const TDesC & aResourceFilename | The data provider registration and configuration data resource filename. |
const RImplInfoPtrArray & aImplementations | The ECOM data provider implementations list (ordered by implementation UID). |
CMTPDataProviderController * | NewL | ( | ) | [static] |
IMPORT_C void | NotifyDataProvidersL | ( | TMTPNotification | aNotification, |
const TAny * | aParams | |||
) |
TMTPNotification aNotification | The notification type identifier. |
const TAny * aParams | The notification type specific parameter block |
IMPORT_C void | NotifyDataProvidersL | ( | TUint | aDPId, |
TMTPNotification | aNotification, | |||
const TAny * | aParams | |||
) |
TUint aDPId | |
TMTPNotification aNotification | |
const TAny * aParams |
IMPORT_C void | RegisterPendingRequestDP | ( | TUint | aDpUid, |
TUint | aTimeOut = 0 | |||
) |
void | RunL | ( | ) | [private, virtual] |
Handles an active object's request completion event.
A derived class must provide an implementation to handle the completed request. If appropriate, it may issue another request.
The function is called by the active scheduler when a request completion event occurs, i.e. after the active scheduler's WaitForAnyRequest() function completes.
Before calling this active object's RunL() function, the active scheduler has:
1. decided that this is the highest priority active object with a completed request
2. marked this active object's request as complete (i.e. the request is no longer outstanding)
RunL() runs under a trap harness in the active scheduler. If it leaves, then the active scheduler calls RunError() to handle the leave.
Note that once the active scheduler's Start() function has been called, all user code is run under one of the program's active object's RunL() or RunError() functions.
CActiveScheduler::Start CActiveScheduler::Error CActiveScheduler::WaitForAnyRequest TRAPD
IMPORT_C void | SetNeedEnumeratingPhase2 | ( | TBool | aNeed | ) |
TBool aNeed |
IMPORT_C TUint | StorageEnumerateState | ( | TUint | aStorageId | ) |
TUint aStorageId |
TInt | Uid | ( | const TDesC & | aResourceFilename, |
TUint & | aUid | |||
) | [private] |
Provides the implemetation UID associated with the specified data provider configuration data resource filename.
IMPORT_C void | UnloadDataProviders | ( | ) |
IMPORT_C void | WaitForEnumerationComplete | ( | ) |
Wait for the enumeration complete.
The active data provider set enumeration states.
EUnenumerated = 0 | |
EEnumerationStarting = 1 | |
EEnumeratingFrameworkStorages = 2 | |
EEnumeratingDataProviderStorages = 3 | |
EEnumeratingFrameworkObjects = 4 | |
EEnumeratingDataProviderObjects = 5 | |
EEnumeratingPhaseOneDone = 6 | |
EEnumeratingSubDirFiles = 7 | |
EEnumeratingCleanDBSnapshot = 8 | |
EEnumeratedFulllyCompleted = 9 |
__FLOG_DECLARATION_MEMBER_MUTABLE | [private] |
FLOGGER debug trace member variable.
RArray< TUint > | iDataProviderIds | [private] |
The active data provider identifier container, ordered by enumeration phase.
RPointerArray< CMTPDataProvider > | iDataProviders | [private] |
The active data provider set container, ordered bit implementation UID.
TUint | iDpIdArrayIndex | [private] |
The index used for iterating through the iDataProviderIds array.
RArray< TUint > | iEnumeratingDps | [private] |
The actively enumerating data providers.
RArray< TUint > | iEnumeratingStorages | [private] |
The actively enumerating storage IDs.
TUint | iEnumerationPhase | [private] |
The active data provider set enumeration phases.
TEnumerationStates | iEnumerationState | [private] |
The active data provider set enumeration states.
TUint | iNextDpId | [private] |
A general purpose index used for iterating through the active data provider set.
CActiveSchedulerWait * | iOpenSessionWaiter | [private] |
opensession waiter
Swi::RSisRegistrySession | iSisSession | [private] |
Session for sisRegistry
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.