author | Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com> |
Tue, 24 Nov 2009 08:56:33 +0200 | |
changeset 33 | 50974a8b132e |
parent 22 | fc9cf246af83 |
permissions | -rw-r--r-- |
19 | 1 |
/* |
2 |
* Copyright (c) 2002 - 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 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 TEXIMPORT_H |
|
22 |
#define TEXIMPORT_H |
|
23 |
||
24 |
// INCLUDES |
|
25 |
#include <StifLogger.h> |
|
26 |
#include <TestScripterInternal.h> |
|
27 |
#include <StifTestModule.h> |
|
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
28 |
#include <StringLoader.h>//for StringLoaderLC |
19 | 29 |
#include <barsread.h>//resource reader |
30 |
#include <aknnotewrappers.h>//for note |
|
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
31 |
#include <CVPbkVCardEng.h>//for the vcard engin |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
32 |
#include <CVPbkContactManager.h>// for iContactManager |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
33 |
#include <MVPbkContactStore.h>// for iContactStore |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
34 |
#include <TVPbkContactStoreUriPtr.h>//used in SetupL |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
35 |
#include <MVPbkContactStoreList.h>//used in SetupL to get contact stores |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
36 |
#include <MVPbkStoreContactField.h>//used in AddFieldToContactL |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
37 |
#include <MVPbkStoreContact.h>// used in many function to get the store contact |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
38 |
#include <MVPbkContactFieldTextData.h>//for the field text data |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
39 |
#include <TVPbkFieldTypeMapping.h>//used in CreateFieldTypeL() |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
40 |
#include <MVPbkFieldType.h>//return type of CreateFieldTypeL() |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
41 |
#include <MVPbkContactOperationBase.h>//for observer |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
42 |
#include <MVPbkContactFieldDateTimeData.h>//Used in AddDateFieldToContactL |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
43 |
#include <MVPbkContactLink.h>//for param in ContactsSaved() |
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
44 |
#include <CVPbkContactStoreUriArray.h>//used in SetupL |
19 | 45 |
#include "contactservice.h" |
46 |
#include<cntitem.h> |
|
47 |
#include<cntdb.h> |
|
48 |
||
49 |
#include <e32base.h> |
|
50 |
#include <e32cons.h> |
|
51 |
#include<cntfldst.h> |
|
52 |
#include "contactiter.h" |
|
53 |
#include "contactcallback.h" |
|
54 |
#include <MVPbkStoreContact.h> |
|
33
50974a8b132e
Revision: 200945
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
22
diff
changeset
|
55 |
#include <MVPbkFieldType.h> |
19 | 56 |
#include <VPbkEng.rsg> |
57 |
#include <MVPbkStoreContact.h> |
|
58 |
||
59 |
||
60 |
// CONSTANTS |
|
61 |
//const ?type ?constant_var = ?constant; |
|
62 |
||
63 |
// MACROS |
|
64 |
//#define ?macro ?macro_def |
|
65 |
// Logging path |
|
66 |
_LIT( KteximportLogPath, "\\logs\\testframework\\teximport\\" ); |
|
67 |
// Log file |
|
68 |
_LIT( KteximportLogFile, "teximport.txt" ); |
|
69 |
||
70 |
// FUNCTION PROTOTYPES |
|
71 |
//?type ?function_name(?arg_list); |
|
72 |
||
73 |
// FORWARD DECLARATIONS |
|
74 |
//class ?FORWARD_CLASSNAME; |
|
75 |
class Cteximport; |
|
76 |
||
77 |
// DATA TYPES |
|
78 |
//enum ?declaration |
|
79 |
//typedef ?declaration |
|
80 |
//extern ?data_type; |
|
81 |
||
82 |
// CLASS DECLARATION |
|
83 |
||
84 |
/** |
|
85 |
* Cteximport test class for STIF Test Framework TestScripter. |
|
86 |
* ?other_description_lines |
|
87 |
* |
|
88 |
* @lib ?library |
|
89 |
* @since ?Series60_version |
|
90 |
*/ |
|
91 |
||
92 |
class CContactCallback : public MContactCallback |
|
93 |
{ |
|
94 |
public: |
|
95 |
/* |
|
96 |
* |
|
97 |
*/ |
|
98 |
||
99 |
||
100 |
virtual void HandleReturnValue( TOperationEvent aEventId, const TInt& aError, TInt aTransId ); |
|
101 |
||
102 |
virtual void HandleReturnIter( const TInt& aError, CContactIter* aIter, TInt aTransId ); |
|
103 |
||
22
fc9cf246af83
Revision: 200931
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
104 |
virtual void HandleReturnId( const TInt& aError, HBufC8* acntId, TInt aTransId ); |
fc9cf246af83
Revision: 200931
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
105 |
|
fc9cf246af83
Revision: 200931
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
106 |
virtual void HandleReturnArray(const TInt& aError, RPointerArray<HBufC8>& aArray, TInt aTransId ); |
fc9cf246af83
Revision: 200931
Dremov Kirill (Nokia-D-MSW/Tampere) <kirill.dremov@nokia.com>
parents:
19
diff
changeset
|
107 |
|
19 | 108 |
TInt iError; |
109 |
}; |
|
110 |
||
111 |
||
112 |
NONSHARABLE_CLASS(Cteximport) : public CScriptBase |
|
113 |
{ |
|
114 |
public: // Constructors and destructor |
|
115 |
||
116 |
/** |
|
117 |
* Two-phased constructor. |
|
118 |
*/ |
|
119 |
static Cteximport* NewL( CTestModuleIf& aTestModuleIf ); |
|
120 |
||
121 |
/** |
|
122 |
* Destructor. |
|
123 |
*/ |
|
124 |
virtual ~Cteximport(); |
|
125 |
||
126 |
public: // New functions |
|
127 |
||
128 |
/** |
|
129 |
* ?member_description. |
|
130 |
* @since ?Series60_version |
|
131 |
* @param ?arg1 ?description |
|
132 |
* @return ?description |
|
133 |
*/ |
|
134 |
//?type ?member_function( ?type ?arg1 ); |
|
135 |
||
136 |
public: // Functions from base classes |
|
137 |
||
138 |
/** |
|
139 |
* From CScriptBase Runs a script line. |
|
140 |
* @since ?Series60_version |
|
141 |
* @param aItem Script line containing method name and parameters |
|
142 |
* @return Symbian OS error code |
|
143 |
*/ |
|
144 |
virtual TInt RunMethodL( CStifItemParser& aItem ); |
|
145 |
||
146 |
protected: // New functions |
|
147 |
||
148 |
/** |
|
149 |
* ?member_description. |
|
150 |
* @since ?Series60_version |
|
151 |
* @param ?arg1 ?description |
|
152 |
* @return ?description |
|
153 |
*/ |
|
154 |
//?type ?member_function( ?type ?arg1 ); |
|
155 |
||
156 |
protected: // Functions from base classes |
|
157 |
||
158 |
/** |
|
159 |
* From ?base_class ?member_description |
|
160 |
*/ |
|
161 |
//?type ?member_function(); |
|
162 |
||
163 |
private: |
|
164 |
||
165 |
/** |
|
166 |
* C++ default constructor. |
|
167 |
*/ |
|
168 |
Cteximport( CTestModuleIf& aTestModuleIf ); |
|
169 |
||
170 |
/** |
|
171 |
* By default Symbian 2nd phase constructor is private. |
|
172 |
*/ |
|
173 |
void ConstructL(); |
|
174 |
||
175 |
// Prohibit copy constructor if not deriving from CBase. |
|
176 |
// ?classname( const ?classname& ); |
|
177 |
// Prohibit assigment operator if not deriving from CBase. |
|
178 |
// ?classname& operator=( const ?classname& ); |
|
179 |
||
180 |
/** |
|
181 |
* Frees all resources allocated from test methods. |
|
182 |
* @since ?Series60_version |
|
183 |
*/ |
|
184 |
void Delete(); |
|
185 |
||
186 |
/** |
|
187 |
* Test methods are listed below. |
|
188 |
*/ |
|
189 |
||
190 |
/** |
|
191 |
* Example test method. |
|
192 |
* @since ?Series60_version |
|
193 |
* @param aItem Script line containing parameters. |
|
194 |
* @return Symbian OS error code. |
|
195 |
*/ |
|
196 |
||
197 |
virtual TInt Export_Test1L( CStifItemParser& aItem ); |
|
198 |
virtual TInt Export_Test2L( CStifItemParser& aItem ); |
|
199 |
virtual TInt Export_Test3L( CStifItemParser& aItem ); |
|
200 |
virtual TInt Export_Test4L( CStifItemParser& aItem ); |
|
201 |
virtual TInt Export_Test5L( CStifItemParser& aItem ); |
|
202 |
virtual TInt Export_Test6L( CStifItemParser& aItem ); |
|
203 |
virtual TInt Export_Test7L( CStifItemParser& aItem ); |
|
204 |
virtual TInt Export_Test8L( CStifItemParser& aItem ); |
|
205 |
// virtual TInt Export_Test9L( CStifItemParser& aItem ); |
|
206 |
||
207 |
//ADD NEW METHOD DEC HERE |
|
208 |
||
209 |
public: // Data |
|
210 |
// ?one_line_short_description_of_data |
|
211 |
//?data_declaration; |
|
212 |
||
213 |
protected: // Data |
|
214 |
// ?one_line_short_description_of_data |
|
215 |
//?data_declaration; |
|
216 |
||
217 |
private: // Data |
|
218 |
||
219 |
CContactService* icontactservice; |
|
220 |
CContactCallback* icallback; |
|
221 |
// ?one_line_short_description_of_data |
|
222 |
//?data_declaration; |
|
223 |
||
224 |
// Reserved pointer for future extension |
|
225 |
//TAny* iReserved; |
|
226 |
||
227 |
public: // Friend classes |
|
228 |
//?friend_class_declaration; |
|
229 |
protected: // Friend classes |
|
230 |
//?friend_class_declaration; |
|
231 |
private: // Friend classes |
|
232 |
//?friend_class_declaration; |
|
233 |
||
234 |
}; |
|
235 |
||
236 |
#endif // TEXIMPORT_H |
|
237 |
||
238 |
// End of File |