os/security/authorisation/userpromptservice/test/include/tupsproperty.h
changeset 0 bde4ae8d615e
     1.1 --- /dev/null	Thu Jan 01 00:00:00 1970 +0000
     1.2 +++ b/os/security/authorisation/userpromptservice/test/include/tupsproperty.h	Fri Jun 15 03:10:57 2012 +0200
     1.3 @@ -0,0 +1,88 @@
     1.4 +/*
     1.5 +* Copyright (c) 2007-2009 Nokia Corporation and/or its subsidiary(-ies).
     1.6 +* All rights reserved.
     1.7 +* This component and the accompanying materials are made available
     1.8 +* under the terms of the License "Eclipse Public License v1.0"
     1.9 +* which accompanies this distribution, and is available
    1.10 +* at the URL "http://www.eclipse.org/legal/epl-v10.html".
    1.11 +*
    1.12 +* Initial Contributors:
    1.13 +* Nokia Corporation - initial contribution.
    1.14 +*
    1.15 +* Contributors:
    1.16 +*
    1.17 +* Description: 
    1.18 +*
    1.19 +*/
    1.20 +
    1.21 +
    1.22 +/**
    1.23 + @file  
    1.24 + @test
    1.25 +*/
    1.26 +
    1.27 +#ifndef UPSPROPERTY_H
    1.28 +#define UPSPROPERTY_H
    1.29 +
    1.30 +// interval between instances of either a PE or a DC. This value is added to the indexes below
    1.31 +static const TInt KInstanceInterval = 100;
    1.32 +
    1.33 +// policy evaluator indexes
    1.34 +static const TInt KPe_Start = 0;
    1.35 +static const TInt KPe_Status = 1;
    1.36 +static const TInt KPe_RunningInstance = 2;
    1.37 +static const TInt KPe_ClientSid = 3;
    1.38 +static const TInt KPe_ServerSid = 4;
    1.39 +static const TInt KPe_Leave = 5;
    1.40 +static const TInt KPe_Error = 6;
    1.41 +static const TInt KPe_ServiceId = 7;
    1.42 +static const TInt KPe_ForcePrompt = 8;
    1.43 +static const TInt KPe_EvaluatorInfo = 9;
    1.44 +static const TInt KPe_HoldEvaluatorOpen = 10;
    1.45 +
    1.46 +// dialog creator indexes
    1.47 +static const TInt KDc_Start = 50;
    1.48 +static const TInt KDc_Status = 1;
    1.49 +static const TInt KDc_RunningInstance = 2;
    1.50 +static const TInt KDc_ClientSid = 3;
    1.51 +static const TInt KDc_ServerSid = 4;
    1.52 +static const TInt KDc_Leave = 5;
    1.53 +static const TInt KDc_Error = 6;
    1.54 +static const TInt KDc_ServiceId = 7;
    1.55 +static const TInt KDc_UpsRequestedButtons = 20;
    1.56 +static const TInt KDc_WhichButtonToPress = 21;
    1.57 +static const TInt KDc_HoldPrepareDialogOpen = 22;
    1.58 +static const TInt KDc_HoldDisplayDialogOpen = 23;
    1.59 +static const TInt KDc_SelectFingerprint = 24;
    1.60 +
    1.61 +static const TInt32 KPropertyCreator=0x101F7784; 
    1.62 +static const TUid KPropertyCreatorUid={KPropertyCreator};
    1.63 +
    1.64 +class CUpsProperty : public CBase
    1.65 +	{
    1.66 +public:
    1.67 +	enum TType
    1.68 +	{
    1.69 +		EPolicyEvaluator,
    1.70 +		EDialogCreator
    1.71 +	};
    1.72 +
    1.73 +	static CUpsProperty* NewL(const TUid& aCategory);
    1.74 +	virtual ~CUpsProperty() {};
    1.75 +
    1.76 +	void GetL(TInt aInstanceNumber, TInt aPropertyKey, TType aType, TInt& aValue);
    1.77 +	void GetL(TInt aInstanceNumber, TInt aPropertyKey, TType aType, TDes& aValue);
    1.78 +	void SetL(TInt aInstanceNumber, TInt aPropertyKey, TType aType, TInt aValue);
    1.79 +	void SetL(TInt aInstanceNumber, TInt aPropertyKey, TType aType, TDes& aValue);
    1.80 +
    1.81 +	TInt GetPropertyKey(TInt aPropertyKey, TInt aStart, TInt aInterval, TInt aInstanceNumber);
    1.82 +
    1.83 +protected:
    1.84 +	TUid iCategory;
    1.85 +
    1.86 +private:
    1.87 +	CUpsProperty(const TUid& aCategory);
    1.88 +	};
    1.89 +
    1.90 +
    1.91 +#endif