5
|
1 |
/*
|
|
2 |
* Copyright (c) 2006-2007 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 the License "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: This class stores information about async calls
|
|
15 |
*
|
|
16 |
*/
|
|
17 |
|
|
18 |
|
|
19 |
#ifndef CSTOREASYNCINFO_H
|
|
20 |
#define CSTOREASYNCINFO_H
|
|
21 |
|
|
22 |
#include <e32base.h>
|
|
23 |
#include "sensorcallback.h"
|
|
24 |
|
|
25 |
//forward declaration
|
|
26 |
class CSensorCallback;
|
|
27 |
/**
|
|
28 |
* This class stores information about async requests that are being served
|
|
29 |
* currently and also provides method to fectch those information
|
|
30 |
*/
|
|
31 |
|
|
32 |
//Enums for Async Request Type
|
|
33 |
enum TAsyncType
|
|
34 |
{
|
|
35 |
EData,
|
|
36 |
EInvalid
|
|
37 |
};
|
|
38 |
|
|
39 |
class CStoreAsyncInfo : public CBase
|
|
40 |
{
|
|
41 |
public:
|
|
42 |
/**
|
|
43 |
* Symbian Two Phase construction
|
|
44 |
* @Param aType : Type of async request
|
|
45 |
* @Param aTransactionId: TransactionId
|
|
46 |
* @Param aChannelId : ChannelId
|
|
47 |
* Returns Pointer to a newly Created object of this class
|
|
48 |
*/
|
|
49 |
static CStoreAsyncInfo* NewL( TAsyncType atype,
|
|
50 |
TInt32 aTransactionId,
|
|
51 |
CSensorCallback* aCallback,
|
|
52 |
TUint aChannelId = 0 );
|
|
53 |
/**
|
|
54 |
* Destructor
|
|
55 |
*/
|
|
56 |
virtual ~CStoreAsyncInfo();
|
|
57 |
|
|
58 |
|
|
59 |
private:
|
|
60 |
/**
|
|
61 |
* Default constructor.
|
|
62 |
*/
|
|
63 |
CStoreAsyncInfo( TAsyncType atype,
|
|
64 |
TInt32 aTransactionId,
|
|
65 |
CSensorCallback* aCallback,
|
|
66 |
TUint aChannelId = 0 );
|
|
67 |
/**
|
|
68 |
* Symbian OS constructor.
|
|
69 |
* @return void
|
|
70 |
*/
|
|
71 |
void ConstructL();
|
|
72 |
public:
|
|
73 |
|
|
74 |
/**
|
|
75 |
* Channel id
|
|
76 |
*/
|
|
77 |
TUint ichnlId;
|
|
78 |
|
|
79 |
/**
|
|
80 |
* Transaction id
|
|
81 |
*/
|
|
82 |
TInt32 iTransactionId;
|
|
83 |
|
|
84 |
/**
|
|
85 |
* Async type
|
|
86 |
*/
|
|
87 |
TAsyncType iAsyncType;
|
|
88 |
|
|
89 |
/**
|
|
90 |
* Ptr to callback
|
|
91 |
*/
|
|
92 |
CSensorCallback* iCallback;
|
|
93 |
};
|
|
94 |
|
|
95 |
#endif // CSTOREASYNCINFO_H
|