|
1 /* |
|
2 * Copyright (c) 2007-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: handles synchronisation of contacts |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef __CCONTACTSYNCHANDLER_H__ |
|
20 #define __CCONTACTSYNCHANDLER_H__ |
|
21 |
|
22 |
|
23 // INCLUDES |
|
24 #include <e32base.h> |
|
25 #include <ximpbase.h> |
|
26 |
|
27 #include <presencecachewriter.h> |
|
28 #include <presencebuddyinfo.h> |
|
29 |
|
30 // FORWARD DECLARATIONS |
|
31 |
|
32 class MOSSProtocolConnectionManager; |
|
33 |
|
34 /** |
|
35 * CContactSyncHandler |
|
36 * |
|
37 * handles synchronisation of contacts from Network Server |
|
38 * |
|
39 */ |
|
40 |
|
41 class CContactSyncHandler: public CActive |
|
42 |
|
43 |
|
44 { |
|
45 |
|
46 public: |
|
47 |
|
48 static CContactSyncHandler* NewL ( MOSSProtocolConnectionManager& aConnMan ); |
|
49 |
|
50 virtual ~CContactSyncHandler(); |
|
51 |
|
52 private: |
|
53 |
|
54 CContactSyncHandler ( MOSSProtocolConnectionManager& aConnMan ); |
|
55 |
|
56 private: // from CActive |
|
57 |
|
58 void DoCancel(); |
|
59 void RunL(); |
|
60 TInt RunError ( TInt aError ); |
|
61 |
|
62 public: |
|
63 |
|
64 /** |
|
65 * keep on listening for events |
|
66 */ |
|
67 void StartListening(); |
|
68 |
|
69 /** |
|
70 * Processes the data from server and sends to ximpfw |
|
71 */ |
|
72 void ProcessAndSendL(); |
|
73 |
|
74 private: // data |
|
75 |
|
76 /** |
|
77 * Oss Protocol Plugin Connection Manager |
|
78 * Not own. |
|
79 */ |
|
80 MOSSProtocolConnectionManager& iConnMan; |
|
81 |
|
82 }; |
|
83 |
|
84 |
|
85 #endif // __CCONTACTSYNCHANDLER_H__ |
|
86 |