sysstatemgmt/systemstatemgr/inc/ssmstatemanager.h
changeset 0 4e1aa6a622a0
equal deleted inserted replaced
-1:000000000000 0:4e1aa6a622a0
       
     1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     2 // All rights reserved.
       
     3 // This component and the accompanying materials are made available
       
     4 // under the terms of "Eclipse Public License v1.0"
       
     5 // which accompanies this distribution, and is available
       
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     7 //
       
     8 // Initial Contributors:
       
     9 // Nokia Corporation - initial contribution.
       
    10 //
       
    11 // Contributors:
       
    12 //
       
    13 // Description:
       
    14 //
       
    15 
       
    16 #ifndef __SSMSTATEMANAGER_H__
       
    17 #define __SSMSTATEMANAGER_H__
       
    18 
       
    19 #include <e32std.h>
       
    20 
       
    21 #include <ssm/ssmstatetransition.h>
       
    22 #include <ssm/ssmswp.h>
       
    23 
       
    24 /**
       
    25  RSsmaStateManager is provided as an API used to request changes to the 
       
    26  system state or to request changes to the value of a system-wide property.
       
    27  The policy plug-in associated with the current system state or the requested 
       
    28  system wide property implements the required security policy in 
       
    29  MSsmStatePolicy::TransitionAllowed() or MSsmSwpPolicy::TransitionAllowed().
       
    30  
       
    31  @see MSsmStatePolicy
       
    32  @see MSsmSwpPolicy
       
    33  @publishedPartner
       
    34  @released
       
    35  */
       
    36 NONSHARABLE_CLASS(RSsmStateManager) : public RSessionBase
       
    37 	{
       
    38 public:
       
    39 	IMPORT_C TInt Connect();
       
    40 	IMPORT_C TInt Connect(TInt aAsyncMessageSlotCount);
       
    41 	IMPORT_C void Close();
       
    42 	IMPORT_C TInt RequestStateTransition(TSsmStateTransition aRequest);
       
    43 	IMPORT_C void RequestStateTransition(TSsmStateTransition aRequest, TRequestStatus& aStatus);
       
    44 	IMPORT_C void RequestStateTransitionCancel();
       
    45 	IMPORT_C TInt RequestSwpChange(TSsmSwp aSwp);
       
    46 	IMPORT_C void RequestSwpChange(TSsmSwp aSwp, TRequestStatus& aStatus);
       
    47 	IMPORT_C void RequestSwpChangeCancel();
       
    48 	IMPORT_C TInt RegisterSwpMapping(TUint aSwpKey, const TDesC& aFilename);
       
    49 
       
    50 protected:
       
    51 	TInt DoConnect(const TDesC& aServerName, TVersion aVersion, TInt aAsyncMessageSlots);
       
    52 private:
       
    53 	TVersion Version() const;
       
    54 	};
       
    55 
       
    56 #endif
       
    57 
       
    58 
       
    59