serviceapifw_plat/rtsecuritymanager_client_api/tsrc/inc/ui_tsecuritymanager.h
changeset 0 99ef825efeca
child 27 bcef26ca2be3
equal deleted inserted replaced
-1:000000000000 0:99ef825efeca
       
     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 
       
    22 
       
    23 
       
    24 
       
    25 
       
    26 #ifndef UI_TSECURITYMANAGER_H
       
    27 #define UI_TSECURITYMANAGER_H
       
    28 
       
    29 //  INCLUDES
       
    30 #include <StifLogger.h>
       
    31 #include <TestScripterInternal.h>
       
    32 #include <StifTestModule.h>
       
    33 
       
    34 #include <e32base.h>
       
    35 #include <e32std.h>
       
    36 #include <f32file.h>
       
    37 #include <RTSecMgrScriptSession.h>
       
    38 #include <rtsecmgrcommondef.h>
       
    39 
       
    40 // Forward reference
       
    41  class CRTSecManager;
       
    42 class CTrustInfo;
       
    43 class RSecMgrSession;
       
    44 class RSecMgrSubSession;
       
    45 // CONSTANTS
       
    46 //const ?type ?constant_var = ?constant;
       
    47 
       
    48 // MACROS
       
    49 //#define ?macro ?macro_def
       
    50 #define TEST_CLASS_VERSION_MAJOR 0
       
    51 #define TEST_CLASS_VERSION_MINOR 0
       
    52 #define TEST_CLASS_VERSION_BUILD 0
       
    53 
       
    54 // Logging path
       
    55 _LIT( Kui_tsecuritymanagerLogPath, "\\logs\\testframework\\ui_tsecuritymanager\\" ); 
       
    56 // Log file
       
    57 _LIT( Kui_tsecuritymanagerLogFile, "ui_tsecuritymanager.txt" ); 
       
    58 _LIT( Kui_tsecuritymanagerLogFileWithTitle, "ui_tsecuritymanager_[%S].txt" );
       
    59 
       
    60 // FUNCTION PROTOTYPES
       
    61 //?type ?function_name(?arg_list);
       
    62 
       
    63 // FORWARD DECLARATIONS
       
    64 //class ?FORWARD_CLASSNAME;
       
    65 class Cui_tsecuritymanager;
       
    66 
       
    67 // DATA TYPES
       
    68 //enum ?declaration
       
    69 //typedef ?declaration
       
    70 //extern ?data_type;
       
    71 
       
    72 // CLASS DECLARATION
       
    73 
       
    74 /**
       
    75 *  Cui_tsecuritymanager test class for STIF Test Framework TestScripter.
       
    76 *  ?other_description_lines
       
    77 *
       
    78 *  @lib ?library
       
    79 *  @since ?Series60_version
       
    80 */
       
    81 NONSHARABLE_CLASS(Cui_tsecuritymanager) : public CScriptBase,public RSessionBase
       
    82     {
       
    83     public:  // Constructors and destructor
       
    84 
       
    85         /**
       
    86         * Two-phased constructor.
       
    87         */
       
    88         static Cui_tsecuritymanager* NewL( CTestModuleIf& aTestModuleIf );
       
    89 
       
    90         /**
       
    91         * Destructor.
       
    92         */
       
    93         virtual ~Cui_tsecuritymanager();
       
    94 
       
    95     public: // New functions
       
    96 	TVersion Version() const;
       
    97         /**
       
    98         * ?member_description.
       
    99         * @since ?Series60_version
       
   100         * @param ?arg1 ?description
       
   101         * @return ?description
       
   102         */
       
   103         //?type ?member_function( ?type ?arg1 );
       
   104 
       
   105     public: // Functions from base classes
       
   106 
       
   107         /**
       
   108         * From CScriptBase Runs a script line.
       
   109         * @since ?Series60_version
       
   110         * @param aItem Script line containing method name and parameters
       
   111         * @return Symbian OS error code
       
   112         */
       
   113         virtual TInt RunMethodL( CStifItemParser& aItem );
       
   114 
       
   115     protected:  // New functions
       
   116 
       
   117         /**
       
   118         * ?member_description.
       
   119         * @since ?Series60_version
       
   120         * @param ?arg1 ?description
       
   121         * @return ?description
       
   122         */
       
   123         //?type ?member_function( ?type ?arg1 );
       
   124 
       
   125     protected:  // Functions from base classes
       
   126 
       
   127         /**
       
   128         * From ?base_class ?member_description
       
   129         */
       
   130         //?type ?member_function();
       
   131 
       
   132     private:
       
   133 
       
   134         /**
       
   135         * C++ default constructor.
       
   136         */
       
   137         Cui_tsecuritymanager( CTestModuleIf& aTestModuleIf );
       
   138 
       
   139         /**
       
   140         * By default Symbian 2nd phase constructor is private.
       
   141         */
       
   142         void ConstructL();
       
   143 
       
   144         // Prohibit copy constructor if not deriving from CBase.
       
   145         // ?classname( const ?classname& );
       
   146         // Prohibit assigment operator if not deriving from CBase.
       
   147         // ?classname& operator=( const ?classname& );
       
   148 
       
   149         /**
       
   150         * Frees all resources allocated from test methods.
       
   151         * @since ?Series60_version
       
   152         */
       
   153         void Delete();
       
   154 
       
   155         /**
       
   156         * Test methods are listed below. 
       
   157         */
       
   158 
       
   159         /**
       
   160         * Example test method.
       
   161         * @since ?Series60_version
       
   162         * @param aItem Script line containing parameters.
       
   163         * @return Symbian OS error code.
       
   164         */
       
   165         virtual TInt serverstart1( CStifItemParser& aItem );
       
   166          virtual TInt serverstart2( CStifItemParser& aItem );
       
   167         virtual TInt secclient1( CStifItemParser& aItem );
       
   168          virtual TInt secclient2( CStifItemParser& aItem );
       
   169    virtual TInt secclient3(CStifItemParser& aItem ); 
       
   170     virtual TInt secclient4(CStifItemParser& aItem );          
       
   171      virtual TInt secclient5(CStifItemParser& aItem );
       
   172        virtual TInt secclient6(CStifItemParser& aItem );
       
   173        virtual TInt secclient7(CStifItemParser& aItem );
       
   174         virtual TInt secclient8(CStifItemParser& aItem );
       
   175          virtual TInt secclient9(CStifItemParser& aItem );
       
   176          virtual TInt secclient10(CStifItemParser& aItem );
       
   177           virtual TInt secclient11(CStifItemParser& aItem );
       
   178           virtual TInt secclient12(CStifItemParser& aItem );
       
   179           virtual TInt secclient13(CStifItemParser& aItem );
       
   180           
       
   181           
       
   182        // void SendTestClassVersion();
       
   183         
       
   184         
       
   185         TInt StartSecManagerServer() const;
       
   186         
       
   187         TFullName ServerLocation() const;
       
   188         TInt ExecuteThreadOne(TAny *aPtr);
       
   189 
       
   190         //ADD NEW METHOD DEC HERE
       
   191         //[TestMethods] - Do not remove
       
   192 
       
   193     public:     // Data
       
   194         // ?one_line_short_description_of_data
       
   195         //?data_declaration;
       
   196 
       
   197     protected:  // Data
       
   198         // ?one_line_short_description_of_data
       
   199         //?data_declaration;
       
   200 
       
   201     private:    // Data
       
   202         
       
   203         // ?one_line_short_description_of_data
       
   204         //?data_declaration;
       
   205 
       
   206         // Reserved pointer for future extension
       
   207         //TAny* iReserved;
       
   208 
       
   209     public:     // Friend classes
       
   210         //?friend_class_declaration;
       
   211     protected:  // Friend classes
       
   212         //?friend_class_declaration;
       
   213     private:    // Friend classes
       
   214         //?friend_class_declaration;
       
   215    CTrustInfo* iTrust;
       
   216     //CLogHandler*      iLogger;
       
   217     CRTSecManager* iSession;
       
   218     CRTSecManager*   iSession2; 
       
   219     CRTSecMgrScriptSession* scriptSession;
       
   220     TInt iPolicyId;
       
   221     
       
   222      RThread iThread1;
       
   223       
       
   224     };
       
   225     
       
   226     
       
   227     const TInt KSecurityServerUid2Int(0x1020507E);
       
   228 const TUid KSecMgrServerUid2 =
       
   229 	{
       
   230 			KSecurityServerUid2Int
       
   231 	};
       
   232 
       
   233 #endif      // UI_TSECURITYMANAGER_H
       
   234 
       
   235 // End of File