|
1 /* |
|
2 * Copyright (c) 2005 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: |
|
15 * |
|
16 */ |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 #ifndef __CMCETESTUIENGINEEVENT_H__ |
|
22 #define __CMCETESTUIENGINEEVENT_H__ |
|
23 |
|
24 // USER INCLUDES |
|
25 |
|
26 // SYSTEM INCLUDES |
|
27 #include <e32base.h> |
|
28 |
|
29 |
|
30 // FORWARD DECLARATIONS |
|
31 |
|
32 class CMceManager; |
|
33 class CMceFCMsgExchange; |
|
34 class CMceEvent; |
|
35 class CMCETestUIEngine; |
|
36 class CMCETestUIEngineCmdBase; |
|
37 class CMCETestUIEngineProfile; |
|
38 |
|
39 // CLASS DECLARATION |
|
40 /** |
|
41 * |
|
42 * CMCETestUIEngineSession provides a wrapper for CMCESession. |
|
43 * Class is not the traditional wrapper in a sense that it would |
|
44 * conform to interface provided by CMCESession. Instead class |
|
45 * implements interface MMCETestUIEngineCmdProvider to provide |
|
46 * same kind of functionality in controlled way on different levels |
|
47 * of abstraction. |
|
48 * |
|
49 * TODO: Wrappers for streams and use of them. |
|
50 * |
|
51 */ |
|
52 class CMCETestUIEngineEvent : public CBase, |
|
53 public MMCETestUIEngineCmdProvider |
|
54 { |
|
55 |
|
56 public: // public enumerations |
|
57 |
|
58 /** |
|
59 * Enumeration for defining session's direction |
|
60 */ |
|
61 |
|
62 public: // Constructors and destructors |
|
63 |
|
64 /** |
|
65 * Destructor. |
|
66 */ |
|
67 IMPORT_C virtual ~CMCETestUIEngineEvent(); |
|
68 |
|
69 public: // From MMCETestUICommandProvider |
|
70 |
|
71 /** |
|
72 * Gets the commands applicaple to this session object. |
|
73 * |
|
74 * @return reference to array of commands |
|
75 */ |
|
76 IMPORT_C const RPointerArray<TMCETestUIEngineCmdBase>& |
|
77 GetCommandsL(); |
|
78 |
|
79 public: // New functions, pure virtual |
|
80 |
|
81 /** |
|
82 * @return Id of this particular session object |
|
83 */ |
|
84 IMPORT_C virtual TInt Id() const = 0; |
|
85 |
|
86 public: // New functions |
|
87 |
|
88 /** |
|
89 * @return Textual representation of the state of the wrapped MCESession |
|
90 */ |
|
91 IMPORT_C const TDesC& State() ; |
|
92 |
|
93 |
|
94 public: // New functions, internal |
|
95 |
|
96 /** |
|
97 * Gets wrapped MCESession object |
|
98 * |
|
99 * @return wrapped MCESession |
|
100 */ |
|
101 CMceEvent& Event(); |
|
102 |
|
103 |
|
104 |
|
105 private: // private constructors |
|
106 |
|
107 /** |
|
108 * C++ default constructor. Not implemented. |
|
109 */ |
|
110 CMCETestUIEngineEvent(); |
|
111 |
|
112 protected: |
|
113 |
|
114 /** |
|
115 * C++ first phase constructor. |
|
116 */ |
|
117 CMCETestUIEngineEvent( |
|
118 CMCETestUIEngine& aEngine ); |
|
119 |
|
120 /** |
|
121 * Symbian second-phase constructor |
|
122 */ |
|
123 void BaseConstructL(); |
|
124 |
|
125 protected: // owned data |
|
126 |
|
127 // Commands applicable to all sessions. Owned. |
|
128 RPointerArray<TMCETestUIEngineCmdBase> iCommands; |
|
129 |
|
130 |
|
131 protected: // not owned data |
|
132 |
|
133 CMCETestUIEngine& iEngine; |
|
134 |
|
135 // Pointer to wrapped OutSession/InSession |
|
136 CMceEvent* iEvent; |
|
137 |
|
138 |
|
139 }; |
|
140 |
|
141 #endif |