0
|
1 |
// Copyright (c) 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 |
// Class declaration for CUsbMassStorageController.
|
|
15 |
//
|
|
16 |
//
|
|
17 |
|
|
18 |
|
|
19 |
|
|
20 |
/**
|
|
21 |
@file
|
|
22 |
@internalTechnology
|
|
23 |
*/
|
|
24 |
|
|
25 |
#ifndef CUSBMASSSTORAGECONTROLLER_H
|
|
26 |
#define CUSBMASSSTORAGECONTROLLER_H
|
|
27 |
|
|
28 |
class CDriveManager;
|
|
29 |
class CUsbMassStorageServer;
|
|
30 |
class MServerProtocol;
|
|
31 |
class MDeviceTransport;
|
|
32 |
class TTestParser;
|
|
33 |
|
|
34 |
|
|
35 |
/**
|
|
36 |
Mass Storage Controller class.
|
|
37 |
Encapsulates the drive manager, transport and protocol for USB Mass Storage.
|
|
38 |
Its main purpose is to instantiate and initialize these objects.
|
|
39 |
*/
|
|
40 |
class CUsbMassStorageController : public CBase
|
|
41 |
{
|
|
42 |
public:
|
|
43 |
static CUsbMassStorageController* NewL();
|
|
44 |
~CUsbMassStorageController();
|
|
45 |
private:
|
|
46 |
CUsbMassStorageController();
|
|
47 |
void ConstructL();
|
|
48 |
|
|
49 |
public:
|
|
50 |
void CreateL(const TLunToDriveMap& aDriveMapping);
|
|
51 |
CDriveManager& DriveManager();
|
|
52 |
TInt Start(const TMassStorageConfig& aConfig);
|
|
53 |
TInt Stop();
|
|
54 |
void Reset();
|
|
55 |
|
|
56 |
private:
|
|
57 |
CDriveManager* iDriveManager;
|
|
58 |
MDeviceTransport* iTransport;
|
|
59 |
MServerProtocol* iProtocol;
|
|
60 |
CUsbMassStorageServer* iServer;
|
|
61 |
TMassStorageConfig iConfig;
|
|
62 |
#ifdef MSDC_TESTMODE
|
|
63 |
TTestParser* iTestParser;
|
|
64 |
#endif
|
|
65 |
};
|
|
66 |
|
|
67 |
#endif // CUSBMASSSTORAGECONTROLLER_H
|