os/kernelhwsrv/userlibandfileserver/fileserver/shostmassstorage/server/protocol/include/mblocktransferprotocol.h
Update contrib.
1 // Copyright (c) 2008-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".
8 // Initial Contributors:
9 // Nokia Corporation - initial contribution.
14 // BOT Protocol layer for USB Mass Storage Class
23 #ifndef MBLOCKTRANSFERPROTOCOL_H
24 #define MBLOCKTRANSFERPROTOCOL_H
27 Interface class to be provided by the Protocol layer. The interface methods are
28 used by TBlockTransfer class which manages block read and block writes of the
29 data to be transferred.
31 class MBlockTransferProtocol
35 Read a block of data aligned to block boundary.
37 @param aPos The position aligned to block boundary
38 @param aBuf The buffer to copy the data into
39 @param aLength The Length in bytes, a multiple of the block length
41 virtual void BlockReadL(TUint64 aPos, TDes8& aBuf, TInt aLength) = 0;
44 Write a block of data aligned to block boundary.
46 @param aPos The position aligned to block boundary
47 @param aBuf The buffer containing the data to write
48 @param aOffset The offset into the buffer to the start of the block
49 @param aLength The length in bytes, must be a multiple of the block length
51 virtual void BlockWriteL(TUint64 aPos, TDesC8& aBuf, TUint aOffset, TInt aLength) = 0;
54 #endif // MBLOCKTRANSFERPROTOCOL_H