|
1 /* |
|
2 * Copyright (c) 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 "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: Singleton |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 #ifndef C_SENDUISINGLETON_H |
|
21 #define C_SENDUISINGLETON_H |
|
22 |
|
23 #include <e32base.h> |
|
24 #include <msvapi.h> |
|
25 |
|
26 class CMsvSession; |
|
27 class CClientMtmRegistry; |
|
28 class CMtmUiRegistry; |
|
29 class CMtmUiDataRegistry; |
|
30 |
|
31 /** |
|
32 * Singelton |
|
33 * |
|
34 * @lib sendui |
|
35 * @since S60 v3.2 |
|
36 */ |
|
37 NONSHARABLE_CLASS( CSendUiSingleton ) : public CBase, |
|
38 public MMsvSessionObserver |
|
39 { |
|
40 public: // Constructors and destructor |
|
41 |
|
42 /** |
|
43 * Two-phased constructor. |
|
44 * |
|
45 * @return Pointer to object of CSendUiSingleton. |
|
46 */ |
|
47 IMPORT_C static CSendUiSingleton* NewL(); |
|
48 |
|
49 /** |
|
50 * Destructor. |
|
51 */ |
|
52 virtual ~CSendUiSingleton(); |
|
53 |
|
54 public: // New functions |
|
55 |
|
56 /** |
|
57 * Returns message server session. |
|
58 * |
|
59 * @return message server session. |
|
60 */ |
|
61 IMPORT_C CMsvSession& MsvSessionL(); |
|
62 |
|
63 /** |
|
64 * Returns client MTM registry. |
|
65 * |
|
66 * @return client MTM registry. |
|
67 */ |
|
68 IMPORT_C CClientMtmRegistry& ClientMtmRegistryL(); |
|
69 |
|
70 /** |
|
71 * Returns MTM UI registry. |
|
72 * |
|
73 * @return MTM UI registry. |
|
74 */ |
|
75 IMPORT_C CMtmUiRegistry& MtmUiRegistryL(); |
|
76 |
|
77 /** |
|
78 * Returns MTM UI data registry. |
|
79 * |
|
80 * @return MTM UI registry. |
|
81 */ |
|
82 IMPORT_C CMtmUiDataRegistry& MtmUiDataRegistryL(); |
|
83 |
|
84 private: // From base classes |
|
85 |
|
86 /** |
|
87 * From MMsvSessionObserver |
|
88 */ |
|
89 virtual void HandleSessionEventL(TMsvSessionEvent aEvent, TAny* aArg1, TAny* aArg2, TAny* aArg3); |
|
90 |
|
91 private: |
|
92 |
|
93 /** |
|
94 * C++ default constructor. |
|
95 */ |
|
96 CSendUiSingleton(); |
|
97 |
|
98 /** |
|
99 * By default Symbian 2nd phase constructor is private. |
|
100 */ |
|
101 void ConstructL(); |
|
102 |
|
103 private: // Data |
|
104 |
|
105 /** |
|
106 * Own. |
|
107 */ |
|
108 CMsvSession* iMsvSession; |
|
109 |
|
110 /** |
|
111 * Own. |
|
112 */ |
|
113 CClientMtmRegistry* iClientMtmRegistry; |
|
114 |
|
115 /** |
|
116 * Own. |
|
117 */ |
|
118 CMtmUiRegistry* iMtmUiRegistry; |
|
119 |
|
120 /** |
|
121 * Own. |
|
122 */ |
|
123 CMtmUiDataRegistry* iMtmUiDataRegistry; |
|
124 |
|
125 }; |
|
126 |
|
127 #endif // C_SENDUISINGLETON_H |
|
128 |
|
129 // End of File |
|
130 |