00001 // 00002 // Copyright (c) 2009 Nokia Corporation and/or its subsidiary(-ies). 00003 // All rights reserved. 00004 // This component and the accompanying materials are made available 00005 // under the terms of "Eclipse Public License v1.0" 00006 // which accompanies this distribution, and is available 00007 // at the URL "http://www.eclipse.org/legal/epl-v10.html". 00008 // 00009 // Initial Contributors: 00010 // Nokia Corporation - initial contribution. 00011 // 00012 // Contributors: 00013 // 00014 // Description: A dummy restore state policy is provided to demonstrate the 00015 // system state manager framework. 00016 // 00017 00018 #ifndef __DUMMY_RESTORE_STATEPOLICY_H__ 00019 #define __DUMMY_RESTORE_STATEPOLICY_H__ 00020 00021 #include <e32base.h> 00022 #include <ssm/ssmstatepolicy.h> 00023 #include <ssm/ssmstate.h> 00024 00030 NONSHARABLE_CLASS(CSsmDummyRestoreStatePolicy) : public CBase, public MSsmStatePolicy 00031 { 00032 public: 00033 IMPORT_C static MSsmStatePolicy* NewL(); 00034 00035 //from MSsmStatePolicy 00036 void Initialize(TRequestStatus& aStatus); 00037 void InitializeCancel(); 00038 void Release(); 00039 TResponse TransitionAllowed(const TSsmStateTransition& aRequest, TSsmStateTransition const* aCurrent, TSsmStateTransition const* aQueued, const RMessagePtr2& aMessage); 00040 void PrepareCommandList(TSsmState aState, TInt aReason, TRequestStatus& aStatus); 00041 void doPrepareCommandListL(TSsmState aState); 00042 void PrepareCommandListCancel(); 00043 CSsmCommandList* CommandList(); 00044 TBool GetNextState(TSsmState aCurrentTransition, TInt aReason, TInt aError, TInt aSeverity, TSsmState& aNextState); 00045 00046 private: 00047 //from CBase 00048 CSsmDummyRestoreStatePolicy(); 00049 ~CSsmDummyRestoreStatePolicy(); 00050 00051 private: 00052 CSsmCommandList* iCommandList; 00053 }; 00054 00055 #endif //__DUMMY_RESTORE_STATEPOLICY_H__
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.