Factories::CFactoryBase Class Reference

class Factories::CFactoryBase : public CBase

Factory Base class provides basic object managment functionlity and the ability for a factory to be load from another Dynamic Linked Library via the ECOM framework.

It also provides asynchronous destruction for it's managed objects (if required) but also copes with synchronous destruction, should a managed object get deleted by another entity.

Inherits from

  • Factories::CFactoryBase

Constructor & Destructor Documentation

CFactoryBase(TUid, CFactoryContainer &)

IMPORT_CCFactoryBase(TUidaFactoryUid,
CFactoryContainer &aParentContainer
)[protected, explicit]

Constructor

Parameters

TUid aFactoryUid
CFactoryContainer & aParentContainer

~CFactoryBase()

IMPORT_C~CFactoryBase()[protected]

Destructor

Member Functions Documentation

AddManagedObjectL(AFactoryObject &)

IMPORT_C TFactoryObjectEntry &AddManagedObjectL(AFactoryObject &aObject)[protected]

Add a AFactoryObject to the managed collection AFactoryObject Since 9.0

Parameters

AFactoryObject & aObjectthe AFactoryObject object to be added

ConstructL(const TUid &)

IMPORT_C voidConstructL(const TUid &aDestroyUid)[protected]

Parameters

const TUid & aDestroyUid

ConstructL()

IMPORT_C voidConstructL()[protected]

DeRegisterNotifier(const IFactoryNotify &)

IMPORT_C voidDeRegisterNotifier(const IFactoryNotify &aFactoryNotify)

De-registers a callback for factory notification

IFactoryNotify CFactoryBase::RegisterNotifierL

Parameters

const IFactoryNotify & aFactoryNotifyThe IFactoryNotify object that implements the callback

FindObject(MFactoryQuery &)

IMPORT_C AFactoryObject *FindObject(MFactoryQuery &aQuery)const [protected]

Find a factory based on criteria specified by aQuery MFactoryQuery

Parameters

MFactoryQuery & aQuerya MFactoryQuery derived object implementing MFactoryQuery::Match

ManagedObjectBeingDeleted(AFactoryObject &)

IMPORT_C voidManagedObjectBeingDeleted(AFactoryObject &aObject)[protected]

Parameters

AFactoryObject & aObject

NewL(const TDesC8 &, const TUid &, CFactoryContainer &)

IMPORT_C CFactoryBase *NewL(const TDesC8 &aName,
const TUid &aInterfaceUid,
CFactoryContainer &aParentContainer
)[static]

Create a new instance of a factory (cnstructed via ECOM using the name and the interfaceUId specified

Exceptions
leaves

with KErrNoMemory in out of memory conditions

Parameters

const TDesC8 & aNameThe name (string representation) of the factory
const TUid & aInterfaceUidThe interface Uid that ECOM should use to load the implementation
CFactoryContainer & aParentContainerThe factory container the factory should become a member of

NewL(const TUid &, CFactoryContainer &)

IMPORT_C CFactoryBase *NewL(const TUid &aImplementationUid,
CFactoryContainer &aParentContainer
)[static]

Create a new instance of a factory (cnstructed via ECOM using the name and the interfaceUId specified

Exceptions
leaves

with KErrNoMemory in out of memory conditions

Parameters

const TUid & aImplementationUidThe interface Uid that ECOM should use to load the implementation
CFactoryContainer & aParentContainerThe factory container the factory should become a member of

ParentContainer()

CFactoryContainer &ParentContainer()[inline]

RegisterNotifierL(const IFactoryNotify &)

IMPORT_C voidRegisterNotifierL(const IFactoryNotify &aFactoryNotify)

Registers a callback for factory notification

IFactoryNotify

Parameters

const IFactoryNotify & aFactoryNotifyThe IFactoryNotify object that implements the callback

RemoveManagedObject(AFactoryObject &)

IMPORT_C voidRemoveManagedObject(AFactoryObject &aObject)[protected]

Parameters

AFactoryObject & aObject

RemoveManagedObject(TInt)

voidRemoveManagedObject(TIntaIndex)[private]

Parameters

TInt aIndex

SignalCreation(AFactoryObject &)

IMPORT_C TIntSignalCreation(AFactoryObject &aObject)[private]

Parameters

AFactoryObject & aObject

SignalDeletion(AFactoryObject &)

IMPORT_C voidSignalDeletion(AFactoryObject &aObject)[private]

Parameters

AFactoryObject & aObject

Uid()

IMPORT_C TUidUid()const

Getter for the identifier of the object specified during construction

Member Data Documentation

TUid iDestroyUid

TUid iDestroyUid[private]

RArray< IFactoryNotify > iFactoryNotify

RArray< IFactoryNotify >iFactoryNotify[protected]

TUid iFactoryUid

TUid iFactoryUid[private]

RArray< TFactoryObjectEntry > iObjects

RArray< TFactoryObjectEntry >iObjects[private]

CFactoryContainer & iParentContainer

CFactoryContainer &iParentContainer[private]