usbmgmt/usbmgr/host/functiondrivers/ms/msmm/client/public/msmmclient.h
changeset 0 c9bc50fca66e
equal deleted inserted replaced
-1:000000000000 0:c9bc50fca66e
       
     1 /*
       
     2 * Copyright (c) 2008-2009 Nokia Corporation and/or its subsidiary(-ies).
       
     3 * All rights reserved.
       
     4 * This component and the accompanying materials are made available
       
     5 * under the terms of "Eclipse Public License v1.0"
       
     6 * which accompanies this distribution, and is available
       
     7 * at the URL "http://www.eclipse.org/legal/epl-v10.html".
       
     8 *
       
     9 * Initial Contributors:
       
    10 * Nokia Corporation - initial contribution.
       
    11 *
       
    12 * Contributors:
       
    13 *
       
    14 * Description:
       
    15 *
       
    16 */
       
    17 
       
    18 /**
       
    19  @file
       
    20  @internalComponent
       
    21 */
       
    22 
       
    23 #ifndef MSMMCLIENT_H
       
    24 #define MSMMCLIENT_H
       
    25 
       
    26 #include <e32std.h>
       
    27 #include "msmm_pub_def.h"
       
    28 
       
    29 /**
       
    30 RMsmmSession is the interface for MFDC to use the MSMM.
       
    31 */
       
    32 NONSHARABLE_CLASS(RMsmmSession) : public RSessionBase
       
    33 {
       
    34 public: 
       
    35     //  RMsmmSession Implementaion
       
    36     IMPORT_C TInt Connect();
       
    37     IMPORT_C TInt Disconnect();
       
    38     IMPORT_C TVersion Version() const;
       
    39     
       
    40     /** Add USB Mass Storage Function to the MSMM synchronously.
       
    41     @param aDevice Usb Mass Storage device description.
       
    42     @param aInterfaceNumber The Usb Mass Storage interface number.
       
    43     @param aInterfaceToken The Usb Mass Storage interface token.
       
    44     @return Error code of IPC. 
       
    45     */
       
    46     IMPORT_C TInt AddFunction(const TUSBMSDeviceDescription& aDevice,
       
    47             TUint8 aInterfaceNumber,
       
    48             TUint32 aInterfaceToken);
       
    49 
       
    50     /** Remove USB Mass Storage device from the MSMM synchronously.
       
    51     @param aDevice Usb Mass Storage device description.
       
    52     @return Error code of IPC.
       
    53     */
       
    54     IMPORT_C TInt RemoveDevice(TUint aDevice);
       
    55 
       
    56     // Support for server-side out-of-memory testing. In release, these just
       
    57     // return KErrNone.
       
    58     IMPORT_C TInt __DbgFailNext(TInt aCount);
       
    59     IMPORT_C TInt __DbgAlloc();
       
    60     
       
    61     
       
    62 private:
       
    63     // RMsmmSession data member
       
    64     TPckgBuf<TUSBMSDeviceDescription> iDevicePkg;
       
    65     TUint8 iInterfaceNumber;
       
    66     TUint32 iInterfaceToken;
       
    67 };
       
    68 
       
    69 #endif // MSMMCLIENT_H
       
    70 
       
    71 // End of file