sysstatemgmt/systemstateplugins/adptplugin/inc/stateadaptationref.h
branchRCL_3
changeset 60 ccb4f6b3db21
parent 0 4e1aa6a622a0
child 61 8cb079868133
equal deleted inserted replaced
56:1ddbe54d0645 60:ccb4f6b3db21
     1 // Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
     1 // Copyright (c) 2007-2010 Nokia Corporation and/or its subsidiary(-ies).
     2 // All rights reserved.
     2 // All rights reserved.
     3 // This component and the accompanying materials are made available
     3 // This component and the accompanying materials are made available
     4 // under the terms of "Eclipse Public License v1.0"
     4 // under the terms of "Eclipse Public License v1.0"
     5 // which accompanies this distribution, and is available
     5 // which accompanies this distribution, and is available
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
     6 // at the URL "http://www.eclipse.org/legal/epl-v10.html".
    25   *********Need for the class*********
    25   *********Need for the class*********
    26   
    26   
    27   On a device when NotifyCoopSysEvent is called, State Adaptation Plug-in would request for notification 
    27   On a device when NotifyCoopSysEvent is called, State Adaptation Plug-in would request for notification 
    28   from the Cooperating System for 'aEvent'.
    28   from the Cooperating System for 'aEvent'.
    29   
    29   
    30   On HRP/Techview,the reference implementation has to complete the notification request with KErrNotSupported
    30   The reference implementation has to complete the notification request with KErrNotSupported.
    31   since there is no Cooperating System on HRP/Techview.
       
    32   
    31   
    33   But this implementation will cause problems in the following scenario.
    32   But this implementation will cause problems in the following scenario.
    34   
    33   
    35   *********Problem*********
    34   *********Problem*********
    36   
    35   
    43   by calling NotifyCoopSysEvent .
    42   by calling NotifyCoopSysEvent .
    44   
    43   
    45   In this context if NotifyCoopSysEvent just completes the message immediately this results in a infinite 
    44   In this context if NotifyCoopSysEvent just completes the message immediately this results in a infinite 
    46   loop and starves other active objects with same priority.
    45   loop and starves other active objects with same priority.
    47   
    46   
    48   This makes testing of Adaptation servers notification functionality impossible on HRP/Techview.
    47   This makes testing of Adaptation servers notification functionality impossible on PlatSim/device.
    49   
    48   
    50   *********Solution*********
    49   *********Solution*********
    51 
    50 
    52   To solve this problem NotifyCoopSysEvent will forward the notification request from adaptation server 
    51   To solve this problem NotifyCoopSysEvent will forward the notification request from adaptation server 
    53   to the test active object(CStateAdaptationRefEventHandler) which has lesser priority compared to 
    52   to the test active object(CStateAdaptationRefEventHandler) which has lesser priority compared to 
    95 	void RequestCoopSysPerformRfsActions(TSsmRfsType aRfsType, TRequestStatus& aStatus);
    94 	void RequestCoopSysPerformRfsActions(TSsmRfsType aRfsType, TRequestStatus& aStatus);
    96 	void RequestCancel();
    95 	void RequestCancel();
    97 
    96 
    98 	void NotifyCoopSysEvent(TDes8& aEvent, TRequestStatus& aStatus);
    97 	void NotifyCoopSysEvent(TDes8& aEvent, TRequestStatus& aStatus);
    99 	void NotifyCancel();
    98 	void NotifyCancel();
   100 
    99 	
   101 private:
   100 private:
   102 	CStateAdaptationRef();
   101 	CStateAdaptationRef();
   103 	void ConstructL();
   102 	void ConstructL();
       
   103 	//Helper function to check for P&S Key
       
   104     TBool IsTestPsKeyDefined();
   104 
   105 
   105 private:
   106 private:
   106 	CStateRefAdaptationTimer* iTimer;	
   107     CStateRefAdaptationTimer* iTimer;
       
   108 	MStateAdaptation* iSaaStateAdaptationDll;
       
   109 	RLibrary iSaaStateAdaptationLib;
   107 	};
   110 	};
   108 
   111 
   109 
   112 
   110 
   113 
   111 
   114