speechsrv_plat/ui_voice_recognition_api/tsrc/inc/testdomuivoicerengn.h
branchRCL_3
changeset 23 e36f3802f733
parent 0 bf1d17376201
equal deleted inserted replaced
22:cad71a31b7fc 23:e36f3802f733
       
     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 "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:  For test ui voice recognition api modules
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef C_TESTDOMUIVOICERENGN_H
       
    21 #define C_TESTDOMUIVOICERENGN_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include <stiflogger.h>
       
    25 #include <testscripterinternal.h>
       
    26 #include <stiftestmodule.h>
       
    27 #include <testclassassert.h>
       
    28 #include <vuicvoicerecog.h>
       
    29 #include <vuicvoicerecogdialog.h>
       
    30 
       
    31 // MACROS
       
    32 #define TEST_CLASS_VERSION_MAJOR 0
       
    33 #define TEST_CLASS_VERSION_MINOR 0
       
    34 #define TEST_CLASS_VERSION_BUILD 0
       
    35 
       
    36 // Logging path
       
    37 _LIT( KtestdomuivoicerengnLogPath, "\\logs\\testframework\\testdomuivoicerengn\\" ); 
       
    38 // Log file
       
    39 _LIT( KtestdomuivoicerengnLogFile, "testdomuivoicerengn.txt" ); 
       
    40 _LIT( KtestdomuivoicerengnLogFileWithTitle, "testdomuivoicerengn_[%S].txt" );
       
    41 
       
    42 class CVoiceRecog;
       
    43 class CVoiceRecognitionDialog;
       
    44 
       
    45 /**
       
    46 *  CTestDOMUiVoiceRengn test class for STIF Test Framework TestScripter.
       
    47 *  @since S60 5.0
       
    48 */
       
    49 NONSHARABLE_CLASS( CTestDOMUiVoiceRengn ) : public CScriptBase
       
    50     {
       
    51 public:  // Constructors and destructor
       
    52 
       
    53     /**
       
    54     * Two-phased constructor.
       
    55     */
       
    56     static CTestDOMUiVoiceRengn* NewL( CTestModuleIf& aTestModuleIf );
       
    57 
       
    58     /**
       
    59     * Destructor.
       
    60     */
       
    61     virtual ~CTestDOMUiVoiceRengn();
       
    62 
       
    63 public: // Functions from base classes
       
    64 
       
    65     /**
       
    66     * From CScriptBase Runs a script line.
       
    67     * @since S60 5.0
       
    68     * @param aItem Script line containing method name and parameters
       
    69     * @return Symbian OS error code
       
    70     */
       
    71     virtual TInt RunMethodL( CStifItemParser& aItem );
       
    72 
       
    73 private:
       
    74 
       
    75     /**
       
    76     * C++ default constructor.
       
    77     */
       
    78     CTestDOMUiVoiceRengn( CTestModuleIf& aTestModuleIf );
       
    79 
       
    80     /**
       
    81     * By default Symbian 2nd phase constructor is private.
       
    82     */
       
    83     void ConstructL();
       
    84     
       
    85     /**
       
    86      * Method used to log version of test class
       
    87      */
       
    88     void SendTestClassVersion();
       
    89     
       
    90         /**
       
    91      * Turn off ScreenSaver
       
    92      * @since S60 5.0
       
    93      * @return Symbian OS error code.
       
    94      */
       
    95     void TurnOffScreenSaver();
       
    96 
       
    97     /**
       
    98      * Restore ScreenSaver
       
    99      * @since S60 5.0
       
   100      * @return Symbian OS error code.
       
   101      */
       
   102     void RestoreScreenSaver();
       
   103 
       
   104 	// [TestMethods]
       
   105 private:// for testing the vuicvoicerecog.h
       
   106 	
       
   107     /**
       
   108     * TestVuicVocRecogNewL test method for testing the NewL method
       
   109     * @since S60 5.0
       
   110     * @param aItem Script line containing parameters.
       
   111     * @return Symbian OS error code.
       
   112     */
       
   113     virtual TInt TestVuicVocRecogNewL( CStifItemParser& aItem );
       
   114     
       
   115     /**
       
   116     * TestVuicVocRecogNewLC test method for testing the NewLC method
       
   117     * @since S60 5.0
       
   118     * @param aItem Script line containing parameters.
       
   119     * @return Symbian OS error code.
       
   120     */
       
   121     virtual TInt TestVuicVocRecogNewLCL( CStifItemParser& aItem );
       
   122     
       
   123     // for testing the vuicvoicerecogdialog.h
       
   124     /**
       
   125     * TestVoceRegDalgCVoceRegDialogL test method for testing the CVoiceRecognitionDialog method
       
   126     * @since S60 5.0
       
   127     * @param aItem Script line containing parameters.
       
   128     * @return Symbian OS error code.
       
   129     */
       
   130     virtual TInt TestVoceRegDalgCVoceRegDialogL( CStifItemParser& aItem );
       
   131     
       
   132     /**
       
   133     * TestVoceRegDalgDestructor test method for testing the ~CVoiceRecognitionDialog method
       
   134     * @since S60 5.0
       
   135     * @param aItem Script line containing parameters.
       
   136     * @return Symbian OS error code.
       
   137     */
       
   138     virtual TInt TestVoceRegDalgDestructor( CStifItemParser& aItem );
       
   139     /**
       
   140     * TestVoceRegDalgExecuteLD test method for testing the ExecuteLD method
       
   141     * @since S60 5.0
       
   142     * @param aItem Script line containing parameters.
       
   143     * @return Symbian OS error code.
       
   144     */
       
   145     virtual TInt TestVoceRegDalgExecuteLDL( CStifItemParser& aItem );
       
   146     /**
       
   147     * TestVoceRegDalgCancel test method for testing the Cancel method
       
   148     * @since S60 5.0
       
   149     * @param aItem Script line containing parameters.
       
   150     * @return Symbian OS error code.
       
   151     */
       
   152     virtual TInt TestVoceRegDalgCancel( CStifItemParser& aItem );
       
   153 private:    // Data
       
   154 
       
   155     /**
       
   156      * ScreenSaver Property
       
   157      */
       
   158     TInt iOldScreenSaverProperty;
       
   159 
       
   160     /**
       
   161      * Own Member
       
   162      *
       
   163      */
       
   164     CVoiceRecog* iVoiceRecog;
       
   165     /**
       
   166      * Own Member
       
   167      *
       
   168      */
       
   169     CVoiceRecognitionDialog* iVoiceRecogDialog;
       
   170 
       
   171     };
       
   172 
       
   173 #endif      // C_TESTDOMUIVOICERENGN_H
       
   174 
       
   175 // End of File