1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/os/ossrv/syslibsapitest/syslibssvs/ecom/common/inc/TestEComInterface.h Fri Jun 15 03:10:57 2012 +0200
1.3 @@ -0,0 +1,74 @@
1.4 +/*
1.5 +* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
1.6 +* All rights reserved.
1.7 +* This component and the accompanying materials are made available
1.8 +* under the terms of "Eclipse Public License v1.0"
1.9 +* which accompanies this distribution, and is available
1.10 +* at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.11 +*
1.12 +* Initial Contributors:
1.13 +* Nokia Corporation - initial contribution.
1.14 +*
1.15 +* Contributors:
1.16 +*
1.17 +* Description:
1.18 +*
1.19 +*/
1.20 +
1.21 +
1.22 +
1.23 +#if defined (_MSC_VER) && (_MSC_VER >= 1000)
1.24 +#pragma once
1.25 +#endif
1.26 +#if (!defined __TEST_ECOM_INTERFACE_H__)
1.27 +#define __TEST_ECOM_INTERFACE_H__
1.28 +
1.29 +#include <e32base.h>
1.30 +#include <ecom/ecom.h>
1.31 +
1.32 +#define CTestEComInterface_UID 0x2000371E
1.33 +
1.34 +
1.35 +class CTestEComInterface : public CBase
1.36 + {
1.37 +/**
1.38 + @internalComponent
1.39 + CTestEComInterface which is an example abstract class being representative
1.40 + of the concrete class which the client wishes to use.
1.41 + It acts as a base, for a real class to provide all the
1.42 + functionality that a client requires.
1.43 + It supplies instantiation & destruction by using
1.44 + the ECom framework, and functional services
1.45 + by using the methods of the actual class.
1.46 + */
1.47 +public:
1.48 + //The function which instantiates an object of this type
1.49 + //using aUid as a resolution parameter.
1.50 + //(eg NewL for a CBase derived object).
1.51 + static CTestEComInterface* NewL(const TUid aUid);
1.52 +
1.53 + //Standardised destructor.
1.54 + virtual ~CTestEComInterface();
1.55 +
1.56 + //Pure interface method
1.57 + //Representative of a method provided on the interface by
1.58 + //the interface definer.
1.59 + virtual void DoMethod1L() = 0;
1.60 +
1.61 + //Pure interface method
1.62 + //Representative of a method provided on the interface by
1.63 + //the interface definer.
1.64 + virtual TInt DoMethod2L() = 0;
1.65 +
1.66 +protected:
1.67 + //Default constructor
1.68 + inline CTestEComInterface();
1.69 +
1.70 + //Attributes
1.71 +public:
1.72 + TUid iDtor_ID_Key;
1.73 + };
1.74 +
1.75 +#include "TestEComInterface.inl"
1.76 +
1.77 +#endif /* __TEST_ECOM_INTERFACE_H__ */