diff -r fa1df4b99609 -r ebe688cedc25 messagingapp/msgappfw/server/src/ccsplugininterface.cpp --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/messagingapp/msgappfw/server/src/ccsplugininterface.cpp Tue Aug 31 15:11:31 2010 +0300 @@ -0,0 +1,173 @@ +/* +* Copyright (c) 2007 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: CS Server Plugin Interface +* +*/ + + +// INCLUDE FILES +#include "ccsplugin.h" +#include "ccsserver.h" +#include "ccsplugininterface.h" +#include "ccsdebug.h" + +// ============================== MEMBER FUNCTIONS ============================ + +// ---------------------------------------------------------------------------- +// CCsPluginInterface::NewL +// Two Phase Construction +// ---------------------------------------------------------------------------- +CCsPluginInterface* CCsPluginInterface::NewL() +{ + PRINT ( _L("Enter CCsPluginInterface::NewL") ); + + CCsPluginInterface* self = CCsPluginInterface::NewLC(); + CleanupStack::Pop( self ); + + PRINT ( _L("End CCsPluginInterface::NewL") ); + + return self; +} + +// ---------------------------------------------------------------------------- +// CCsPluginInterface::NewLC +// Two Phase Construction +// ---------------------------------------------------------------------------- +CCsPluginInterface* CCsPluginInterface::NewLC() +{ + PRINT ( _L("Enter CCsPluginInterface::NewLC") ); + + CCsPluginInterface* self = new( ELeave ) CCsPluginInterface(); + CleanupStack::PushL( self ); + self->ConstructL(); + + PRINT ( _L("End CCsPluginInterface::NewLC") ); + + return self; +} + +// ---------------------------------------------------------------------------- +// CCsPluginInterface::CCsPluginInterface +// Constructor +// ---------------------------------------------------------------------------- +CCsPluginInterface::CCsPluginInterface() +{ +} + +// ---------------------------------------------------------------------------- +// CCsPluginInterface::ConstructL +// 2nd phase constructor +// ---------------------------------------------------------------------------- +void CCsPluginInterface::ConstructL() +{ +} + +// ---------------------------------------------------------------------------- +// CCsPluginInterface::~CCsPluginInterface +// Constructor +// ---------------------------------------------------------------------------- +CCsPluginInterface::~CCsPluginInterface( ) +{ + PRINT ( _L("Enter CCsPluginInterface::~CCsPluginInterface") ); + + UnloadPlugIns(); + iCsPluginInstances.ResetAndDestroy(); + + PRINT ( _L("End CCsPluginInterface::~CCsPluginInterface") ); +} + +// ---------------------------------------------------------------------------- +// CCsPluginInterface::InstantiateAllPlugInsL +// Instantiates all plugins +// ---------------------------------------------------------------------------- +void CCsPluginInterface::InstantiatePluginL(CCsServer* aCsServer ) + { + RImplInfoPtrArray infoArray; + + // Get list of all implementations + ListAllImplementationsL( infoArray ); + + // Instantiate plugins for all impUIds by calling + // InstantiatePlugInFromImpUidL + for ( TInt iloop=0; iloopGetConversationsL(); +} + +// ---------------------------------------------------------------------------- +// CCsPluginInterface::GetPlugin +// Get Plugins count +// ---------------------------------------------------------------------------- +TInt CCsPluginInterface:: GetPluginsCount() +{ + return iCsPluginInstances.Count(); +} + +//EOF