author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Tue, 31 Aug 2010 16:06:03 +0300 | |
branch | RCL_3 |
changeset 44 | 0b68a1b0c15e |
parent 36 | c210248fa89d |
child 45 | a9c0808a1095 |
permissions | -rw-r--r-- |
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: Implements callback methods which is called my core dll call |
|
15 |
* callback methods. |
|
16 |
* |
|
17 |
*/ |
|
18 |
||
19 |
#include <liwserviceifbase.h> |
|
23
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
5
diff
changeset
|
20 |
#include <liwcommon.h> |
26
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
21 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
22 |
#ifndef SYMBIAN_ENABLE_SPLIT_HEADERS |
5 | 23 |
#include <logwrap.h> |
26
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
24 |
#else |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
25 |
#include <logwrap.h> |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
26 |
#include <logengevents.h> |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
27 |
#include <logwraplimits.h> |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
28 |
#include <logfilterandeventconstants.hrh> |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
29 |
#include <logengdurations.h> |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
30 |
#endif |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
31 |
|
23
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
5
diff
changeset
|
32 |
#include <logclientchangeobserver.h> |
5 | 33 |
|
34 |
#include "logiter.h" |
|
35 |
#include "logginginterface.h" |
|
36 |
#include "loggingasyncservice.h" |
|
37 |
#include "loggingcallback.h" |
|
38 |
#include "loggingevent.h" |
|
39 |
#include "liwlogiter.h" |
|
40 |
||
41 |
||
42 |
/** |
|
43 |
* OverLoaded constructor which accepts the callback adderss |
|
44 |
* and registers it |
|
45 |
*/ |
|
46 |
LoggingInterfaceCB :: LoggingInterfaceCB( MLiwNotifyCallback* aCallBack ) : iCallBack(aCallBack) |
|
47 |
{ |
|
48 |
} |
|
49 |
||
50 |
/** |
|
51 |
* Default destructor |
|
52 |
*/ |
|
53 |
LoggingInterfaceCB :: ~LoggingInterfaceCB() |
|
54 |
{ |
|
55 |
//delete iOutParmList; |
|
56 |
} |
|
57 |
||
58 |
/** |
|
59 |
* overloaded NewL function for creating local call back objects |
|
60 |
* as required by logginginterface.cpp |
|
61 |
*/ |
|
62 |
LoggingInterfaceCB *LoggingInterfaceCB :: NewL( MLiwNotifyCallback* aCallBack ) |
|
63 |
{ |
|
64 |
LoggingInterfaceCB *self = new( ELeave ) LoggingInterfaceCB( aCallBack ) ; |
|
65 |
return self ; |
|
66 |
} |
|
67 |
||
68 |
/** |
|
69 |
* HandleNotifyL method, callback method, called by the core class |
|
70 |
* for async events |
|
71 |
*/ |
|
72 |
||
73 |
void LoggingInterfaceCB :: HandleNotifyL( TUint aTransId, TUint aStatus, CLogIter *aIter ) |
|
74 |
{ |
|
75 |
CleanupStack :: PushL( this ) ; |
|
76 |
||
77 |
CLiwGenericParamList *OutParm = CLiwGenericParamList :: NewL() ; |
|
78 |
CleanupStack :: PushL(OutParm) ; |
|
79 |
CLiwGenericParamList *InParm = CLiwGenericParamList :: NewL() ; |
|
80 |
CleanupStack :: PushL(InParm) ; |
|
81 |
||
82 |
TInt32 sapierror ; |
|
83 |
||
84 |
sapierror = CLoggingInterface::ConvertToSapiError( aStatus ); |
|
85 |
||
86 |
OutParm->AppendL(TLiwGenericParam(KErrCode , TLiwVariant((TInt32)sapierror))) ; |
|
87 |
||
88 |
switch( iRequestType ) |
|
89 |
{ |
|
90 |
case EReadEvents : |
|
91 |
{ |
|
35
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
92 |
if( aStatus == KErrNone ) |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
93 |
{ |
5 | 94 |
CLiwLogIter *iter = CLiwLogIter :: NewL( aIter ) ; |
95 |
CleanupClosePushL( *iter ); |
|
96 |
OutParm->AppendL( TLiwGenericParam ( KResponse , TLiwVariant( iter ) ) ) ; |
|
97 |
CleanupStack :: Pop( iter ) ; |
|
98 |
iter->DecRef(); |
|
99 |
iCallBack->HandleNotifyL( aTransId, KLiwEventCompleted, *OutParm, *InParm ) ; |
|
35
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
100 |
} |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
101 |
else |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
102 |
{ |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
103 |
iCallBack->HandleNotifyL( aTransId, KLiwEventError, *OutParm, *InParm ) ; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
104 |
delete aIter; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
105 |
aIter = NULL; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
106 |
} |
5 | 107 |
CleanupStack::PopAndDestroy( InParm ); |
108 |
CleanupStack::PopAndDestroy( OutParm ); |
|
109 |
CleanupStack :: Pop( this ) ; |
|
110 |
delete this ; |
|
111 |
break ; |
|
112 |
} |
|
113 |
||
114 |
case EGetEvent : |
|
115 |
{ |
|
35
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
116 |
if( aStatus == KErrNone ) |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
117 |
{ |
5 | 118 |
CLiwLogIter *iter = CLiwLogIter :: NewL( aIter ) ; |
119 |
CleanupClosePushL( *iter ); |
|
120 |
OutParm->AppendL( TLiwGenericParam ( KResponse , TLiwVariant( iter ) ) ) ; |
|
121 |
CleanupStack :: Pop( iter ) ; |
|
122 |
iter->DecRef(); |
|
123 |
iCallBack->HandleNotifyL( aTransId, KLiwEventCompleted, *OutParm, *InParm ) ; |
|
35
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
124 |
} |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
125 |
else |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
126 |
{ |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
127 |
iCallBack->HandleNotifyL( aTransId, KLiwEventError, *OutParm, *InParm ) ; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
128 |
delete aIter; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
129 |
aIter = NULL; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
130 |
} |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
131 |
CleanupStack::PopAndDestroy( InParm ); |
5 | 132 |
CleanupStack::PopAndDestroy( OutParm ); |
133 |
CleanupStack :: Pop( this ) ; |
|
134 |
delete this ; |
|
135 |
break ; |
|
136 |
} |
|
137 |
||
138 |
case EGetRecent : |
|
139 |
{ |
|
35
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
140 |
if( aStatus == KErrNone ) |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
141 |
{ |
5 | 142 |
CLiwLogIter *iter = CLiwLogIter :: NewL( aIter ) ; |
143 |
CleanupClosePushL( *iter ); |
|
144 |
OutParm->AppendL( TLiwGenericParam ( KResponse , TLiwVariant( iter ) ) ) ; |
|
145 |
CleanupStack :: Pop( iter ) ; |
|
146 |
iter->DecRef(); |
|
147 |
iCallBack->HandleNotifyL( aTransId, KLiwEventCompleted, *OutParm, *InParm ) ; |
|
35
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
148 |
} |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
149 |
else |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
150 |
{ |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
151 |
iCallBack->HandleNotifyL( aTransId, KLiwEventError, *OutParm, *InParm ) ; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
152 |
delete aIter; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
153 |
aIter = NULL; |
68159986cd41
Revision: 201011
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
26
diff
changeset
|
154 |
} |
5 | 155 |
CleanupStack::PopAndDestroy( InParm ); |
156 |
CleanupStack::PopAndDestroy( OutParm ); |
|
157 |
CleanupStack :: Pop( this ) ; |
|
158 |
delete this ; |
|
159 |
break ; |
|
160 |
} |
|
161 |
||
162 |
case EAddEvent : |
|
163 |
{ |
|
164 |
if( aStatus == KErrNone ) |
|
165 |
{ |
|
166 |
TLogId ret=(aIter->Event())->Id(); |
|
167 |
TBuf<8> des; |
|
168 |
des.Num( ret ); |
|
169 |
OutParm->AppendL( TLiwGenericParam ( KResponse , TLiwVariant( des ) ) ) ; |
|
170 |
iCallBack->HandleNotifyL( aTransId, KLiwEventCompleted, *OutParm, *InParm ) ; |
|
171 |
} |
|
172 |
else |
|
173 |
{ |
|
174 |
iCallBack->HandleNotifyL( aTransId, KLiwEventError, *OutParm, *InParm ) ; |
|
175 |
} |
|
176 |
||
177 |
CleanupStack::PopAndDestroy( InParm ); |
|
178 |
CleanupStack::PopAndDestroy( OutParm ); |
|
179 |
CleanupStack :: Pop( this ) ; |
|
180 |
delete this ; |
|
181 |
delete aIter; |
|
182 |
break ; |
|
183 |
} |
|
184 |
||
185 |
case ENotification : |
|
186 |
{ |
|
187 |
iCallBack->HandleNotifyL( aTransId, KLiwEventInProgress, *OutParm, *InParm ) ; |
|
188 |
CleanupStack::PopAndDestroy( InParm ); |
|
189 |
CleanupStack::PopAndDestroy( OutParm ); |
|
190 |
CleanupStack :: Pop( this ) ; |
|
191 |
break ; |
|
192 |
} |
|
193 |
||
194 |
case EDeleteEvent : |
|
195 |
{ |
|
196 |
if( aStatus == KErrNone ) |
|
197 |
{ |
|
198 |
iCallBack->HandleNotifyL( aTransId, KLiwEventCompleted, *OutParm, *InParm ) ; |
|
199 |
} |
|
200 |
else |
|
201 |
{ |
|
202 |
iCallBack->HandleNotifyL( aTransId, KLiwEventError, *OutParm, *InParm ) ; |
|
203 |
} |
|
204 |
CleanupStack::PopAndDestroy( InParm ); |
|
205 |
CleanupStack::PopAndDestroy( OutParm ); |
|
206 |
CleanupStack :: Pop( this ) ; |
|
207 |
delete this; |
|
208 |
break ; |
|
209 |
} |
|
210 |
||
211 |
default : |
|
212 |
{ |
|
213 |
break ; |
|
214 |
} |
|
215 |
} |
|
216 |
} |
|
217 |
||
26
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
218 |
void LoggingInterfaceCB :: HandleReqeustL( TUint aTransId, TUint aStatus, CLogsEvent *aEvents ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
219 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
220 |
TInt i = 0; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
221 |
CleanupStack :: PushL( this ) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
222 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
223 |
CLiwGenericParamList *OutParm = CLiwGenericParamList :: NewL() ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
224 |
CleanupStack :: PushL(OutParm) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
225 |
CLiwGenericParamList *InParm = CLiwGenericParamList :: NewL() ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
226 |
CleanupStack :: PushL(InParm) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
227 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
228 |
TInt32 sapierror ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
229 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
230 |
sapierror = CLoggingInterface::ConvertToSapiError( aStatus ); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
231 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
232 |
OutParm->AppendL(TLiwGenericParam(KErrCode , TLiwVariant((TInt32)sapierror))) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
233 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
234 |
CleanupStack::PushL(aEvents); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
235 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
236 |
CLiwDefaultMap *evntmap = CLiwDefaultMap :: NewL() ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
237 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
238 |
CleanupClosePushL( *evntmap ); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
239 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
240 |
TLiwVariant entry; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
241 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
242 |
/** |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
243 |
* Extract all the event details form CLogsEvent object |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
244 |
* and push it to the aEntry |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
245 |
*/ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
246 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
247 |
TInt32 val = 0 ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
248 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
249 |
switch( (aEvents->getEventType()).iUid ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
250 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
251 |
case KLogCallEventType : |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
252 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
253 |
val = CLoggingInterface :: EKLogCallEventType ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
254 |
break ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
255 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
256 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
257 |
case KLogDataEventType : |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
258 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
259 |
val = CLoggingInterface :: EKLogDataEventType ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
260 |
break ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
261 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
262 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
263 |
case KLogFaxEventType : |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
264 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
265 |
val = CLoggingInterface :: EKLogFaxEventType ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
266 |
break ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
267 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
268 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
269 |
case KLogShortMessageEventType : |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
270 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
271 |
val = CLoggingInterface :: EKLogShortMessageEventType ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
272 |
break ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
273 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
274 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
275 |
case KLogPacketDataEventType : |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
276 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
277 |
val = CLoggingInterface :: EKLogPacketDataEventType ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
278 |
break ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
279 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
280 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
281 |
default : |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
282 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
283 |
break ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
284 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
285 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
286 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
287 |
evntmap->InsertL(KEventTypeKey , TLiwVariant((TInt32)val)); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
288 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
289 |
evntmap->InsertL(KRemotePartyKey , TLiwVariant(aEvents->getRemoteParty())) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
290 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
291 |
evntmap->InsertL(KEventDurationKey ,TLiwVariant((TInt32)aEvents->getDuration())) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
292 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
293 |
evntmap->InsertL(KEventTimeKey , TLiwVariant(aEvents->getTime())) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
294 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
295 |
val = 0 ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
296 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
297 |
/** |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
298 |
* Need to convert status to int value |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
299 |
*/ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
300 |
if( ( ( aEvents->getStatus() ).Compare( KStatusPending ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
301 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
302 |
val = CLoggingInterface :: EStatusPending ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
303 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
304 |
else if( ( ( aEvents->getStatus() ).Compare( KStatusSent ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
305 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
306 |
val =CLoggingInterface :: EStatusSent ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
307 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
308 |
else if( ( ( aEvents->getStatus() ).Compare( KStatusFalied ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
309 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
310 |
val = CLoggingInterface :: EStatusFalied ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
311 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
312 |
else if( ( ( aEvents->getStatus() ).Compare( KStatusNone ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
313 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
314 |
val = CLoggingInterface :: EStatusNone; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
315 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
316 |
else if( ( ( aEvents->getStatus() ).Compare( KStatusDone ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
317 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
318 |
val = CLoggingInterface :: EStatusDone; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
319 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
320 |
else if( ( ( aEvents->getStatus() ).Compare( KStatusNotSent ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
321 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
322 |
val = CLoggingInterface :: EStatusNotSent; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
323 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
324 |
else if( ( ( aEvents->getStatus() ).Compare( KStatusScheduled ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
325 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
326 |
val = CLoggingInterface :: EStatusScheduled; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
327 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
328 |
else |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
329 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
330 |
val = CLoggingInterface :: EStatusNotPresent; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
331 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
332 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
333 |
if( val != -1 ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
334 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
335 |
evntmap->InsertL(KDeliveryStatusKey , TLiwVariant((TInt32)val)) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
336 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
337 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
338 |
evntmap->InsertL(KSubjectKey , TLiwVariant(aEvents->getSubject())) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
339 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
340 |
evntmap->InsertL(KPhoneNumberKey , TLiwVariant(aEvents->getNumber())) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
341 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
342 |
evntmap->InsertL(KDescriptionKey , TLiwVariant (aEvents->getDescription())) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
343 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
344 |
evntmap->InsertL(KLinkKey , TLiwVariant((TInt32)aEvents->getLink())) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
345 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
346 |
val = 0 ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
347 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
348 |
if( aEvents->Flags() & KLogEventContactSearched ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
349 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
350 |
val = CLoggingInterface :: EKLogEventContactSearched ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
351 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
352 |
else if( aEvents->Flags() & KLogEventRead ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
353 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
354 |
val = CLoggingInterface :: EKLogEventRead ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
355 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
356 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
357 |
else |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
358 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
359 |
val = CLoggingInterface :: EFlagNotPresent; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
360 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
361 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
362 |
if( val != -1 ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
363 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
364 |
evntmap->InsertL(KFlagsKey , TLiwVariant((TInt32)val) ); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
365 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
366 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
367 |
TInt32 ret = aEvents->Id(); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
368 |
TBuf<8> des; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
369 |
des.Num(ret); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
370 |
evntmap->InsertL(KLogId , TLiwVariant( des)) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
371 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
372 |
val = 0 ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
373 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
374 |
if( ( ( aEvents->getDirection() ).Compare( KIncomingEvent ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
375 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
376 |
val = CLoggingInterface :: EIncomingEvent ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
377 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
378 |
else if( ( ( aEvents->getDirection() ).Compare( KOutgoingEvent ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
379 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
380 |
val = CLoggingInterface :: EOutgoingEvent ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
381 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
382 |
else if( ( ( aEvents->getDirection() ).Compare( KIncomingEventAlternateline ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
383 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
384 |
val = CLoggingInterface :: EIncomingEventAlternateline ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
385 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
386 |
else if( ( ( aEvents->getDirection() ).Compare( KOutgoingEventAlternateline ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
387 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
388 |
val = CLoggingInterface :: EOutgoingEventAlternateline; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
389 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
390 |
else if( ( ( aEvents->getDirection() ).Compare( KFetchedEvent ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
391 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
392 |
val = CLoggingInterface :: EFetchedEvent; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
393 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
394 |
else if( ( ( aEvents->getDirection() ).Compare( KMissedEvent ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
395 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
396 |
val = CLoggingInterface :: EMissedEvent; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
397 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
398 |
else if( ( ( aEvents->getDirection() ).Compare( KMissedEventAlternateline ) ) == KErrNone ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
399 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
400 |
val = CLoggingInterface :: EMissedEventAlternateline; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
401 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
402 |
else |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
403 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
404 |
val = CLoggingInterface :: EDirectionNotPresent; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
405 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
406 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
407 |
if( val != -1 ) |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
408 |
{ |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
409 |
evntmap->InsertL(KDirectionKey , TLiwVariant((TInt32)val)) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
410 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
411 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
412 |
evntmap->InsertL(KEventDataKey , TLiwVariant(aEvents->getDataL())); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
413 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
414 |
entry.SetL( evntmap ) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
415 |
OutParm->AppendL( TLiwGenericParam( KResponse , entry ) ) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
416 |
CleanupStack :: Pop( evntmap ) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
417 |
evntmap->DecRef(); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
418 |
CleanupStack::Pop( aEvents ); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
419 |
delete aEvents; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
420 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
421 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
422 |
iCallBack->HandleNotifyL( aTransId, KLiwEventInProgress, *OutParm, *InParm ) ; |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
423 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
424 |
CleanupStack::PopAndDestroy( InParm ); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
425 |
CleanupStack::PopAndDestroy( OutParm ); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
426 |
CleanupStack::Pop(this); |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
427 |
} |
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
428 |
|
5d0ec8b709be
Revision: 200949
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
23
diff
changeset
|
429 |
|
44
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
430 |
void LoggingInterfaceCB :: CancelNotifyL( TUint aTransid ) |
5 | 431 |
{ |
44
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
432 |
CleanupStack :: PushL( this ) ; |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
433 |
CLiwGenericParamList *OutParm = CLiwGenericParamList :: NewL() ; |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
434 |
CleanupStack :: PushL( OutParm ) ; |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
435 |
CLiwGenericParamList *InParm = CLiwGenericParamList :: NewL() ; |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
436 |
CleanupStack :: PushL( InParm ) ; |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
437 |
OutParm->AppendL( TLiwGenericParam( KErrCode , TLiwVariant( ( TInt32 )SErrNone ) ) ) ; |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
438 |
iCallBack->HandleNotifyL( aTransid, KLiwEventCanceled, *OutParm, *InParm ) ; |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
439 |
CleanupStack::PopAndDestroy( InParm ); |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
440 |
CleanupStack::PopAndDestroy( OutParm ); |
0b68a1b0c15e
Revision: 201033
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
36
diff
changeset
|
441 |
CleanupStack :: Pop( this ) ; |
5 | 442 |
delete this; |
443 |
} |