os/persistentdata/traceservices/tracefw/ulogger/src/pluginframework/pluginallocator.h
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/persistentdata/traceservices/tracefw/ulogger/src/pluginframework/pluginallocator.h	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,69 @@
     1.4 +// Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.5 +// All rights reserved.
     1.6 +// This component and the accompanying materials are made available
     1.7 +// under the terms of "Eclipse Public License v1.0"
     1.8 +// which accompanies this distribution, and is available
     1.9 +// at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.10 +//
    1.11 +// Initial Contributors:
    1.12 +// Nokia Corporation - initial contribution.
    1.13 +//
    1.14 +// Contributors:
    1.15 +//
    1.16 +// Description:
    1.17 +// ULogger plug-in allocator header file
    1.18 +// 
    1.19 +//
    1.20 +
    1.21 +/**
    1.22 + @file
    1.23 + @internalTechnology
    1.24 + @prototype
    1.25 +*/
    1.26 +
    1.27 +#ifndef PLUGINALLOCATOR_H_
    1.28 +#define PLUGINALLOCATOR_H_
    1.29 +
    1.30 +#include <e32base.h>
    1.31 +#include <e32cmn.h>
    1.32 +#include "uloggeroutputplugin.h"
    1.33 +#include "uloggerinputplugin.h"
    1.34 +
    1.35 +
    1.36 +namespace Ulogger
    1.37 +{
    1.38 +
    1.39 +/*!CPluginAllocator class.
    1.40 +*/
    1.41 +class CPluginAllocator : public CBase
    1.42 +	{
    1.43 +public:
    1.44 +	IMPORT_C static CPluginAllocator* NewL(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName);
    1.45 +	IMPORT_C static CPluginAllocator* NewLC(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName);
    1.46 +	IMPORT_C ~CPluginAllocator();
    1.47 +	IMPORT_C void ConstructL(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName);
    1.48 +	IMPORT_C MOutputPlugin* GetOutputPlugin();
    1.49 +	IMPORT_C MInputPlugin*  GetInputPlugin();
    1.50 +
    1.51 +	/**
    1.52 +	Requests a list of all available implementations which 
    1.53 +	satisfy this given interface in a ECOM framework
    1.54 +	*/
    1.55 +	IMPORT_C static void ListAllImplementationsL(RImplInfoPtrArray& aImplInfoArray);
    1.56 +
    1.57 +private:
    1.58 +	CPluginAllocator();
    1.59 +	TInt CreateChannelsL(const TPtrC8& aOutputPluginName, const TPtrC8& aInputPluginName);
    1.60 +
    1.61 +private:
    1.62 +	CPlugin     *iOutputPluginBase; //output plugin instance
    1.63 +	RLibrary 	iOutputLib;
    1.64 +	TFileName 	iOutputLibName;
    1.65 +
    1.66 +	CPlugin     *iInputPluginBase; //input plugin instance
    1.67 +	RLibrary 	iInputLib;
    1.68 +	TFileName 	iInputLibName;
    1.69 +	}; //</CPluginAllocator>
    1.70 +
    1.71 +} //</namespace ULogger>
    1.72 +#endif /*PLUGINALLOCATOR_H_*/