diff -r 89d6a7a84779 -r 25a17d01db0c Symbian3/PDK/Source/GUID-895A685E-83E8-51A3-A823-3A0E07B1E609.dita --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Symbian3/PDK/Source/GUID-895A685E-83E8-51A3-A823-3A0E07B1E609.dita Fri Jan 22 18:26:19 2010 +0000 @@ -0,0 +1,51 @@ + + + + + +Exporting +the Implementation Factories

An implementation collection gathers one or more interface implementations +in a DLL. It provides necessary information to the plug-in framework to use +them. The collection must export a single function that provides an array. +This array maps the UID of each implementation it contains with a pointer +to its factory instantiation function (NewL() in our example).

+ + +Define a UID for each implementation. This UID maps to the instantiation +function of the implementation. Construct an array of UID's for all the implementations +in the collection. +// Define the interface UIDs +const TImplementationProxy ImplementationTable[] = + { + {{0x10009DC3}, CImplementationClassOne::NewL();}, + {{0x10009DC4}, CImplementationClassTwo::NewL();} + }; + } + + +The signature of this exported function must be: +const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount); + + +The exported function returns a pointer to an array of TImplementationProxy objects. + + +Each TImplementationProxy contains a UID and a function +pointer. + aTableCount should be set to the number of items in +the array. +EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount) + { + aTableCount = sizeof(ImplementationTable) / sizeof(TImplementationProxy); + + return ImplementationTable; + } + + +
\ No newline at end of file