activityfw/activitydatabase/hsactivitydbclient/s60/inc/hsactivitydbasyncrequest_p.h
changeset 61 8e5041d13c84
child 66 32469d7d46ff
equal deleted inserted replaced
60:f62f87b200ec 61:8e5041d13c84
       
     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 HSACTIVITYDBASYNCREQUESTPRIVATE_H
       
    18 #define HSACTIVITYDBASYNCREQUESTPRIVATE_H
       
    19 #include <e32base.h>
       
    20 #include <QVariant>
       
    21 #include <hsactivitydbasyncrequestobserver.h>
       
    22 
       
    23 class HsActivityDbClientPrivate;
       
    24 
       
    25 /**
       
    26  * Class is responsible for async. request handling
       
    27  */
       
    28 class HsActivityDbAsyncRequestPrivate : public CActive
       
    29 
       
    30 {
       
    31 public:
       
    32     /**
       
    33      * First step constructor
       
    34      */
       
    35     static HsActivityDbAsyncRequestPrivate* 
       
    36         NewL(HsActivityDbAsyncRequestObserver &, HsActivityDbClientPrivate &);
       
    37     
       
    38     /**
       
    39      * First step constructor
       
    40      */
       
    41     static HsActivityDbAsyncRequestPrivate* 
       
    42         NewLC(HsActivityDbAsyncRequestObserver &, HsActivityDbClientPrivate &);
       
    43     
       
    44     /**
       
    45      * Destructor
       
    46      */
       
    47     ~HsActivityDbAsyncRequestPrivate();
       
    48     
       
    49     /**
       
    50      * Function create subscription to current ativity changes
       
    51      * @param condition - activity filetering rules
       
    52      */
       
    53     void waitActivity(const QVariantHash& condition);
       
    54 protected:
       
    55     /**
       
    56      * Interface implementation.
       
    57      * @see void CActive::DoCancel()
       
    58      */
       
    59     void DoCancel();
       
    60     
       
    61     /**
       
    62      * Interface implementation.
       
    63      * @see void CActive::DoCancel()
       
    64      */
       
    65     void RunL();
       
    66 private:
       
    67     /**
       
    68      * Constructor
       
    69      */
       
    70     HsActivityDbAsyncRequestPrivate(HsActivityDbAsyncRequestObserver &,
       
    71                                     HsActivityDbClientPrivate &);
       
    72 private:
       
    73     HsActivityDbAsyncRequestObserver& mObserver; 
       
    74     HsActivityDbClientPrivate& mSession;
       
    75     int mRequestType;
       
    76     RBuf8 mDataBuf;
       
    77     TPckgBuf<int> mDataSize;
       
    78 };
       
    79 #endif // HSACTIVITYDBCLIENTPRIVATE_H