|
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: common mailbox object |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 #ifndef CFSMAILPLUGINMANAGER_H |
|
20 #define CFSMAILPLUGINMANAGER_H |
|
21 |
|
22 |
|
23 // INCLUDES |
|
24 #include <e32std.h> |
|
25 #include <e32base.h> |
|
26 #include <ecom/ecom.h> |
|
27 |
|
28 #include "CFSMailPlugin.h" |
|
29 |
|
30 #include "CFSMailRequestHandler.h" |
|
31 |
|
32 /** plugin configuration at start up */ |
|
33 enum TFsFwConfiguration |
|
34 { |
|
35 EFSListPlugins = 1, |
|
36 EFSLoadPlugins, |
|
37 EFSLoadPluginsAndMockup, |
|
38 EFSLoadMockupOnly |
|
39 }; |
|
40 |
|
41 /** |
|
42 * email framework plugin manager |
|
43 * |
|
44 * @lib FSFWCommonLib |
|
45 * @since S60 v3.1 |
|
46 */ |
|
47 class CFSMailPluginManager : public CFSMailRequestHandler |
|
48 { |
|
49 |
|
50 public: |
|
51 |
|
52 |
|
53 /** |
|
54 * destructor |
|
55 */ |
|
56 ~CFSMailPluginManager(); |
|
57 |
|
58 /** |
|
59 * two based constructor |
|
60 */ |
|
61 static CFSMailPluginManager* NewL(TInt aConfiguration); |
|
62 |
|
63 /** |
|
64 * two based constructor |
|
65 */ |
|
66 static CFSMailPluginManager* NewLC(TInt aConfiguration); |
|
67 |
|
68 /** |
|
69 * adds new plugin to plugin list |
|
70 * |
|
71 */ |
|
72 void AppendPluginL(CFSMailPlugin* aPlugin,CImplementationInformation* aPluginInfo); |
|
73 |
|
74 /** |
|
75 * returns plugin pointer by plugin table index |
|
76 * |
|
77 * @return plugin pointer |
|
78 */ |
|
79 CFSMailPlugin* GetPluginByIndex(TUint aIndex); |
|
80 |
|
81 /** |
|
82 * get plugin id by plugin table index |
|
83 * |
|
84 */ |
|
85 TUid GetPluginIdByIndex(TUint aIndex); |
|
86 |
|
87 /** |
|
88 * returns count of existing plugins |
|
89 * |
|
90 */ |
|
91 TUint GetPluginCount( ); |
|
92 |
|
93 /** |
|
94 * loads plugin identified by plugin id |
|
95 * |
|
96 */ |
|
97 void LoadPluginL(TUid aPluginId); |
|
98 |
|
99 /** |
|
100 * list ids of existing plugins |
|
101 * |
|
102 */ |
|
103 void ListPlugins( RArray<TUid>& aPluginList ); |
|
104 |
|
105 /** |
|
106 * lists plugin pointers & plugin info |
|
107 * |
|
108 */ |
|
109 void ListImplementationsL( RPointerArray<CFSMailPlugin>& aImplementations, |
|
110 RPointerArray<CImplementationInformation>& aInfo ); |
|
111 |
|
112 protected: |
|
113 |
|
114 /** |
|
115 * C++ default constructor. |
|
116 * |
|
117 */ |
|
118 |
|
119 CFSMailPluginManager(); |
|
120 |
|
121 /** |
|
122 * ConstructL |
|
123 */ |
|
124 void ConstructL(TInt aConfiguration); |
|
125 |
|
126 private: // data |
|
127 |
|
128 /** plugin information table */ |
|
129 RPointerArray<CImplementationInformation> iPluginInfo; |
|
130 |
|
131 }; |
|
132 |
|
133 |
|
134 #endif // CFSMAILPLUGINMANAGER_H |
|
135 |
|
136 // End of File |