diff -r 000000000000 -r 094583676ce7 PECengine/PluginServer2/SrvSrc/CPEngPluginHolder.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/PECengine/PluginServer2/SrvSrc/CPEngPluginHolder.h Thu Dec 17 08:41:52 2009 +0200 @@ -0,0 +1,81 @@ +/* +* Copyright (c) 2002 Nokia Corporation and/or its subsidiary(-ies). +* All rights reserved. +* This component and the accompanying materials are made available +* under the terms of "Eclipse Public License v1.0" +* which accompanies this distribution, and is available +* at the URL "http://www.eclipse.org/legal/epl-v10.html". +* +* Initial Contributors: +* Nokia Corporation - initial contribution. +* +* Contributors: +* +* Description: See class description below. +* +*/ + + +#ifndef __CPENGPLUGINHOLDER_H__ +#define __CPENGPLUGINHOLDER_H__ + +// INCLUDES +#include + +class CPEngPluginInterface2; + +// CLASS DEFINITION +/** + * + * + * + * + * @lib + * @since 3.0 + */ +class CPEngPluginHolder : public CBase + { + public: // Constructors and destructors + + static CPEngPluginHolder* NewL(); // Static constructor + static CPEngPluginHolder* NewLC(); // Static constructor + virtual ~CPEngPluginHolder(); // Destructor (virtual) + + public: // New methods + + /** + * Returns the uid of the held plugin. + * + * @since 3.0 + * @return The uid + */ + TUid Uid() const; + + /** + * Check if the plugin is currently loaded. + * + * @since 3.0 + * @return ETrue if the plugin is loaded. + */ + TBool Loaded() const; + + void LoadPluginL( TUid aPluginUid ); + + const CPEngPluginInterface2* Interface() const; + + protected: // Constructors and destructors + + CPEngPluginHolder();// Default constructor, protected to allow derivation + void ConstructL(); // Second phase construct + + private: // Data + + //Filename of the plugin + TUid iUid; + + //Pointer to plugin's interface, OWNED + CPEngPluginInterface2* iPlugin; + + }; + +#endif // __CPENGPLUGINHOLDER_H__