|
1 /* |
|
2 * Copyright (c) 2008 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: Storage view implementation |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 // INCLUDE FILES |
|
20 #include "s_vimpststorageviewid.h" |
|
21 |
|
22 #include "MVIMPSTStorageContactList.h" |
|
23 |
|
24 |
|
25 // ----------------------------------------------------------------------------- |
|
26 // MyMVIMPSTStorageViewIdStub::AddContactListIdL |
|
27 // ----------------------------------------------------------------------------- |
|
28 // |
|
29 MVIMPSTStorageContactList* MyMVIMPSTStorageViewIdStub::AddContactListIdL( |
|
30 const TDesC& /*aContactListId*/, |
|
31 const TDesC& /*aDisplayName*/, |
|
32 TBool /*aNotify*/ ) |
|
33 { |
|
34 //CVIMPSTStorageContactList* contactList = CVIMPSTStorageContactList::NewL(); |
|
35 |
|
36 return NULL; |
|
37 } |
|
38 |
|
39 |
|
40 |
|
41 // ----------------------------------------------------------------------------- |
|
42 // MyMVIMPSTStorageViewIdStub::RemoveContactList |
|
43 // ----------------------------------------------------------------------------- |
|
44 // |
|
45 void MyMVIMPSTStorageViewIdStub::RemoveContactList( const TDesC& /*aContactListId*/ ) |
|
46 { |
|
47 |
|
48 } |
|
49 |
|
50 // ----------------------------------------------------------------------------- |
|
51 // MyMVIMPSTStorageViewIdStub::RemoveContact |
|
52 // From MVIMPSTStorageContacts. |
|
53 // ----------------------------------------------------------------------------- |
|
54 void MyMVIMPSTStorageViewIdStub::RemoveContact( const TDesC& /*aListId*/, |
|
55 const TDesC& /*aContactId*/ ) |
|
56 { |
|
57 |
|
58 } |
|
59 |
|
60 // ----------------------------------------------------------------------------- |
|
61 // MyMVIMPSTStorageViewIdStub::FindContact |
|
62 // From MVIMPSTStorageContacts. |
|
63 // Try to load with given ID, return NULL if not found. |
|
64 // ----------------------------------------------------------------------------- |
|
65 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindContact( const TDesC& /*aContactListId*/, |
|
66 const TDesC& /*aId*/ ) |
|
67 { |
|
68 return NULL; |
|
69 } |
|
70 |
|
71 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindContact( const TDesC& /*aContactListId*/, |
|
72 const TDesC& /*aId*/ , |
|
73 MVIMPSTStorageContactList*& /*aContactList*/ ) |
|
74 { |
|
75 return NULL; |
|
76 } |
|
77 |
|
78 // ----------------------------------------------------------------------------- |
|
79 // MyMVIMPSTStorageViewIdStub::ContactInAnyList |
|
80 // From MVIMPSTStorageContacts. |
|
81 // ----------------------------------------------------------------------------- |
|
82 TBool MyMVIMPSTStorageViewIdStub::ContactInAllLists( const TDesC& /*aContactId*/ ) const |
|
83 { |
|
84 return ETrue; |
|
85 } |
|
86 |
|
87 // ----------------------------------------------------------------------------- |
|
88 // MyMVIMPSTStorageViewIdStub::FindContact |
|
89 // From MVIMPSTStorageContacts. |
|
90 // Try to load with given ID, return NULL if not found. |
|
91 // ----------------------------------------------------------------------------- |
|
92 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindAnyContact( const TDesC& /*aContactId*/ ) |
|
93 { |
|
94 return NULL; |
|
95 } |
|
96 // ----------------------------------------------------------------------------- |
|
97 // MyMVIMPSTStorageViewIdStub::FindContact |
|
98 // From MVIMPSTStorageContacts. |
|
99 // Try to load with given ID, return NULL if not found. |
|
100 // ----------------------------------------------------------------------------- |
|
101 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindAnyContactByName( const TDesC& /*aContactId*/ ) |
|
102 { |
|
103 return NULL; |
|
104 } |
|
105 |
|
106 |
|
107 // ----------------------------------------------------------------------------- |
|
108 // MyMVIMPSTStorageViewIdStub::ListCount |
|
109 // Count of contactlists |
|
110 // ----------------------------------------------------------------------------- |
|
111 // |
|
112 TInt MyMVIMPSTStorageViewIdStub::ListCount() const |
|
113 { |
|
114 return 1; |
|
115 } |
|
116 |
|
117 |
|
118 // ----------------------------------------------------------------------------- |
|
119 // MyMVIMPSTStorageViewIdStub::ListAt |
|
120 // Reference to contact list |
|
121 // ----------------------------------------------------------------------------- |
|
122 // |
|
123 MVIMPSTStorageContactList& MyMVIMPSTStorageViewIdStub::ListAt( TInt /*aIndex*/ ) const |
|
124 { |
|
125 // FIXME ASSERT |
|
126 MVIMPSTStorageContactList *abc = NULL; |
|
127 |
|
128 return *abc; |
|
129 } |
|
130 |
|
131 |
|
132 // ----------------------------------------------------------------------------- |
|
133 // MyMVIMPSTStorageViewIdStub::ContactCount |
|
134 // Count of contacts |
|
135 // ----------------------------------------------------------------------------- |
|
136 // |
|
137 TInt MyMVIMPSTStorageViewIdStub::ContactCount( TBool /*aSkipOfflineContacts*/ ) const |
|
138 { |
|
139 TInt contactCount( 0 ); |
|
140 |
|
141 return contactCount; |
|
142 } |
|
143 |
|
144 |
|
145 // ----------------------------------------------------------------------------- |
|
146 // MyMVIMPSTStorageViewIdStub::CreateContactL |
|
147 // From MVIMPSTExtendedStorageContact |
|
148 // ----------------------------------------------------------------------------- |
|
149 // |
|
150 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::CreateContactL( |
|
151 const TDesC& /*aContactList*/, |
|
152 const TDesC& /*aWVID*/, |
|
153 MVPbkContactLink* /*aContactLink*/, |
|
154 CVPbkContactManager& /*aContactManager*/, |
|
155 MVIMPSTStorageContactManagementObserver& /*aContactManagementObserver*/ ) |
|
156 { |
|
157 |
|
158 return NULL; |
|
159 } |
|
160 |
|
161 // ----------------------------------------------------------------------------- |
|
162 // MyMVIMPSTStorageViewIdStub::CreateContactL |
|
163 // ----------------------------------------------------------------------------- |
|
164 // |
|
165 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::CreateContactL( |
|
166 MVIMPSTStorageContactList& /*aContactList*/, |
|
167 const TDesC& /*aWVID*/, |
|
168 TVIMPSTEnums::TOnlineStatus /*aStatus*/, |
|
169 const TDesC& /*aStatusText*/, |
|
170 MVPbkContactLink* /*aContactLink*/, |
|
171 CVPbkContactManager& /*aContactManager*/, |
|
172 MVIMPSTStorageContactManagementObserver& /* aContactManagementObserver*/) |
|
173 { |
|
174 |
|
175 // this is used at fetching, so do not notify any observer, will be done for whole list |
|
176 return NULL; |
|
177 } |
|
178 |
|
179 // ----------------------------------------------------------------------------- |
|
180 // MyMVIMPSTStorageViewIdStub::RemoveAllContactsL |
|
181 // ----------------------------------------------------------------------------- |
|
182 // |
|
183 void MyMVIMPSTStorageViewIdStub::RemoveAllContactsL() |
|
184 { |
|
185 |
|
186 } |
|
187 |
|
188 |
|
189 |
|
190 // ----------------------------------------------------------------------------- |
|
191 // MyMVIMPSTStorageViewIdStub::UpdatepresenceL |
|
192 // ----------------------------------------------------------------------------- |
|
193 // |
|
194 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::UpdatePresenceL( |
|
195 const TDesC& /*aContactId*/, |
|
196 TVIMPSTEnums::TOnlineStatus/* aStatus*/, |
|
197 const TDesC& /*aAlias*/, |
|
198 const TDesC& /*aStatusText*/) |
|
199 { |
|
200 return NULL; |
|
201 } |
|
202 |
|
203 |
|
204 |
|
205 // ----------------------------------------------------------------------------- |
|
206 // MyMVIMPSTStorageViewIdStub::OwnStatus |
|
207 // ----------------------------------------------------------------------------- |
|
208 // |
|
209 MVIMPSTStorageContact& MyMVIMPSTStorageViewIdStub::OwnStatus() |
|
210 { |
|
211 MVIMPSTStorageContact* own = NULL; |
|
212 return *own; |
|
213 } |
|
214 |
|
215 |
|
216 // ----------------------------------------------------------------------------- |
|
217 // MyMVIMPSTStorageViewIdStub::IsContactValid |
|
218 // ----------------------------------------------------------------------------- |
|
219 // |
|
220 TBool MyMVIMPSTStorageViewIdStub::IsContactValid( const MVIMPSTStorageContact* /*aContact*/ ) const |
|
221 { |
|
222 // contact not found |
|
223 return EFalse; |
|
224 } |
|
225 |
|
226 // ----------------------------------------------------------------------------- |
|
227 // MyMVIMPSTStorageViewIdStub::SortContactLists |
|
228 // ----------------------------------------------------------------------------- |
|
229 // |
|
230 void MyMVIMPSTStorageViewIdStub::SortContactLists() |
|
231 { |
|
232 |
|
233 } |
|
234 |
|
235 // ----------------------------------------------------------------------------- |
|
236 // MyMVIMPSTStorageViewIdStub::FindContactList |
|
237 // ----------------------------------------------------------------------------- |
|
238 // |
|
239 MVIMPSTStorageContactList* MyMVIMPSTStorageViewIdStub::FindContactList( const TDesC& /*aListId */) |
|
240 { |
|
241 return NULL; |
|
242 } |
|
243 |
|
244 /** |
|
245 * From MVIMPSTStorageContacts |
|
246 */ |
|
247 MVIMPSTStorageVpbkStoreHandler& MyMVIMPSTStorageViewIdStub::GetStoreHandler( ) |
|
248 { |
|
249 MVIMPSTStorageVpbkStoreHandler* storehandler = NULL; |
|
250 return *storehandler; |
|
251 } |
|
252 |
|
253 /** |
|
254 * From MVIMPSTStorageContacts |
|
255 */ |
|
256 MVPbkStoreContact* MyMVIMPSTStorageViewIdStub::CreateNewContactLC( ) |
|
257 { |
|
258 MVPbkStoreContact* contact = NULL; |
|
259 return contact; |
|
260 } |
|
261 |
|
262 /** |
|
263 * From MVIMPSTStorageContacts |
|
264 */ |
|
265 void MyMVIMPSTStorageViewIdStub::AddObserverL( MVIMPSTStorageContactsObserver* /*aObserver*/ ) |
|
266 { |
|
267 |
|
268 } |
|
269 |
|
270 |
|
271 /** |
|
272 * From MVIMPSTStorageContacts |
|
273 */ |
|
274 void MyMVIMPSTStorageViewIdStub::RemoveObserver( MVIMPSTStorageContactsObserver* /*aObserver*/ ) |
|
275 { |
|
276 |
|
277 } |
|
278 |
|
279 |
|
280 |
|
281 /** |
|
282 * From MVIMPSTStorageContacts |
|
283 */ |
|
284 TInt MyMVIMPSTStorageViewIdStub::FindContact( const MVIMPSTStorageContact& /*aContact*/ ) const |
|
285 { |
|
286 return 0; |
|
287 } |
|
288 |
|
289 |
|
290 /** |
|
291 * From MVIMPSTStorageContacts |
|
292 */ |
|
293 void MyMVIMPSTStorageViewIdStub::FindContacts( RPointerArray< MVIMPSTStorageContact >& /*aArray*/, |
|
294 const TDesC& /*aContactId*/ ) const |
|
295 { |
|
296 |
|
297 } |
|
298 |
|
299 |
|
300 /** |
|
301 * From MVIMPSTStorageContacts |
|
302 */ |
|
303 void MyMVIMPSTStorageViewIdStub::Sort( const TDesC& /*aContactListId*/ ) |
|
304 { |
|
305 |
|
306 } |
|
307 |
|
308 /** |
|
309 * Resort one contact, what ever contact list it is in |
|
310 */ |
|
311 void MyMVIMPSTStorageViewIdStub::ResortContactInAll( MVIMPSTStorageContact* /*aContact*/ ) |
|
312 { |
|
313 |
|
314 } |
|
315 |
|
316 /** |
|
317 * From MVIMPSTStorageContacts |
|
318 */ |
|
319 void MyMVIMPSTStorageViewIdStub::SetSortAlgorithm( MVIMPSTStorageContact::TSortAlgorithm /*aAlgorithm*/ ) |
|
320 { |
|
321 |
|
322 } |
|
323 |
|
324 /** |
|
325 * From MVIMPSTStorageContacts |
|
326 */ |
|
327 TVIMPSTEnums::TOnlineStatus MyMVIMPSTStorageViewIdStub::OnlineStatus( const TDesC& /*aContactId*/ ) |
|
328 { |
|
329 return iStatus; |
|
330 } |
|
331 |
|
332 |
|
333 /** |
|
334 * From MVIMPSTStorageContacts |
|
335 */ |
|
336 void MyMVIMPSTStorageViewIdStub::SetNotifyOnSave( TBool /*aStatus*/ ) |
|
337 { |
|
338 |
|
339 } |
|
340 |
|
341 |
|
342 /** |
|
343 * MVIMPSTStorageContacts |
|
344 */ |
|
345 void MyMVIMPSTStorageViewIdStub::SendContactListUpdatedEvent( MVIMPSTStorageContactList& /*aList*/ ) |
|
346 { |
|
347 |
|
348 } |
|
349 |
|
350 |
|
351 /** |
|
352 * add contact to the virtual phonebook. |
|
353 */ |
|
354 void MyMVIMPSTStorageViewIdStub::AddServerContactL( const TDesC& /*aContact*/) |
|
355 { |
|
356 |
|
357 } |
|
358 |
|
359 |
|
360 /** |
|
361 * add selected pbk2 contact to the service store. |
|
362 * @param aContact contact selected from phone book. |
|
363 */ |
|
364 void MyMVIMPSTStorageViewIdStub::AddPhoneBookContactL( const MVPbkStoreContact& /*aContact */) |
|
365 { |
|
366 |
|
367 } |
|
368 |
|
369 /** |
|
370 * add selected contact to the phone book. |
|
371 * @param aContact selected contact. |
|
372 */ |
|
373 void MyMVIMPSTStorageViewIdStub::AddContactToPhoneBookL( const MVIMPSTStorageContact& /*aContact*/ ) |
|
374 { |
|
375 |
|
376 } |
|
377 |
|
378 /** |
|
379 * removes contact from the virtual phonebook. |
|
380 */ |
|
381 void MyMVIMPSTStorageViewIdStub::RemoveServerContactL( const TDesC& /*aContact*/) |
|
382 { |
|
383 |
|
384 } |
|
385 void MyMVIMPSTStorageViewIdStub::UpdateAvatarDataL( const TDesC& /*aContactId*/ ,const TDesC8& /*aData*/) |
|
386 { |
|
387 |
|
388 } |
|
389 |
|
390 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindContactByName( const TDesC& /*aContactListId*/, |
|
391 const TDesC& /*aId*/ ) |
|
392 { |
|
393 MVIMPSTStorageContact* contact= NULL; |
|
394 return contact; |
|
395 } |
|
396 |
|
397 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindContactByName( const TDesC& /*aContactListId*/, |
|
398 const TDesC& /*aId*/, |
|
399 MVIMPSTStorageContactList*& /*aContactList*/ ) |
|
400 { |
|
401 MVIMPSTStorageContact* contact= NULL; |
|
402 return contact; |
|
403 } |
|
404 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindContact( const MVPbkContactLink& /*aContactLink*/, |
|
405 MVIMPSTStorageContactList*& /*aContactList*/ ) |
|
406 |
|
407 { |
|
408 MVIMPSTStorageContact* contact= NULL; |
|
409 return contact; |
|
410 } |
|
411 |
|
412 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::FindContactByServiceField( const TDesC& /*aServiceId */) |
|
413 { |
|
414 MVIMPSTStorageContact* contact= NULL; |
|
415 return contact; |
|
416 } |
|
417 |
|
418 MVIMPSTStorageContact* MyMVIMPSTStorageViewIdStub::AddContactL( const TDesC& /*aFirstName*/ /*= KNullDesC*/,const TDesC& /*aServiceField*/ /*= KNullDesC */) |
|
419 { |
|
420 MVIMPSTStorageContact* contact= NULL; |
|
421 return contact; |
|
422 } |
|
423 |
|
424 void MyMVIMPSTStorageViewIdStub::RemoveContactL( const MVPbkContactLink& /*aContactLink*/) |
|
425 { |
|
426 |
|
427 } |
|
428 |
|
429 void MyMVIMPSTStorageViewIdStub::RemoveContactL( const TDesC& /*aServiceContactId*/) |
|
430 |
|
431 { |
|
432 |
|
433 } |
|
434 |
|
435 void MyMVIMPSTStorageViewIdStub::SetOwnDataL( const TDesC& aOwnId ) |
|
436 { |
|
437 iOwnId = NULL; |
|
438 iOwnId = aOwnId.AllocL(); |
|
439 } |
|
440 |
|
441 // ----------------------------------------------------------------------------- |
|
442 |
|
443 |
|
444 |
|
445 // End of File |