sl@0: /* sl@0: * Copyright (c) 2002-2008 Nokia Corporation and/or its subsidiary(-ies). sl@0: * All rights reserved. sl@0: * This component and the accompanying materials are made available sl@0: * under the terms of "Eclipse Public License v1.0" sl@0: * which accompanies this distribution, and is available sl@0: * at the URL "http://www.eclipse.org/legal/epl-v10.html". sl@0: * sl@0: * Initial Contributors: sl@0: * Nokia Corporation - initial contribution. sl@0: * sl@0: * Contributors: sl@0: * sl@0: * Description: Header definition of plugin classes implementing devsound client sl@0: * custom interface extension. sl@0: * sl@0: */ sl@0: sl@0: sl@0: sl@0: #ifndef CIEXTNCLIENTPLUGIN_H sl@0: #define CIEXTNCLIENTPLUGIN_H sl@0: sl@0: // Include files sl@0: #include sl@0: #include sl@0: sl@0: // Forward declarations sl@0: class MCIFactoryIntfc; sl@0: sl@0: /** sl@0: * Plugin class implementing DevSound CI client Extension sl@0: * sl@0: * An instance of this class is created when DevSound is created. When client sl@0: * calls CMMFDevSound::CustomInterface() function with UID that is not supported sl@0: * by platform version of A3F DevSound, the request is then forwarded to this sl@0: * plugin. sl@0: * sl@0: * Only one instance of this plugin can exist in the system. sl@0: * sl@0: * This class is intended to be used only by DevSound client implementation. sl@0: * sl@0: * @since S60 v3.2 sl@0: * sl@0: */ sl@0: class CCIExtnClientPlugin : public CBase, sl@0: public MDevSoundCIClientExtension sl@0: { sl@0: public: sl@0: sl@0: /** sl@0: * Two-phased constructor. sl@0: * Called by ECom framework. sl@0: */ sl@0: static MDevSoundCIClientExtension* NewL(); sl@0: sl@0: /** sl@0: * Destructor. sl@0: */ sl@0: ~CCIExtnClientPlugin(); sl@0: sl@0: // From MDevSoundCIClientExtension begins sl@0: // Called by framework when plugin is constructed sl@0: TInt Setup( MCustomCommand& aCustomCommand ); sl@0: // Called by framework forwarding request to create a custom interface sl@0: TInt CustomInterfaceExtension( TUid aUid, TAny*& aInterface ); sl@0: // Called by framework when plugin is to be deleted sl@0: void Release(); sl@0: // Called by framework after plugin is created sl@0: void PassDestructorKey( TUid aDestructorKey ); sl@0: // From MDevSoundCIClientExtension ends sl@0: sl@0: private: sl@0: /** sl@0: * Constructor. sl@0: */ sl@0: CCIExtnClientPlugin(); sl@0: sl@0: /** sl@0: * Second phase constructor. sl@0: */ sl@0: void ConstructL(); sl@0: sl@0: /** sl@0: * Initializes factory plugins list. sl@0: * sl@0: * Leaves on error. sl@0: */ sl@0: void InitializeFactoryPluginsL(); sl@0: sl@0: private: sl@0: sl@0: /** sl@0: * Reference to MCustomCommand interface sl@0: * Not own. sl@0: */ sl@0: MCustomCommand* iMCustomCommand; sl@0: sl@0: /** sl@0: * Uid of the plugin object passed by the framework via PassDestructorKey() sl@0: */ sl@0: TUid iDestructorKey; sl@0: sl@0: /** sl@0: * List of factory plugins. When framework calls sl@0: * CustomInterfaceExtension() function, the request will be forwarded to each sl@0: * factory plugin in this list until it is handled. sl@0: * sl@0: * Own. sl@0: */ sl@0: RPointerArray iMCIFactoryIntfcList; sl@0: }; sl@0: sl@0: #endif // CIEXTNCLIENTPLUGIN_H