lowlevellibsandfws/pluginfw/Framework/frame/TestHarnessDomainMember.h
changeset 0 e4d67989cc36
equal deleted inserted replaced
-1:000000000000 0:e4d67989cc36
       
     1 // Copyright (c) 2005-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 __TEST_HARNESS_DOMAIN_MEMBER_H__
       
    17 #define __TEST_HARNESS_DOMAIN_MEMBER_H__
       
    18 
       
    19 #include <e32base.h>
       
    20 #include <domainmember.h>
       
    21 /**
       
    22 @internalTechnology
       
    23 
       
    24 Test version of CDmDomain defined in domainmember.h
       
    25 An class for interfacing to a domain managed by 
       
    26 the domain manager or the test harness depending on whether
       
    27 __ECOM_SERVER_TESTABILITY__ macro is defined or not.
       
    28 This class acts either as a dummy intermediate class which 
       
    29 passes all the calls directly to the base class CDmDomain or
       
    30 a class which blocks all the calls to the CDmDomain. The
       
    31 behaviour is defined based on the existence of 
       
    32 KIniEcomTestBehaviourFileName
       
    33 */
       
    34 class CDmDomainTestHarness : public CDmDomain
       
    35 	{
       
    36 public:
       
    37 	CDmDomainTestHarness(TDmHierarchyId aHierarchyId, TDmDomainId aDomainId);
       
    38 	~CDmDomainTestHarness();
       
    39 
       
    40 	void RequestTransitionNotificationL();
       
    41 	void AcknowledgeLastStateL(TInt aError);
       
    42 	TDmDomainState GetState();
       
    43 	void ChangeStartupStateL(TInt aState);
       
    44 	
       
    45 	void ResetRequestTransitionNotificationL();
       
    46 	TBool IsTransitionNotificationRequestedL();
       
    47 	void ResetLastStateAcknowledgedL();
       
    48 	TBool IsLastStateAcknowledgedL();
       
    49 	TBool IsRequestNotificationCancelledL();
       
    50 	void Cancel();
       
    51 protected:
       
    52 	// from CActive
       
    53 	void DoCancel();
       
    54 	void ConstructL();
       
    55 private:
       
    56 	TBool IsTestBehaviour();
       
    57     TBool iIsRequestSent;
       
    58     TBool iIsLastStateAcknowledged;
       
    59 	TInt iState;
       
    60 	TInt iIsTestBehaviour;
       
    61 	TInt iIsBehaviourSet;
       
    62 	TBool iIsRequestCancelled;
       
    63 	};
       
    64 
       
    65 #endif //__TEST_HARNESS_DOMAIN_MEMBER_H__
       
    66