rtsecuritymanager/rtsecuritymanagerserver/inc/rtsecmgrsubsession.h
changeset 57 61b27eec6533
parent 45 7aa6007702af
equal deleted inserted replaced
45:7aa6007702af 57:61b27eec6533
     1 /*
       
     2 * Copyright (c) 2003-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 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:       Security Manager Server Script Sub-Session Class
       
    15  *
       
    16 */
       
    17 
       
    18 
       
    19 
       
    20 
       
    21 
       
    22 
       
    23 #ifndef C_CRTSECMGRSUBSESSION_H
       
    24 #define C_CRTSECMGRSUBSESSION_H
       
    25 
       
    26 #include "rtsecmgrcommondef.h"
       
    27 #include "rtsecmgrdata.h"
       
    28 #include "rtsecmgrserver.h"
       
    29 
       
    30 class CRTSecMgrSession;
       
    31 
       
    32 /*
       
    33  * Server side script sub-session class
       
    34  * 
       
    35  * @exe rtsecmgrserver.exe
       
    36  * 
       
    37  */
       
    38 class CRTSecMgrSubSession : public CObject
       
    39 	{
       
    40 public:
       
    41 
       
    42 	/**
       
    43 	 * Two-phased constructor
       
    44 	 * 
       
    45 	 * Constructs a CRTSecMgrSubSession instance
       
    46 	 * 
       
    47 	 * @return CRTSecMgrSubSession* pointer to an instance of CRTSecMgrSession
       
    48 	 */
       
    49 	inline static CRTSecMgrSubSession* NewL(CRTSecMgrSession* aSession,
       
    50 			CScript* aScript,CRTSecMgrServer* aSecMgrServer);
       
    51 
       
    52 	/**
       
    53 	 * Destructor
       
    54 	 * 
       
    55 	 */
       
    56 	inline ~CRTSecMgrSubSession();
       
    57 
       
    58 	/**
       
    59 	 * Handles get script file service
       
    60 	 * 
       
    61 	 * @param aMessage const RMessage2& Input message
       
    62 	 * 
       
    63 	 */
       
    64 	void GetScriptFile(const RMessage2& aMessage);
       
    65 
       
    66 	/**
       
    67 	 * Handles update permanent permission service
       
    68 	 * 
       
    69 	 * @param aMessage const RMessage2& Input message
       
    70 	 * 
       
    71 	 */
       
    72 	void UpdatePermGrantL(const RMessage2& aMessage);
       
    73 	
       
    74 	/**
       
    75      * Handles update permanent permission service
       
    76      * 
       
    77      * @param aMessage const RMessage2& Input message
       
    78      * 
       
    79      */
       
    80     void UpdatePermGrantProviderL(const RMessage2& aMessage);
       
    81 
       
    82 	/**
       
    83 	 * Gets script identifier of the underlying script object
       
    84 	 * 
       
    85 	 * @return TExecutableID script identifier of script object
       
    86 	 * 
       
    87 	 */
       
    88 	inline TExecutableID ScriptID() const;
       
    89 
       
    90 	/**
       
    91 	 * Gets the underlying script object
       
    92 	 * 
       
    93 	 * @return const CScript& the script object
       
    94 	 * 
       
    95 	 */
       
    96 	inline const CScript& Script() const;
       
    97 private:
       
    98 
       
    99 	/**
       
   100 	 * Constructor
       
   101 	 * 
       
   102 	 */
       
   103 	inline CRTSecMgrSubSession(CRTSecMgrSession* aSession, CScript* aScript,CRTSecMgrServer* aSecMgrServer);
       
   104 
       
   105 private:
       
   106 
       
   107 	/*
       
   108 	 * 
       
   109 	 * Reference to parent session object
       
   110 	 */
       
   111 	CRTSecMgrSession* iSession; // The session that owns this CRTSecMgrSession object.
       
   112 
       
   113 	/*
       
   114 	 * script identifier
       
   115 	 * 
       
   116 	 */
       
   117 	TExecutableID iScriptID;
       
   118 
       
   119 	/*
       
   120 	 * 
       
   121 	 * pointer to script object
       
   122 	 */
       
   123 	CScript* iScript;
       
   124 	/*
       
   125 	 * Security manager server instance
       
   126 	 * 
       
   127 	 * Stored as member variable for convenient
       
   128 	 * access
       
   129 	 */
       
   130 	CRTSecMgrServer* iSecMgrServer;
       
   131 	};
       
   132 
       
   133 #include "rtsecmgrsubsession.inl"
       
   134 
       
   135 #endif //C_CRTSECMGRSUBSESSION_H
       
   136