diff -r 000000000000 -r ba25891c3a9e appinstaller/AppMngr2/inc/appmngr2scannerdir.h --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/appinstaller/AppMngr2/inc/appmngr2scannerdir.h Thu Dec 17 08:51:10 2009 +0200 @@ -0,0 +1,55 @@ +/* +* Copyright (c) 2008 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: Manages and watches one directory in CAppMngr2DirScanner +* +*/ + + +#ifndef C_APPMNGR2SCANNERDIR_H +#define C_APPMNGR2SCANNERDIR_H + +#include // CActive +#include // RFs +#include "appmngr2scannerdirobserver.h" // MAppMngr2ScannerDirObserver + + +class CAppMngr2ScannerDir : public CActive + { +public: // constructor and destructor + static CAppMngr2ScannerDir* NewL( RFs& aFs, const TDesC& aDir, + MAppMngr2ScannerDirObserver& aObs ); + ~CAppMngr2ScannerDir(); + +public: // new functions + const TDesC& DirName() const; + void StartWatchingChanges(); + void StopWatchingChanges(); + +protected: // from CActive + void DoCancel(); + void RunL(); + +private: // new functions + CAppMngr2ScannerDir( RFs& aFs, MAppMngr2ScannerDirObserver& aObs ); + void ConstructL( const TDesC& aDir ); + TPtrC ChopTrailingString( const TDesC& aString, const TDesC& aTrailing ); + +private: // data + MAppMngr2ScannerDirObserver& iObserver; + RFs& iFs; + HBufC* iDir; + }; + +#endif // C_APPMNGR2SCANNERDIR_H +