os/kernelhwsrv/kerneltest/f32test/plugins/version_2beta/hex/t_hexhook.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
     1 // Copyright (c) 2006-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 the License "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 // f32test\plugins\hexrypt\t_hexhook.h
    15 // 
    16 //
    17 
    18 #if !defined(__T_HEXHOOK_H__)
    19 #define __T_HEXHOOK_H__
    20 
    21 #include <f32plugin.h>
    22 
    23 
    24 /**
    25 The actual implementation of the test hex plugin hook.
    26 It implements all of the pure virtual functions from CTestHexHook.
    27 @internalComponent
    28 */
    29 class CTestHexHook: public CFsPlugin
    30 	{
    31 public:
    32 	static CTestHexHook* NewL();
    33 	~CTestHexHook();
    34 
    35 	virtual void InitialiseL();
    36 	virtual TInt DoRequestL(TFsPluginRequest& aRequest);
    37 
    38 private:
    39 	enum TOperation {EFileOpen, EFileDelete, EFileRename, EFileClose};
    40 
    41 private:
    42 	CTestHexHook();
    43 
    44 	TInt HexFileOpen(TFsPluginRequest& aRequest);
    45 	TInt HexFileRead(TFsPluginRequest& aRequest);
    46 
    47 public:
    48 private:
    49 	TInt HexPluginName(TDes& aName);
    50 	
    51 private:
    52 	TInt iDrvNumber;
    53 	RFs iFs;
    54 	TBuf8<64> iHexBuf;
    55 	TBuf8<32> iBinBuf;
    56 	};
    57 
    58 #endif