00001 // Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies). 00002 // All rights reserved. 00003 // This component and the accompanying materials are made available 00004 // under the terms of "Eclipse Public License v1.0" 00005 // which accompanies this distribution, and is available 00006 // at the URL "http://www.eclipse.org/legal/epl-v10.html". 00007 // 00008 // Initial Contributors: 00009 // Nokia Corporation - initial contribution. 00010 // 00011 // Contributors: 00012 // 00013 // Description: 00014 // Defines RSecureSession and RSecureSubSession classes. 00015 // 00016 00017 00018 00022 #ifndef __SECURECLIENT_H__ 00023 #define __SECURECLIENT_H__ 00024 00025 #include <e32base.h> 00026 00034 class RSecureSession : public RSessionBase 00035 { 00036 public: 00037 RSecureSession(); 00038 TInt Connect(); 00039 TVersion Version() const; 00040 TInt ResourceCountL(); 00041 void Close(); 00042 private: 00043 RThread iServerThread; 00044 }; 00045 00052 class RSecureSubSession : public RSubSessionBase 00053 { 00054 public: 00055 TInt Open(RSecureSession& aServer); 00056 TInt SetFromString(const TDesC& aString); 00057 void Close(); 00058 void Increase(); 00059 void Decrease(); 00060 void IncreaseByL(TInt anInt); 00061 void DecreaseByL(TInt anInt); 00062 void Reset(); 00063 TInt CounterValueL(); 00064 void VerifyTransaction(); 00065 void SaveCounterL(); 00066 void SetCounterFromFileL(); 00067 }; 00068 00069 #endif 00070