diff -r 000000000000 -r 8466d47a6819 meetingrequest/mrgui/inc/cesmrlocationplugin.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/meetingrequest/mrgui/inc/cesmrlocationplugin.h Thu Dec 17 08:39:21 2009 +0200 @@ -0,0 +1,81 @@ +/* +* Copyright (c) 2008-2009 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: Interface definition for Location integration plug-in +* +*/ + + +#ifndef CESMRLOCATIONPLUGIN_H +#define CESMRLOCATIONPLUGIN_H + +#include +#include +#include "esmrinternaluid.h" +#include "mesmrlocationplugin.h" + +class MESMRLocationPluginObserver; + +/** + * CESMRLocationPlugin defines the interface for accessing location service provider + * from ESMR GUI. + * + */ +class CESMRLocationPlugin : public CActive, + public MESMRLocationPlugin + { + +public: + + /** + * Two-phased constructor + * + * @param aObserver Observer for location plugin asynchronous events. + */ + inline static CESMRLocationPlugin* NewL(); + + inline virtual ~CESMRLocationPlugin(); + + virtual void SetObserver ( MESMRLocationPluginObserver* aObserver ) = 0; + +protected: + + inline CESMRLocationPlugin( TInt aPriority ); + +private: // data + + TUid iDtorIDKey; + }; + +// INLINE FUNCTIONS + +inline CESMRLocationPlugin* CESMRLocationPlugin::NewL() + { + TAny* impl = NULL; + impl = REComSession::CreateImplementationL( + TUid::Uid( KESMRLocationPluginImplementationUid ), + _FOFF( CESMRLocationPlugin, iDtorIDKey ) ); + return reinterpret_cast< CESMRLocationPlugin* >( impl ); + } + +inline CESMRLocationPlugin::CESMRLocationPlugin( TInt aPriority ) + : CActive( aPriority ) + { + } + +inline CESMRLocationPlugin::~CESMRLocationPlugin() + { + REComSession::DestroyedImplementation( iDtorIDKey ); + } + +#endif // CESMRLOCATIONPLUGIN_H