diff -r 80ef3a206772 -r 48780e181b38 Symbian3/SDK/Source/GUID-6482956D-C3A3-5B68-A37F-4250C85B0D82.dita --- a/Symbian3/SDK/Source/GUID-6482956D-C3A3-5B68-A37F-4250C85B0D82.dita Fri Jul 16 17:23:46 2010 +0100 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,53 +0,0 @@ - - - - - -Polymorphic -interface DLLs -

A polymorphic DLL contains an interface defined by a gate function and -an abstract class with at least one virtual function.

-

The polymorphic DLL exports the gate function at ordinal 1, which typically -constructs a concrete class derived from the abstract interface. The virtual -function is then called, and the functions of the class are available.

-

Examples of polymorphic DLLs in Symbian platform include ECom plug-ins, -device drivers, Front End Processors, and many more.

-

Each type of interface should specify its own UID, which is used as uid2 for -the polymorphic DLL.

-

The function responsible for loading a polymorphic DLL should check that -its uid2 corresponds with the expected interface type.

-

For polymorphic DLLs, the interpretation of uid3 depends -on the interface type. uid3 may not be required by all interfaces.

-

The build process for a polymorphic DLL produces an import library, but -it is not used.

-
mmp project specification

The project -file for a polymorphic DLL must specify the correct target type and UIDs:

    -
  • Specify the TARGETTYPE line -as:

    TARGETTYPE dll

    This -implicitly specifies UID1 correctly. Note that some types -of polymorphic DLLs, have particular support by the build tools, and have -their own different target types. See Polymorphic -DLL targettype summary.

  • -
  • Specify the UID for -the DLL in a UID line:

    UID <UID2> <UID3>

    The UID2 value is defined by the interface which is being implemented. -Some types of polymorphic DLL also require a third UID, but, if so, its meaning -is defined by the DLL.

  • -
-

An example of a project file (PolymorphicDLL1.mmp) -for a polymorphic DLL is given below.

TARGET PolymorphicDLL1.dll -TARGETTYPE dll -UID 0x10004262 0x10004264 -SOURCEPATH . -SOURCE PolymorphicDLL1.cpp -USERINCLUDE . -USERINCLUDE ..\UsingDLLs -SYSTEMINCLUDE \Epoc32\include -LIBRARY euser.lib -EXPORTUNFROZEN
-
\ No newline at end of file