usbclasses/usbphoneasmodem/classimplementation/inc/usbmscfile.h
changeset 35 9d8b04ca6939
child 63 ef2686f7597e
equal deleted inserted replaced
34:7858bc6ead78 35:9d8b04ca6939
       
     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 "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: RUsbMscFile Client side header
       
    14 //              Implements the Symbian OS USB mass storage server RUsbMscFile API 
       
    15 // 
       
    16 
       
    17 #ifndef USBMSCFILE_H
       
    18 #define USBMSCFILE_H
       
    19 
       
    20 #include <e32std.h>
       
    21 #include "usbmscfileshared.h"
       
    22 
       
    23 class RUsbMscFile : public RSessionBase
       
    24 /**
       
    25  The RUsbMscFile class implements the Symbian OS USB mass storage RUsbMscFile API 
       
    26  
       
    27  @internalTechnology
       
    28  */
       
    29 	{
       
    30 public:
       
    31 	/**
       
    32      Constructor
       
    33       
       
    34 	 @internalTechnology
       
    35 	 */
       
    36 	inline RUsbMscFile();
       
    37 
       
    38 	/**
       
    39      Extract the version of the server providing the RUsbMscFile API
       
    40      
       
    41      @return	Version of the server
       
    42      @internalTechnology
       
    43 	 */
       
    44 	inline TVersion Version() const;
       
    45 
       
    46 	/**
       
    47 	 * Setup a logical unit. Maps a file containing a file system image
       
    48 	 * to a logical Mass Storage unit. The parameter aLun is reserved for 
       
    49 	 * future expansion, currently only one unit with LUN = 0 is supported.
       
    50 	 * 
       
    51 	 * @param aFileName path to the file containing the file system image
       
    52 	 * @param aProtocol type of SCSI protocol to use
       
    53 	 * @param aLun logical unit number (LUN) to assign
       
    54      * @return KErrNone on success, otherwise system wide error code 
       
    55 	 */
       
    56 	inline TInt SetupLogicalUnit( const TDesC& aFileName, 
       
    57 	                              const TInt aProtocol, 
       
    58 	                              const TInt aLun = 0 );
       
    59 	/**
       
    60      StartL the mass storage transport service
       
    61      
       
    62 	 @param aMsConfig	mass storage configuration info
       
    63 	 @internalTechnology
       
    64 	 @return KErrNone on success, otherwise system wide error code 
       
    65 	 */
       
    66 	inline TInt Start( const TMassStorageConfig& aMsConfig );
       
    67 
       
    68 	/**
       
    69      Stops mass storage transport service
       
    70      
       
    71 	 @internalTechnology
       
    72 	 @return KErrNone on success, otherwise system wide error code 
       
    73 	 */
       
    74 	inline TInt Stop();
       
    75 	
       
    76 	/**
       
    77      Shut down the Mass Storage server
       
    78      
       
    79 	 @internalTechnology
       
    80 	 @return KErrNone on success, otherwise system wide error code 
       
    81 	 */
       
    82 	inline TInt Shutdown();
       
    83 	
       
    84 	/**
       
    85 	 Connects to mass storage file server
       
    86 	 
       
    87 	 @internalTechnology
       
    88 	 @return KErrNone on success, otherwise system wide error code 
       
    89 	 */
       
    90     inline TInt Connect();
       
    91     
       
    92 	};
       
    93 
       
    94 #include "usbmscfile.inl"
       
    95 
       
    96 #endif //USBMSCFILE_H