uiaccelerator_plat/alf_client_server_api/tsrc/inc/testplatclientserver.h
branchRCL_3
changeset 52 31fccae4f8a7
parent 22 7c5dd702d6d3
equal deleted inserted replaced
51:e5af45d51884 52:31fccae4f8a7
       
     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 "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:  test functions for alf client server api
       
    15 *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 #ifndef C_TESTPLATCLIENTSERVER_H
       
    21 #define C_TESTPLATCLIENTSERVER_H
       
    22 
       
    23 //  INCLUDES
       
    24 #include <stiflogger.h>
       
    25 #include <testscripterinternal.h>
       
    26 #include <stiftestmodule.h>
       
    27 #include <testclassassert.h>
       
    28 
       
    29 // MACROS
       
    30 #define TEST_CLASS_VERSION_MAJOR 0
       
    31 #define TEST_CLASS_VERSION_MINOR 0
       
    32 #define TEST_CLASS_VERSION_BUILD 0
       
    33 
       
    34 class CAlfAppServer;
       
    35 
       
    36 // Logging path
       
    37 _LIT( KtestplatclientserverLogPath, "\\logs\\testframework\\testplatclientserver\\" ); 
       
    38 // Log file
       
    39 _LIT( KtestplatclientserverLogFile, "testplatclientserver.txt" ); 
       
    40 _LIT( KtestplatclientserverLogFileWithTitle, "testplatclientserver_[%S].txt" );
       
    41 
       
    42 /**
       
    43 *  CTestPlatClientServer test class for STIF Test Framework TestScripter.
       
    44 *  @since S60 5.0
       
    45 */
       
    46 NONSHARABLE_CLASS( CTestPlatClientServer ) : public CScriptBase
       
    47     {
       
    48 public:  // Constructors and destructor
       
    49 
       
    50     /**
       
    51     * Two-phased constructor.
       
    52     */
       
    53     static CTestPlatClientServer* NewL( CTestModuleIf& aTestModuleIf );
       
    54 
       
    55     /**
       
    56     * Destructor.
       
    57     */
       
    58     virtual ~CTestPlatClientServer();
       
    59 
       
    60 public: // Functions from base classes
       
    61 
       
    62     /**
       
    63     * From CScriptBase Runs a script line.
       
    64     * @since S60 5.0
       
    65     * @param aItem Script line containing method name and parameters
       
    66     * @return Symbian OS error code
       
    67     */
       
    68     virtual TInt RunMethodL( CStifItemParser& aItem );
       
    69     
       
    70 
       
    71 private:
       
    72 
       
    73     /**
       
    74     * C++ default constructor.
       
    75     */
       
    76     CTestPlatClientServer( CTestModuleIf& aTestModuleIf );
       
    77 
       
    78     /**
       
    79     * By default Symbian 2nd phase constructor is private.
       
    80     */
       
    81     void ConstructL();
       
    82     
       
    83     /**
       
    84      * Method used to log version of test class
       
    85      */
       
    86     void SendTestClassVersion();
       
    87     
       
    88         /**
       
    89      * Turn off ScreenSaver
       
    90      * @since S60 5.0
       
    91      * @return Symbian OS error code.
       
    92      */
       
    93     void TurnOffScreenSaver();
       
    94 
       
    95     /**
       
    96      * Restore ScreenSaver
       
    97      * @since S60 5.0
       
    98      * @return Symbian OS error code.
       
    99      */
       
   100     void RestoreScreenSaver();
       
   101 
       
   102 private: // [TestMethods]
       
   103     
       
   104     //alfappserver.h
       
   105     /**
       
   106     * TestServerNewAppServerL test method in alfappserver.h.
       
   107     * @since S60 5.0
       
   108     * @param aItem no used.
       
   109     * @return Symbian OS error code.
       
   110     */
       
   111     virtual TInt TestServerNewAppServerL( CStifItemParser& /*aItem*/ );
       
   112     
       
   113     /**
       
   114     * TestServerNewAppServerL test method in alfappserver.h.
       
   115     * @since S60 5.0
       
   116     * @param aItem no used.
       
   117     * @return Symbian OS error code.
       
   118     */
       
   119     virtual TInt TestServerHandleClientExitL( CStifItemParser& /*aItem*/ );
       
   120     
       
   121     /**
       
   122     * TestServerAdjustWindowGroupPositionL test method in alfappserver.h.
       
   123     * @since S60 5.0
       
   124     * @param aItem no used.
       
   125     * @return Symbian OS error code.
       
   126     */
       
   127     virtual TInt TestServerAdjustWindowGroupPositionL( CStifItemParser& /*aItem*/ );
       
   128     
       
   129     /**
       
   130     * TestServerWsSessionL test method in alfappserver.h.
       
   131     * @since S60 5.0
       
   132     * @param aItem no used.
       
   133     * @return Symbian OS error code.
       
   134     */
       
   135     virtual TInt TestServerWsSessionL( CStifItemParser& /*aItem*/ );
       
   136     
       
   137     /**
       
   138     * TestServerMetricsInterfaceL test method in alfappserver.h.
       
   139     * @since S60 5.0
       
   140     * @param aItem no used.
       
   141     * @return Symbian OS error code.
       
   142     */
       
   143     virtual TInt TestServerMetricsInterfaceL( CStifItemParser& /*aItem*/ );
       
   144     
       
   145     /**
       
   146     * TestServerMetricsInterfaceConstL test method in alfappserver.h.
       
   147     * @since S60 5.0
       
   148     * @param aItem no used.
       
   149     * @return Symbian OS error code.
       
   150     */
       
   151     virtual TInt TestServerMetricsInterfaceConstL( CStifItemParser& /*aItem*/ );
       
   152     
       
   153     /**
       
   154     * TestServerSetMetricsInterfaceL test method in alfappserver.h.
       
   155     * @since S60 5.0
       
   156     * @param aItem no used.
       
   157     * @return Symbian OS error code.
       
   158     */
       
   159     virtual TInt TestServerSetMetricsInterfaceL( CStifItemParser& /*aItem*/ );
       
   160     
       
   161     /**
       
   162     * TestServerAppUiL test method in alfappserver.h.
       
   163     * @since S60 5.0
       
   164     * @param aItem no used.
       
   165     * @return Symbian OS error code.
       
   166     */
       
   167     virtual TInt TestServerAppUiL( CStifItemParser& /*aItem*/ );
       
   168     
       
   169     //alfappsrvsessionbase.h
       
   170     /**
       
   171     * TestServerCAlfAppSrvSessionBaseServerL test method in alfappsrvsessionbase.h.
       
   172     * @since S60 5.0
       
   173     * @param aItem no used.
       
   174     * @return Symbian OS error code.
       
   175     */
       
   176     virtual TInt TestServerCAlfAppSrvSessionBaseServerL( CStifItemParser& /*aItem*/ );
       
   177     
       
   178     /**
       
   179     * TestServerCAlfAppSrvSessionBaseL test method in alfappsrvsessionbase.h.
       
   180     * @since S60 5.0
       
   181     * @param aItem no used.
       
   182     * @return Symbian OS error code.
       
   183     */
       
   184     virtual TInt TestServerCAlfAppSrvSessionBaseL( CStifItemParser& /*aItem*/ );
       
   185     
       
   186     /**
       
   187     * TestServerClientDrawingAreaL test method in alfappsrvsessionbase.h.
       
   188     * @since S60 5.0
       
   189     * @param aItem no used.
       
   190     * @return Symbian OS error code.
       
   191     */
       
   192     virtual TInt TestServerClientDrawingAreaL( CStifItemParser& /*aItem*/ );
       
   193     
       
   194     /**
       
   195     * TestServerFocusGainedLL test method in alfappsrvsessionbase.h.
       
   196     * @since S60 5.0
       
   197     * @param aItem no used.
       
   198     * @return Symbian OS error code.
       
   199     */
       
   200     virtual TInt TestServerFocusGainedLL( CStifItemParser& /*aItem*/ );
       
   201     
       
   202     /**
       
   203     * TestServerFocusLostL test method in alfappsrvsessionbase.h.
       
   204     * @since S60 5.0
       
   205     * @param aItem no used.
       
   206     * @return Symbian OS error code.
       
   207     */
       
   208     virtual TInt TestServerFocusLostL( CStifItemParser& /*aItem*/ );
       
   209     
       
   210     /**
       
   211     * TestServerPreferredWindowGroupPositionL test method in alfappsrvsessionbase.h.
       
   212     * @since S60 5.0
       
   213     * @param aItem no used.
       
   214     * @return Symbian OS error code.
       
   215     */
       
   216     virtual TInt TestServerPreferredWindowGroupPositionL( CStifItemParser& /*aItem*/ );
       
   217     
       
   218     /**
       
   219     * TestServerAlfServerL test method in alfappsrvsessionbase.h.
       
   220     * @since S60 5.0
       
   221     * @param aItem no used.
       
   222     * @return Symbian OS error code.
       
   223     */
       
   224     virtual TInt TestServerAlfServerL( CStifItemParser& /*aItem*/ );
       
   225     
       
   226     /**
       
   227     * TestServerPreferredRefreshModeL test method in alfappsrvsessionbase.h.
       
   228     * @since S60 5.0
       
   229     * @param aItem no used.
       
   230     * @return Symbian OS error code.
       
   231     */
       
   232     virtual TInt TestServerPreferredRefreshModeL( CStifItemParser& /*aItem*/ );
       
   233     
       
   234     /**
       
   235     * TestServerAlfAppUiL test method in alfappsrvsessionbase.h.
       
   236     * @since S60 5.0
       
   237     * @param aItem no used.
       
   238     * @return Symbian OS error code.
       
   239     */
       
   240     virtual TInt TestServerAlfAppUiL( CStifItemParser& /*aItem*/ );
       
   241     
       
   242     /**
       
   243     * TestServerLayoutManagerL test method in alfappsrvsessionbase.h.
       
   244     * @since S60 5.0
       
   245     * @param aItem no used.
       
   246     * @return Symbian OS error code.
       
   247     */
       
   248     virtual TInt TestServerLayoutManagerL( CStifItemParser& /*aItem*/ );
       
   249     
       
   250     /**
       
   251     * TestServerSharedHuiEnvL test method in alfappsrvsessionbase.h.
       
   252     * @since S60 5.0
       
   253     * @param aItem no used.
       
   254     * @return Symbian OS error code.
       
   255     */
       
   256     virtual TInt TestServerSharedHuiEnvL( CStifItemParser& /*aItem*/ );
       
   257     
       
   258     /**
       
   259     * TestServerHandleCurrentCommanndAsynchL test method in alfappsrvsessionbase.h.
       
   260     * @since S60 5.0
       
   261     * @param aItem no used.
       
   262     * @return Symbian OS error code.
       
   263     */
       
   264     virtual TInt TestServerHandleCurrentCommanndAsynchL( CStifItemParser& /*aItem*/ );
       
   265     
       
   266     /**
       
   267     * TestServerBaseConstructL test method in alfappsrvsessionbase.h.
       
   268     * @since S60 5.0
       
   269     * @param aItem no used.
       
   270     * @return Symbian OS error code.
       
   271     */
       
   272     virtual TInt TestServerBaseConstructL( CStifItemParser& /*aItem*/ );
       
   273     
       
   274     /**
       
   275     * TestServerGetInterfaceLL test method in alfappsrvsessionbase.h.
       
   276     * @since S60 5.0
       
   277     * @param aItem no used.
       
   278     * @return Symbian OS error code.
       
   279     */
       
   280     virtual TInt TestServerGetInterfaceLL( CStifItemParser& /*aItem*/ );
       
   281     
       
   282     /**
       
   283     * TestServerGetHandleFromInterfaceL test method in alfappsrvsessionbase.h.
       
   284     * @since S60 5.0
       
   285     * @param aItem no used.
       
   286     * @return Symbian OS error code.
       
   287     */
       
   288     virtual TInt TestServerGetHandleFromInterfaceL( CStifItemParser& /*aItem*/ );
       
   289     
       
   290     /**
       
   291     * TestServerCompleteCmdL test method in alfappsrvsessionbase.h.
       
   292     * @since S60 5.0
       
   293     * @param aItem no used.
       
   294     * @return Symbian OS error code.
       
   295     */
       
   296     virtual TInt TestServerCompleteCmdL( CStifItemParser& /*aItem*/ );
       
   297     
       
   298     /**
       
   299     * TestServerAlfInterfaceProviderExtensionL test method in alfappsrvsessionbase.h.
       
   300     * @since S60 5.0
       
   301     * @param aItem no used.
       
   302     * @return Symbian OS error code.
       
   303     */
       
   304     virtual TInt TestServerAlfInterfaceProviderExtensionL( CStifItemParser& /*aItem*/ );
       
   305     
       
   306     //alfappui.h
       
   307     /**
       
   308     * TestServerCAlfAppUiL test method in alfappsrvsessionbase.h.
       
   309     * @since S60 5.0
       
   310     * @param aItem no used.
       
   311     * @return Symbian OS error code.
       
   312     */
       
   313     virtual TInt TestServerCAlfAppUiL( CStifItemParser& /*aItem*/ );
       
   314     
       
   315     /**
       
   316     * TestServerContainerL test method in alfappsrvsessionbase.h.
       
   317     * @since S60 5.0
       
   318     * @param aItem no used.
       
   319     * @return Symbian OS error code.
       
   320     */
       
   321     virtual TInt TestServerContainerL( CStifItemParser& /*aItem*/ );
       
   322     
       
   323     /**
       
   324     * TestServerConstructL test method in alfappui.h.
       
   325     * @since S60 5.0
       
   326     * @param aItem no used.
       
   327     * @return Symbian OS error code.
       
   328     */
       
   329     virtual TInt TestServerConstructL( CStifItemParser& /*aItem*/ );
       
   330     
       
   331     /**
       
   332     * TestServerAppendDisplayOnSharedWindowL test method in alfappui.h.
       
   333     * @since S60 5.0
       
   334     * @param aItem no used.
       
   335     * @return Symbian OS error code.
       
   336     */
       
   337     virtual TInt TestServerAppendDisplayOnSharedWindowL( CStifItemParser& /*aItem*/ ); 
       
   338     
       
   339     /**
       
   340     * TestServerHandleSystemEventL test method in alfappui.h.
       
   341     * @since S60 5.0
       
   342     * @param aItem no used.
       
   343     * @return Symbian OS error code.
       
   344     */
       
   345     virtual TInt TestServerHandleSystemEventL( CStifItemParser& /*aItem*/ );
       
   346     
       
   347     /**
       
   348     * TestServerHandleWsEventL test method in alfappui.h.
       
   349     * @since S60 5.0
       
   350     * @param aItem no used.
       
   351     * @return Symbian OS error code.
       
   352     */
       
   353     virtual TInt TestServerHandleWsEventL( CStifItemParser& /*aItem*/ );
       
   354     
       
   355     /**
       
   356     * TestServerFrameworkCallsRendezvousL test method in alfappui.h.
       
   357     * @since S60 5.0
       
   358     * @param aItem no used.
       
   359     * @return Symbian OS error code.
       
   360     */
       
   361     virtual TInt TestServerFrameworkCallsRendezvousL( CStifItemParser& /*aItem*/ );
       
   362     
       
   363     /**
       
   364     * TestServerHandleResourceChangeL test method in alfappui.h.
       
   365     * @since S60 5.0
       
   366     * @param aItem no used.
       
   367     * @return Symbian OS error code.
       
   368     */
       
   369     virtual TInt TestServerHandleResourceChangeL( CStifItemParser& /*aItem*/ );
       
   370     
       
   371     /**
       
   372     * TestServerHandleCommandL test method in alfappui.h.
       
   373     * @since S60 5.0
       
   374     * @param aItem no used.
       
   375     * @return Symbian OS error code.
       
   376     */
       
   377     virtual TInt TestServerHandleCommandL( CStifItemParser& /*aItem*/ ); 
       
   378     
       
   379     //alfclientbase.h
       
   380     /**
       
   381     * TestServerRAlfClientBaseL test method in alfclientbase.h.
       
   382     * @since S60 5.0
       
   383     * @param aItem no used.
       
   384     * @return Symbian OS error code.
       
   385     */
       
   386     virtual TInt TestServerRAlfClientBaseL( CStifItemParser& /*aItem*/ );
       
   387     
       
   388     /**
       
   389     * TestServerOpenL test method in alfclientbase.h.
       
   390     * @since S60 5.0
       
   391     * @param aItem no used.
       
   392     * @return Symbian OS error code.
       
   393     */
       
   394     virtual TInt TestServerOpenL( CStifItemParser& /*aItem*/ );
       
   395     
       
   396     /**
       
   397     * TestServerServiceUidL test method in alfclientbase.h.
       
   398     * @since S60 5.0
       
   399     * @param aItem no used.
       
   400     * @return Symbian OS error code.
       
   401     */
       
   402     virtual TInt TestServerServiceUidL( CStifItemParser& /*aItem*/ );
       
   403     
       
   404     /**
       
   405     * TestServerGrantAccessToPrivateFileL test method in alfclientbase.h.
       
   406     * @since S60 5.0
       
   407     * @param aItem no used.
       
   408     * @return Symbian OS error code.
       
   409     */
       
   410     virtual TInt TestServerGrantAccessToPrivateFileL( CStifItemParser& /*aItem*/ );
       
   411     
       
   412     /**
       
   413     * TestServerGrantAccessToPrivateRFileL test method in alfclientbase.h.
       
   414     * @since S60 5.0
       
   415     * @param aItem no used.
       
   416     * @return Symbian OS error code.
       
   417     */
       
   418     virtual TInt TestServerGrantAccessToPrivateRFileL( CStifItemParser& /*aItem*/ );
       
   419     
       
   420     /**
       
   421     * TestServerConstructServerNameL test method in alfclientbase.h.
       
   422     * @since S60 5.0
       
   423     * @param aItem no used.
       
   424     * @return Symbian OS error code.
       
   425     */
       
   426     virtual TInt TestServerConstructServerNameL( CStifItemParser& /*aItem*/ );
       
   427     
       
   428     /**
       
   429     * TestServerStartServerLL test method in alfclientbase.h.
       
   430     * @since S60 5.0
       
   431     * @param aItem no used.
       
   432     * @return Symbian OS error code.
       
   433     */
       
   434     virtual TInt TestServerStartServerLL( CStifItemParser& /*aItem*/ );
       
   435     
       
   436     /**
       
   437     * TestServerLaunchAppL test method in alfclientbase.h.
       
   438     * @since S60 5.0
       
   439     * @param aItem no used.
       
   440     * @return Symbian OS error code.
       
   441     */
       
   442     virtual TInt TestServerLaunchAppL( CStifItemParser& /*aItem*/ );  
       
   443     
       
   444 private:    // Data
       
   445 
       
   446     /**
       
   447      * ScreenSaver Property
       
   448      */
       
   449     TInt iOldScreenSaverProperty;
       
   450 
       
   451     };
       
   452 
       
   453 #endif      // C_TESTPLATCLIENTSERVER_H
       
   454 
       
   455 // End of File