os/kernelhwsrv/baseapitest/basesvs/FileSystemPlugins/inc/T_TestFSY.h
author sl
Tue, 10 Jun 2014 14:32:02 +0200
changeset 1 260cb5ec6c19
permissions -rw-r--r--
Update contrib.
sl@0
     1
/*
sl@0
     2
* Copyright (c) 2005-2009 Nokia Corporation and/or its subsidiary(-ies).
sl@0
     3
* All rights reserved.
sl@0
     4
* This component and the accompanying materials are made available
sl@0
     5
* under the terms of "Eclipse Public License v1.0"
sl@0
     6
* which accompanies this distribution, and is available
sl@0
     7
* at the URL "http://www.eclipse.org/legal/epl-v10.html".
sl@0
     8
*
sl@0
     9
* Initial Contributors:
sl@0
    10
* Nokia Corporation - initial contribution.
sl@0
    11
*
sl@0
    12
* Contributors:
sl@0
    13
*
sl@0
    14
* Description: 
sl@0
    15
*
sl@0
    16
*/
sl@0
    17
sl@0
    18
sl@0
    19
/**
sl@0
    20
@test
sl@0
    21
@internalComponent
sl@0
    22
sl@0
    23
This contains CTestFileSystem
sl@0
    24
*/
sl@0
    25
sl@0
    26
#if (!defined __T_TEST_FSY_H__)
sl@0
    27
#define __T_TEST_FSY_H__
sl@0
    28
sl@0
    29
//	EPOC includes
sl@0
    30
#include <f32fsys.h>
sl@0
    31
sl@0
    32
class CTestMountCB : public CMountCB
sl@0
    33
	{
sl@0
    34
public:
sl@0
    35
	CTestMountCB() {}
sl@0
    36
	~CTestMountCB() {}
sl@0
    37
	virtual void	MountL(TBool /*aForceMount*/) {}
sl@0
    38
	virtual TInt	ReMount() { return KErrNone; }
sl@0
    39
	virtual void	Dismounted() {}
sl@0
    40
	virtual void	VolumeL(TVolumeInfo& /*aVolume*/) const {}
sl@0
    41
	virtual void	SetVolumeL(TDes& /*aName*/) {}
sl@0
    42
	virtual void	MkDirL(const TDesC& /*aName*/) {}
sl@0
    43
	virtual void	RmDirL(const TDesC& /*aName*/) {}
sl@0
    44
	virtual void	DeleteL(const TDesC& /*aName*/) {}
sl@0
    45
	virtual void	RenameL(const TDesC& /*anOldName*/,const TDesC& /*anNewName*/) {}
sl@0
    46
	virtual void	ReplaceL(const TDesC& /*anOldName*/,const TDesC& /*anNewName*/) {}
sl@0
    47
	virtual void	EntryL(const TDesC& /*aName*/,TEntry& /*anEntry*/) const {}
sl@0
    48
	virtual void	SetEntryL(const TDesC& /*aName*/,const TTime& /*aTime*/,TUint /*aSetAttMask*/,TUint /*aClearAttMask*/) {}
sl@0
    49
	virtual void	FileOpenL(const TDesC& /*aName*/,TUint /*aMode*/,TFileOpen /*anOpen*/,CFileCB* /*aFile*/) {}
sl@0
    50
	virtual void	DirOpenL(const TDesC& /*aName*/,CDirCB* /*aDir*/) {}
sl@0
    51
	virtual void	RawReadL(TInt64 /*aPos*/,TInt /*aLength*/,const TAny* /*aTrg*/,TInt /*anOffset*/,const RMessagePtr2& /*aMessage*/) const {}
sl@0
    52
	virtual void	RawWriteL(TInt64 /*aPos*/,TInt /*aLength*/,const TAny* /*aSrc*/,TInt /*anOffset*/,const RMessagePtr2& /*aMessage*/) {}
sl@0
    53
	virtual void	ReadUidL(const TDesC& /*aName*/,TEntry& /*anEntry*/) const {}
sl@0
    54
	virtual void	GetShortNameL(const TDesC& /*aLongName*/,TDes& /*aShortName*/) {}
sl@0
    55
	virtual void	GetLongNameL(const TDesC& /*aShortName*/,TDes& /*aLongName*/) {}
sl@0
    56
	virtual void	IsFileInRom(const TDesC& /*aFileName*/,TUint8*& /*aFileStart*/) {}
sl@0
    57
	virtual void	ReadSectionL(const TDesC& /*aName*/,TInt /*aPos*/,TAny* /*aTrg*/,TInt /*aLength*/,const RMessagePtr2& /*aMessage*/) {}
sl@0
    58
	};
sl@0
    59
sl@0
    60
class CTestFileCB : public CFileCB
sl@0
    61
	{
sl@0
    62
public:
sl@0
    63
	CTestFileCB() {}
sl@0
    64
	~CTestFileCB() {}
sl@0
    65
	virtual void	RenameL(const TDesC& /*aNewName*/) {}
sl@0
    66
	virtual void	ReadL(TInt /*aPos*/,TInt& /*aLength*/,const TAny* /*aDes*/,const RMessagePtr2& /*aMessage*/) {}
sl@0
    67
	virtual void	WriteL(TInt /*aPos*/,TInt& /*aLength*/,const TAny* /*aDes*/,const RMessagePtr2& /*aMessage*/) {}
sl@0
    68
	virtual TInt	Address(TInt& /*aPos*/) const {return 0;}
sl@0
    69
	virtual void	SetSizeL(TInt /*aSize*/) {}
sl@0
    70
	virtual void	SetEntryL(const TTime& /*aTime*/,TUint /*aSetAttMask*/,TUint /*aClearAttMask*/) {}
sl@0
    71
	virtual void	FlushDataL() {}
sl@0
    72
	virtual void	FlushAllL() {}
sl@0
    73
	virtual void	CheckPos(TInt /*aPos*/) {}
sl@0
    74
	};
sl@0
    75
sl@0
    76
class CTestDirCB : public CDirCB
sl@0
    77
	{
sl@0
    78
public:
sl@0
    79
	CTestDirCB() {}
sl@0
    80
	~CTestDirCB() {}
sl@0
    81
	virtual void	ReadL(TEntry& /*anEntry*/) {}
sl@0
    82
	};
sl@0
    83
sl@0
    84
class CTestFormatCB : public CFormatCB
sl@0
    85
	{
sl@0
    86
public:
sl@0
    87
	CTestFormatCB() {}
sl@0
    88
	~CTestFormatCB() {}
sl@0
    89
	virtual void	DoFormatStepL() {}
sl@0
    90
	};
sl@0
    91
sl@0
    92
class CTestFileSystem : public CFileSystem
sl@0
    93
	{
sl@0
    94
public:
sl@0
    95
	TInt			DefaultPath(TDes& aPath) const;
sl@0
    96
	void			DriveInfo(TDriveInfo& anInfo, TInt aDriveNumber) const;
sl@0
    97
	TBusLocalDrive&	DriveNumberToLocalDrive(TInt aDriveNumber) const;
sl@0
    98
	CMountCB*		NewMountL() const;
sl@0
    99
	CFileCB*		NewFileL() const;
sl@0
   100
	CDirCB*			NewDirL() const;
sl@0
   101
	CFormatCB*		NewFormatL() const;
sl@0
   102
 
sl@0
   103
protected:
sl@0
   104
	CTestFileSystem();
sl@0
   105
	};
sl@0
   106
sl@0
   107
#endif /* __T_TEST_FSY_H__ */