diff -r 000000000000 -r f0cf47e981f9 mmsharing/mmshavailability/tsrc/ut_availability/Stubs/inc/musavaobserverimp.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/mmsharing/mmshavailability/tsrc/ut_availability/Stubs/inc/musavaobserverimp.h Thu Dec 17 08:44:37 2009 +0200 @@ -0,0 +1,121 @@ +/* +* Copyright (c) 2005-2006 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: This observer is used by +* ECOM clients to get function call from the availability Plug-in +* +*/ + + + +#ifndef __MUSAVAOBSERVERIMP_H__ +#define __MUSAVAOBSERVERIMP_H__ + +#include "musavaavailabilityobserver.h" +//#include "musavaobserver.h" +#include "musunittesting.h" +#include +#include + +#ifdef MUS_UNITTEST +#undef IMPORT_C +#define IMPORT_C +#endif + +class CMusAvaController; +class MMusAvaObserver; +/** + * MusAvailability Observer base class + * + * Observer interface for ECOM clients. + * + * @lib musavailabilityplugin.lib + * @since S60 v3.2 + */ + +class CMusAvaObserverImp : public CBase, + public MMusAvaObserver + + { +public: + + /** + * Two-phased constructor + * + * @since S60 v3.2 + * @param + * @return Returns pointer to CMusAvaController object + */ + + static CMusAvaObserverImp* NewL( ); + + /** + * Destructor + * + * @since S60 v3.2 + * @param + * @return + */ + + ~CMusAvaObserverImp(); + + protected: + + /** + * Constructor + * + * @since S60 v3.2 + * @return + */ + + CMusAvaObserverImp( ); + + /** + * Perform the second phase construction of a + * CMusAvaController object + * + * @since S60 v3.2 + * @param + * @return + */ + + void ConstructL(); + +// from base class MMusAvaAvailabilityObserver + +public: + + /** + * Availability report + * + * @since S60 v3.2 + * @param aStatus New status for availability. + */ + virtual void AvailabilityChanged( + MMusAvaObserver::TAvailabilityName aName, + MMusAvaObserver::TAvailabilityStatus aStatus ); + + virtual void AvailabilityError( + MMusAvaObserver::TAvailabilityName aName, + MMusAvaObserver::TAvailabilityStatus aStatus ); + +public: + + MMusAvaObserver::TAvailabilityStatus iStatus; + MMusAvaObserver::TAvailabilityName iName; + MUS_UNITTEST ( UT_CMusAvaDefaultImp ) + }; + + +#endif // __MUSAVAOBSERVERIMP_H__ +