author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Tue, 24 Nov 2009 08:56:33 +0200 | |
changeset 33 | 50974a8b132e |
parent 19 | 989d2f495d90 |
permissions | -rw-r--r-- |
19 | 1 |
/* |
2 |
* Copyright (c) 2002 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 the License "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: ?Description |
|
15 |
* |
|
16 |
*/ |
|
17 |
||
18 |
||
19 |
||
20 |
||
21 |
#ifndef MEDIAMGMT_H |
|
22 |
#define MEDIAMGMT_H |
|
23 |
||
24 |
// INCLUDES |
|
25 |
#include <StifLogger.h> |
|
26 |
#include <TestScripterInternal.h> |
|
27 |
#include <StifTestModule.h> |
|
28 |
#include <liwcommon.h> |
|
29 |
#include <liwserviceifbase.h> |
|
30 |
||
31 |
#include "mgservice.h" |
|
32 |
#include "mgservice.hrh" |
|
33 |
#include "mgoperationobserver.h" |
|
34 |
||
35 |
||
36 |
// CONSTANTS |
|
37 |
//const ?type ?constant_var = ?constant; |
|
38 |
||
39 |
// MACROS |
|
40 |
//#define ?macro ?macro_def |
|
41 |
// Logging path |
|
42 |
_LIT( KMediaMgmtLogPath, "\\logs\\testframework\\MediaMgmt\\" ); |
|
43 |
// Log file |
|
44 |
_LIT( KMediaMgmtLogFile, "MediaMgmt.txt" ); |
|
45 |
_LIT( KResultFile, "Result.txt" ); |
|
46 |
||
47 |
// FUNCTION PROTOTYPES |
|
48 |
//?type ?function_name(?arg_list); |
|
49 |
||
50 |
// FORWARD DECLARATIONS |
|
51 |
//class ?FORWARD_CLASSNAME; |
|
52 |
||
53 |
||
54 |
class CMediaMgmt; |
|
55 |
||
56 |
// DATA TYPES |
|
57 |
//enum ?declaration |
|
58 |
//typedef ?declaration |
|
59 |
//extern ?data_type; |
|
60 |
||
61 |
// CLASS DECLARATION |
|
62 |
||
63 |
/** |
|
64 |
* CMediaMgmt test class for STIF Test Framework TestScripter. |
|
65 |
* ?other_description_lines |
|
66 |
* |
|
67 |
* @lib ?library |
|
68 |
* @since ?Series60_version |
|
69 |
*/ |
|
70 |
NONSHARABLE_CLASS(CMediaMgmt) : public CScriptBase |
|
71 |
{ |
|
72 |
public: // Constructors and destructor |
|
73 |
||
74 |
/** |
|
75 |
* Two-phased constructor. |
|
76 |
*/ |
|
77 |
static CMediaMgmt* NewL( CTestModuleIf& aTestModuleIf ); |
|
78 |
||
79 |
/** |
|
80 |
* Destructor. |
|
81 |
*/ |
|
82 |
virtual ~CMediaMgmt(); |
|
83 |
||
84 |
public: // New functions |
|
85 |
||
86 |
/** |
|
87 |
* ?member_description. |
|
88 |
* @since ?Series60_version |
|
89 |
* @param ?arg1 ?description |
|
90 |
* @return ?description |
|
91 |
*/ |
|
92 |
//?type ?member_function( ?type ?arg1 ); |
|
93 |
||
94 |
public: // Functions from base classes |
|
95 |
||
96 |
/** |
|
97 |
* From CScriptBase Runs a script line. |
|
98 |
* @since ?Series60_version |
|
99 |
* @param aItem Script line containing method name and parameters |
|
100 |
* @return Symbian OS error code |
|
101 |
*/ |
|
102 |
virtual TInt RunMethodL( CStifItemParser& aItem ); |
|
103 |
||
104 |
protected: // New functions |
|
105 |
||
106 |
/** |
|
107 |
* ?member_description. |
|
108 |
* @since ?Series60_version |
|
109 |
* @param ?arg1 ?description |
|
110 |
* @return ?description |
|
111 |
*/ |
|
112 |
//?type ?member_function( ?type ?arg1 ); |
|
113 |
||
114 |
protected: // Functions from base classes |
|
115 |
||
116 |
/** |
|
117 |
* From ?base_class ?member_description |
|
118 |
*/ |
|
119 |
//?type ?member_function(); |
|
120 |
||
121 |
private: |
|
122 |
||
123 |
/** |
|
124 |
* C++ default constructor. |
|
125 |
*/ |
|
126 |
CMediaMgmt( CTestModuleIf& aTestModuleIf ); |
|
127 |
||
128 |
/** |
|
129 |
* By default Symbian 2nd phase constructor is private. |
|
130 |
*/ |
|
131 |
void ConstructL(); |
|
132 |
||
133 |
// Prohibit copy constructor if not deriving from CBase. |
|
134 |
// ?classname( const ?classname& ); |
|
135 |
// Prohibit assigment operator if not deriving from CBase. |
|
136 |
// ?classname& operator=( const ?classname& ); |
|
137 |
||
138 |
/** |
|
139 |
* Frees all resources allocated from test methods. |
|
140 |
* @since ?Series60_version |
|
141 |
*/ |
|
142 |
void Delete(); |
|
143 |
||
144 |
/** |
|
145 |
* Test methods are listed below. |
|
146 |
*/ |
|
147 |
||
148 |
/** |
|
149 |
* Example test method. |
|
150 |
* @since ?Series60_version |
|
151 |
* @param aItem Script line containing parameters. |
|
152 |
* @return Symbian OS error code. |
|
153 |
*/ |
|
154 |
||
155 |
virtual TInt GetFilesL( CStifItemParser& aItem ); |
|
156 |
virtual TInt GetFilesInfoL( CStifItemParser& aItem ); |
|
157 |
||
158 |
||
159 |
public: // Data |
|
160 |
// ?one_line_short_description_of_data |
|
161 |
//?data_declaration; |
|
162 |
||
163 |
protected: // Data |
|
164 |
// ?one_line_short_description_of_data |
|
165 |
//?data_declaration; |
|
166 |
||
167 |
private: // Data |
|
168 |
||
169 |
// ?one_line_short_description_of_data |
|
170 |
//?data_declaration; |
|
171 |
||
172 |
// Reserved pointer for future extension |
|
173 |
//TAny* iReserved; |
|
174 |
||
175 |
public: // Friend classes |
|
176 |
//?friend_class_declaration; |
|
177 |
protected: // Friend classes |
|
178 |
//?friend_class_declaration; |
|
179 |
private: // Friend classes |
|
180 |
//?friend_class_declaration; |
|
181 |
friend TInt GetFilesAsynchL( TAny *aCStifItemParser ); |
|
182 |
||
183 |
}; |
|
184 |
||
185 |
struct ParamPass |
|
186 |
{ |
|
187 |
CStifItemParser* it; |
|
188 |
CStifLogger *log; |
|
189 |
TMgCmdId CmdId ; // 0 for GetFiles and 1 GetFilesInfo |
|
190 |
TInt meta; |
|
191 |
TInt returnCode; |
|
192 |
||
193 |
}; |
|
194 |
||
195 |
class Callback : public MMgOperationObserver |
|
196 |
{ |
|
197 |
struct ParamPass *arg; |
|
198 |
public: |
|
199 |
||
200 |
Callback(ParamPass *aArg):arg(aArg) |
|
201 |
{ |
|
202 |
||
203 |
} |
|
204 |
TInt HandleNotifyL(TInt aCmdId,TInt aEventId,CLiwGenericParamList& aEventParamList,const CLiwGenericParamList& aInParamList); |
|
205 |
virtual void MgNotifyL(TUint aTransactionID, |
|
206 |
MCLFItemListModel* aListModel, |
|
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
207 |
CClfOperationObserver* aOperationObserver, |
19 | 208 |
TMgOperationEvent& aOperationEvent, |
209 |
const TInt& aError ); |
|
210 |
}; |
|
211 |
TInt ThreadFunction (TAny *a); |
|
212 |
TInt GetFilesAsynchL( TAny *ParamPass ); |
|
213 |
||
214 |
#endif // MEDIAMGMT_H |
|
215 |
||
216 |
// End of File |