|
1 /* |
|
2 * Copyright (c) 2010 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 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 #ifndef __CREATORLOGS_H__ |
|
23 #define __CREATORLOGS_H__ |
|
24 |
|
25 #include "engine.h" |
|
26 #include "creator_modulebase.h" |
|
27 |
|
28 |
|
29 #include <e32base.h> |
|
30 //#include <logwrap.h> |
|
31 #include <logwraplimits.h> |
|
32 #include <logcli.h> |
|
33 //#include <logeng.h> |
|
34 #include <logengdurations.h> |
|
35 |
|
36 |
|
37 |
|
38 class CCreatorEngine; |
|
39 class CLogsParameters; |
|
40 |
|
41 |
|
42 class CCreatorLogs : public CActive, public MCreatorModuleBase, public MUIObserver |
|
43 { |
|
44 enum TCreatorLogsStatus{ |
|
45 ECreatorLogsDelete = 0, |
|
46 ECreatorLogsStart |
|
47 }; |
|
48 |
|
49 public: |
|
50 static CCreatorLogs* NewL(CCreatorEngine* aEngine); |
|
51 static CCreatorLogs* NewLC(CCreatorEngine* aEngine); |
|
52 ~CCreatorLogs(); |
|
53 |
|
54 private: |
|
55 CCreatorLogs(); |
|
56 void ConstructL(CCreatorEngine* aEngine); // from MCreatorModuleBase |
|
57 |
|
58 void RunL(); // from CActive |
|
59 void DoCancel(); // from CActive |
|
60 |
|
61 public: |
|
62 TBool AskDataFromUserL( TInt aCommand ); // from MCreatorModuleBase |
|
63 void QueryDialogClosedL(TBool aPositiveAction, TInt aUserData); |
|
64 |
|
65 TInt CreateMissedCallEntryL(CLogsParameters *aParameters); |
|
66 TInt CreateReceivedCallEntryL(CLogsParameters *aParameters); |
|
67 TInt CreateDialledNumberEntryL(CLogsParameters *aParameters); |
|
68 void DeleteAllL(); |
|
69 void DeleteAllCreatedByCreatorL(); |
|
70 |
|
71 private: |
|
72 CCreatorEngine* iEngine; |
|
73 TInt iCommand; |
|
74 TInt iEntriesToBeCreated; |
|
75 TInt iDummy; |
|
76 |
|
77 CLogClient* iLogClient; |
|
78 CLogEvent* iLogEvent; |
|
79 CActiveSchedulerWait iLogWriteWait; |
|
80 |
|
81 CLogsParameters* iParameters; |
|
82 RArray<TInt> iEntryIds; // TLogId ( == TInt32) CLogEvent::Id() |
|
83 |
|
84 public: |
|
85 }; |
|
86 |
|
87 |
|
88 class CLogsParameters : public CCreatorModuleBaseParameters |
|
89 { |
|
90 public: |
|
91 /*HBufC* iMissedCallPhoneNumber; |
|
92 TTime iMissedCallEventTime; |
|
93 |
|
94 HBufC* iReceivedCallPhoneNumber; |
|
95 TTime iReceivedCallEventTime; |
|
96 TLogDuration iReceivedCallDuration; |
|
97 |
|
98 HBufC* iDialledNumberPhoneNumber; |
|
99 TTime iDialledNumberEventTime; |
|
100 TLogDuration iDialledNumberDuration;*/ |
|
101 HBufC* iPhoneNumber; |
|
102 TTime iEventTime; |
|
103 TLogDuration iDuration; |
|
104 |
|
105 public: |
|
106 CLogsParameters(); |
|
107 ~CLogsParameters(); |
|
108 }; |
|
109 |
|
110 |
|
111 |
|
112 #endif // __CREATORLOGS_H__ |