sl@0
|
1 |
// Copyright (c) 2004-2009 Nokia Corporation and/or its subsidiary(-ies).
|
sl@0
|
2 |
// All rights reserved.
|
sl@0
|
3 |
// This component and the accompanying materials are made available
|
sl@0
|
4 |
// under the terms of the License "Eclipse Public License v1.0"
|
sl@0
|
5 |
// which accompanies this distribution, and is available
|
sl@0
|
6 |
// at the URL "http://www.eclipse.org/legal/epl-v10.html".
|
sl@0
|
7 |
//
|
sl@0
|
8 |
// Initial Contributors:
|
sl@0
|
9 |
// Nokia Corporation - initial contribution.
|
sl@0
|
10 |
//
|
sl@0
|
11 |
// Contributors:
|
sl@0
|
12 |
//
|
sl@0
|
13 |
// Description:
|
sl@0
|
14 |
// Class declaration for CMassStorageFileSystem.
|
sl@0
|
15 |
//
|
sl@0
|
16 |
//
|
sl@0
|
17 |
|
sl@0
|
18 |
/**
|
sl@0
|
19 |
@file
|
sl@0
|
20 |
@internalTechnology
|
sl@0
|
21 |
*/
|
sl@0
|
22 |
|
sl@0
|
23 |
#ifndef __CMASSSTORAGEFILESYSTEM_H__
|
sl@0
|
24 |
#define __CMASSSTORAGEFILESYSTEM_H__
|
sl@0
|
25 |
|
sl@0
|
26 |
#include <f32fsys.h>
|
sl@0
|
27 |
#include <f32ver.h>
|
sl@0
|
28 |
#include <f32file.h>
|
sl@0
|
29 |
#include "cusbmassstoragecontroller.h"
|
sl@0
|
30 |
|
sl@0
|
31 |
|
sl@0
|
32 |
/**
|
sl@0
|
33 |
Mass Storage Filesystem class.
|
sl@0
|
34 |
Only supports creating a new mount. Calling NewFileL, NewDirL and NewFormatL
|
sl@0
|
35 |
results in the functions leaving with KErrNotReady.
|
sl@0
|
36 |
When this file system is installed a new thread is created to load the
|
sl@0
|
37 |
Usb Mass Storage controller.
|
sl@0
|
38 |
@internalTechnology
|
sl@0
|
39 |
*/
|
sl@0
|
40 |
class CMassStorageFileSystem : public CFileSystem
|
sl@0
|
41 |
{
|
sl@0
|
42 |
public:
|
sl@0
|
43 |
static CMassStorageFileSystem* NewL();
|
sl@0
|
44 |
~CMassStorageFileSystem();
|
sl@0
|
45 |
|
sl@0
|
46 |
//CFileSystem
|
sl@0
|
47 |
TBool IsExtensionSupported() const;
|
sl@0
|
48 |
TInt Remove();
|
sl@0
|
49 |
TInt Install();
|
sl@0
|
50 |
CMountCB* NewMountL() const;
|
sl@0
|
51 |
CFileCB* NewFileL() const;
|
sl@0
|
52 |
CDirCB* NewDirL() const;
|
sl@0
|
53 |
CFormatCB* NewFormatL() const;
|
sl@0
|
54 |
void DriveInfo(TDriveInfo& anInfo,TInt aDriveNumber) const;
|
sl@0
|
55 |
TInt DefaultPath(TDes& aPath) const;
|
sl@0
|
56 |
TInt DriveList(TDriveList& aList) const;
|
sl@0
|
57 |
|
sl@0
|
58 |
CUsbMassStorageController& Controller();
|
sl@0
|
59 |
TInt InitThread();
|
sl@0
|
60 |
TInt InitThreadL();
|
sl@0
|
61 |
|
sl@0
|
62 |
private:
|
sl@0
|
63 |
CMassStorageFileSystem();
|
sl@0
|
64 |
TInt EnumerateMsDrivesL();
|
sl@0
|
65 |
void ConstructL();
|
sl@0
|
66 |
|
sl@0
|
67 |
public:
|
sl@0
|
68 |
// Public so the mount can see it
|
sl@0
|
69 |
RArray<TBusLocalDrive> iLocalDriveForMediaFlag;
|
sl@0
|
70 |
CArrayFixFlat<TBool> *iMediaChanged;
|
sl@0
|
71 |
TRequestStatus iThreadStat;
|
sl@0
|
72 |
TBool iInstalled;
|
sl@0
|
73 |
|
sl@0
|
74 |
private:
|
sl@0
|
75 |
CUsbMassStorageController* iMassStorageController;
|
sl@0
|
76 |
TBool iRunning;
|
sl@0
|
77 |
RArray<TInt> iMsDrives;
|
sl@0
|
78 |
|
sl@0
|
79 |
|
sl@0
|
80 |
};
|
sl@0
|
81 |
|
sl@0
|
82 |
#endif // __CMASSSTORAGEFILESYSTEM_H__
|
sl@0
|
83 |
|