|
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 * ?description_line |
|
16 * |
|
17 */ |
|
18 |
|
19 |
|
20 #ifndef CPOSTp125_H |
|
21 #define CPOSTp125_H |
|
22 |
|
23 // INCLUDES |
|
24 #include "FT_CLandmarkTestProcedureBase.h" |
|
25 #include <EPos_CPosLMCategoryManager.h> |
|
26 #include <EPos_CPosLmMultiDbSearch.h> |
|
27 //#include <EPos_CPosLmMultiDbSearchOperation.h> |
|
28 |
|
29 // CLASS DECLARATION |
|
30 |
|
31 /** |
|
32 * Test procedure 125 |
|
33 */ |
|
34 class CPosTp125 : public CLandmarkTestProcedureBase |
|
35 { |
|
36 public: // Constructors and destructor |
|
37 |
|
38 /** |
|
39 * C++ default constructor. |
|
40 */ |
|
41 |
|
42 CPosTp125(TInt tpno, CStifLogger* aLog) : CLandmarkTestProcedureBase(tpno, aLog) {}; |
|
43 /** |
|
44 * Destructor. |
|
45 */ |
|
46 ~CPosTp125() {delete iLandmarksMultiDbSearch; |
|
47 delete iDbArray;}; |
|
48 |
|
49 public: // Functions from base classes |
|
50 |
|
51 void CloseTest(); |
|
52 |
|
53 /** |
|
54 * From CLandmarkTestProcedureBase |
|
55 * Runs the test in the module |
|
56 */ |
|
57 void StartL(); |
|
58 |
|
59 private: |
|
60 |
|
61 void SearchL( |
|
62 const RPointerArray<CCategorySearchResult>& aSearchResults, |
|
63 TExecutionMode aExecutionMode); |
|
64 |
|
65 void SearchWithMaximumL( |
|
66 const RPointerArray<CCategorySearchResult>& aSearchResults, |
|
67 TExecutionMode aExecutionMode); |
|
68 |
|
69 void SearchWithSortOrderL( |
|
70 const RPointerArray<CCategorySearchResult>& aSearchResults, |
|
71 TExecutionMode aExecutionMode); |
|
72 |
|
73 void SearchAfterAddedCategoryL(); |
|
74 |
|
75 void SearchAndCancelL(const TBool& aInCallback=EFalse); |
|
76 |
|
77 /** |
|
78 * Include the global categories when searching |
|
79 */ |
|
80 void SearchGlobalL(const RPointerArray<CCategorySearchResult>& aSearchResults, const TBool& aSync=EFalse); |
|
81 |
|
82 /** |
|
83 * All categories are included in all databases. Remove so there are no duplicates. |
|
84 */ |
|
85 void RemoveExtraCategoriesL(); |
|
86 |
|
87 void RemoveCategoryL(CPosLmCategoryManager* aCatMan, |
|
88 TPosLmItemId aCatId); |
|
89 |
|
90 |
|
91 void AssertThatIdIsInCorrectDbL(TInt aDbIndex, TInt aId); |
|
92 |
|
93 void SetupDbArrayL(); |
|
94 |
|
95 void SortResultsL(RArray<TPosLmItemId>& aArray, |
|
96 CDesCArrayFlat*& aResultArray); |
|
97 |
|
98 void InvertArrayL(CDesCArrayFlat*& aArray); |
|
99 |
|
100 void TestDuplicateGlobalCategoriesL(const RPointerArray<CCategorySearchResult>& aSearchResults, const TBool& aSync=EFalse); |
|
101 |
|
102 // data members |
|
103 private: |
|
104 |
|
105 CDesCArrayFlat* iDbArray; |
|
106 CPosLmMultiDbSearch* iLandmarksMultiDbSearch; |
|
107 |
|
108 }; |
|
109 |
|
110 #endif // CPOSTp125_H |
|
111 |
|
112 // End of File |