landmarks/locationlandmarks/tsrc/LandmarkTestModule/inc/FT_CPosTp133.h
branchRCL_3
changeset 44 2b4ea9893b66
equal deleted inserted replaced
42:02ba3f1733c6 44:2b4ea9893b66
       
     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 CPOSTP133_H
       
    21 #define CPOSTP133_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include "FT_CLandmarkTestProcedureBase.h"
       
    25 
       
    26 // CLASS DECLARATION
       
    27 class CPosLmMultiDbSearch;
       
    28 /**
       
    29 *  Test procedure 133
       
    30 */
       
    31 class CPosTp133 : public CLandmarkTestProcedureBase, public MProgressObserver
       
    32     {
       
    33     public:  // Constructors and destructor
       
    34         
       
    35         /**
       
    36         * C++ default constructor.
       
    37         */
       
    38        
       
    39          CPosTp133(TInt tpno, CStifLogger* aLog) : CLandmarkTestProcedureBase(tpno, aLog) {iLastNrOfDisplayData=0;iAscendedSorted = ETrue;iErrorsFound=KErrNone;iPartialFlag=EFalse;};
       
    40         /**
       
    41         * Destructor.
       
    42         */
       
    43         ~CPosTp133() {};
       
    44 
       
    45     public: // Functions from base classes
       
    46 
       
    47         
       
    48         /**
       
    49         * From CLandmarkTestProcedureBase
       
    50         * Runs the test in the module
       
    51         */
       
    52         void StartL();
       
    53         
       
    54         void CloseTest();
       
    55         
       
    56         /**
       
    57         * From MProgressObserver
       
    58         * Notifies the progress of the execution of a CPosLmOperation object.
       
    59         *
       
    60         * @param sProgress the progress of the operation
       
    61         */
       
    62         void NotifyProgress(TReal aProgress);
       
    63 
       
    64     private:
       
    65             
       
    66        void DoSearchL(
       
    67             const RPointerArray<CSearchResult>& aSearchResults, CDesCArray* aDbUris, 
       
    68             					TExecutionMode aExecutionMode);
       
    69 
       
    70         void SearchPartialLandmarksL(TInt aWhatIndexToSerrachFor, 
       
    71         							const RPointerArray<CSearchResult>& aSearchResults,
       
    72         							CDesCArray* aDbUris);
       
    73         
       
    74         void CheckPartialErrorCodeL(const TBool aPartial, const TInt aErr);
       
    75         
       
    76         void CheckPartialLandmarkL(const CPosLandmark& aLandmark, 
       
    77                                      const CPosLandmark::TAttributes& aAttr,
       
    78                                      const RArray<TUint>& aReqFields);
       
    79                                      
       
    80         void SearchPartialWithoutNameL(const RPointerArray<CSearchResult>& aSearchResults,
       
    81         							CDesCArray* aDbUris);
       
    82         
       
    83         void CheckResetL(const RPointerArray<CSearchResult>& aSearchResults, CDesCArray* aDbUris);
       
    84         
       
    85         void CancelTestL(const RPointerArray<CSearchResult>& aSearchResults, 
       
    86         				CDesCArray* aDbUris, TBool aCancelInCallback);
       
    87         
       
    88         void LandmarksSortL(RArray<TPosLmItemId>& aArray, const TPosLmSortPref& aSortPref);
       
    89         
       
    90         /**
       
    91         * Execute search operation, add testclass as observer
       
    92         */
       
    93         void ExecuteLmOpL();
       
    94         
       
    95         /**
       
    96         * Execute search operation but cancel in callback, add testclass as observer
       
    97         */
       
    98         void ExecuteLmOpInCallbackL();
       
    99         
       
   100         private:
       
   101         
       
   102         	CPosLmDisplayData* iDisplayData;
       
   103         	TBool iAscendedSorted;
       
   104         	TInt iErrorsFound;
       
   105         	TBool iPartialFlag;
       
   106         	CPosLmMultiDbSearch* iMultiLandmarkSearch;
       
   107         	TInt iLastNrOfDisplayData;
       
   108         	RArray<TPosLmItemId>* iJustNowSearchResults;
       
   109         	
       
   110     };
       
   111 
       
   112 #endif      // CPOSTP133_H
       
   113             
       
   114 // End of File