lowlevellibsandfws/pluginfw/Framework/HeapTestImpl/HeapTestImpl.cpp
changeset 0 e4d67989cc36
equal deleted inserted replaced
-1:000000000000 0:e4d67989cc36
       
     1 // Copyright (c) 2003-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 // HeapTestImpl.cpp
       
    15 // 
       
    16 //
       
    17 
       
    18 
       
    19 #include "HeapTestInterface.h"
       
    20 #include "ImplementationProxy.h"
       
    21 
       
    22 class CHeapTest : public CHeapTestInterface
       
    23 {
       
    24 public:
       
    25 	static CHeapTest* NewL();
       
    26 	virtual ~CHeapTest();
       
    27 	TUid ImplId();
       
    28 	void DisplayMessage();
       
    29 
       
    30 
       
    31 private:
       
    32 	CHeapTest();
       
    33 
       
    34 private:
       
    35 	enum EEE {KSize = 100};
       
    36 	TUint8 iNooo[KSize];
       
    37 
       
    38 };
       
    39 
       
    40 // __________________________________________________________________________
       
    41 // Implementation
       
    42 
       
    43 CHeapTest* CHeapTest::NewL()
       
    44 	{
       
    45 	CHeapTest* self = new (ELeave) CHeapTest();
       
    46 	return self;
       
    47 	}
       
    48 
       
    49 CHeapTest::~CHeapTest()
       
    50 	{
       
    51 	}
       
    52 
       
    53 CHeapTest::CHeapTest() :
       
    54 	CHeapTestInterface()
       
    55 	{
       
    56 	for(TInt8 i=0;i<KSize;i++)
       
    57 		{
       
    58 		iNooo[i] = i;
       
    59 		}
       
    60 	}
       
    61 
       
    62 TUid CHeapTest::ImplId()
       
    63 	{
       
    64 	TUid idVal = {0x101FE393};
       
    65 	return idVal;
       
    66 	}
       
    67 
       
    68 void CHeapTest::DisplayMessage()
       
    69 {
       
    70 	RDebug::Printf("Implementation of DLL with version 1");
       
    71 }
       
    72 
       
    73 
       
    74 // __________________________________________________________________________
       
    75 // Exported proxy for instantiation method resolution
       
    76 // Define the interface UIDs
       
    77 const TImplementationProxy ImplementationTable[] = 
       
    78 	{
       
    79 		IMPLEMENTATION_PROXY_ENTRY(0x101FE393,CHeapTest::NewL)
       
    80 	};
       
    81 
       
    82 EXPORT_C const TImplementationProxy* ImplementationGroupProxy(TInt& aTableCount)
       
    83 	{
       
    84 	aTableCount = sizeof(ImplementationTable) / sizeof(TImplementationProxy);
       
    85 
       
    86 	return ImplementationTable;
       
    87 	}
       
    88