tstaskmonitor/server/inc/tsrunningappstorage.h
changeset 102 8b8b34fa9751
parent 100 0920c6a9b6c8
child 106 e78d6e055a5b
equal deleted inserted replaced
100:0920c6a9b6c8 102:8b8b34fa9751
     1 /*
       
     2 * Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:
       
    15 *
       
    16 */
       
    17 #ifndef RUNNINGAPPSTORAGE_H
       
    18 #define RUNNINGAPPSTORAGE_H
       
    19 
       
    20 // INCLUDES
       
    21 #include <e32std.h>
       
    22 #include <e32base.h>
       
    23 
       
    24 #include "tsdataobserver.h"
       
    25 #include "hsdataprovider.h"
       
    26 #include "tsdatastorage.h"
       
    27 
       
    28 class CTsDataList;
       
    29 class MTsResourceManager;
       
    30 class MTsWindowGroupsMonitor;
       
    31 
       
    32 /**
       
    33  *  CRunningAppServer
       
    34  * 
       
    35  */
       
    36 class CRunningAppStorage : public CBase,
       
    37                            public MHsDataProvider, 
       
    38                            public MHsDataObserver,
       
    39                            public MTsDataStorage 
       
    40 {
       
    41 public:
       
    42     /**
       
    43      * Destructor.
       
    44      */
       
    45     ~CRunningAppStorage();
       
    46 
       
    47     /**
       
    48      * Two-phased constructor.
       
    49      */
       
    50     static CRunningAppStorage* NewL(MHsDataObserver& observer,
       
    51                                     MTsResourceManager& resources,
       
    52                                     MTsWindowGroupsMonitor &wsMonitor);
       
    53     
       
    54 public: //MHsDataObserver
       
    55     const TDesC8& Data() const; 
       
    56     
       
    57     //MHsDataChangeProvider
       
    58     void DataChanged();
       
    59     
       
    60     void UpdateL(TInt key,const CFbsBitmap& data, TInt param, TInt priority);
       
    61     
       
    62     void UpdateL(TInt key, const Visibility& data, TInt param);
       
    63     
       
    64     void RemoveL(TInt key, TInt param);
       
    65 
       
    66 private:
       
    67     /**
       
    68      * Constructor for performing 1st stage construction
       
    69      */
       
    70     CRunningAppStorage(MHsDataObserver& observer);
       
    71 
       
    72     /**
       
    73      * Default constructor for performing 2nd stage construction
       
    74      */
       
    75     void ConstructL(MTsResourceManager& resources,
       
    76                     MTsWindowGroupsMonitor &wsMonitor);
       
    77     
       
    78     void DataChangedL();
       
    79 
       
    80 private:
       
    81     MHsDataObserver& mObserver;
       
    82     RBuf8 mData;
       
    83     CTsDataList* mEngine;
       
    84 };
       
    85 
       
    86 #endif // RUNNINGAPPSERVER_H