class CMMFTransferBuffer : public CMMFDataBuffer |
Public Member Functions | |
---|---|
~CMMFTransferBuffer () | |
TUint | BufferSize () |
TDes8 & | Data () |
const TDesC8 & | Data () |
IMPORT_C void | MapOutBuffer () |
IMPORT_C CMMFTransferBuffer * | NewL ( RTransferWindow &, TUint ) |
void | SetPosition ( TUint ) |
void | SetRequestSizeL ( TInt ) |
IMPORT_C RTransferWindow & | TransferWindow () |
IMPORT_C TInt | UpdateTransferWindow ( RTransferWindow &, TUint ) |
Private Member Functions | |
---|---|
CMMFTransferBuffer () | |
void | ConstructL ( RTransferWindow &, TUint ) |
Private Attributes | |
---|---|
TPtr8 | iPtr |
RTransferWindow | iTransferWindow |
TBool | iTransferWindowMappedInOK |
Inherited Attributes | |
---|---|
CMMFBuffer::iFrameNumber | |
CMMFBuffer::iLastBuffer | |
CMMFBuffer::iPosition | |
CMMFBuffer::iRequestSize | |
CMMFBuffer::iStatus | |
CMMFBuffer::iTimeToPlay | |
CMMFBuffer::iType |
IMPORT_C | ~CMMFTransferBuffer | ( | ) |
CMMFTransferBuffer destructor
Destructor maps out RTransferBuffer and closes RTransferWindow .
TUint | BufferSize | ( | ) | const [virtual] |
Returns the actual data size (ie. not the max length) of the data contained in the CMMFTransferBuffer .
void | ConstructL | ( | RTransferWindow & | aTransferWindow, |
TUint | aDataLength | |||
) | [private] |
This method is not supported under EKA2.
Internal ConstructL.
Note this method checks if a transfer buffer has been mapped in and will leave with KErrNotReady if the RTransferWindow does not have a mapped in RTransferBuffer.
RTransferWindow & aTransferWindow | This is a reference to a valid RTransferWindow that has an RTransferBuffer mapped in. |
TUint aDataLength | The length of the data. |
TDes8 & | Data | ( | ) | [virtual] |
Returns a descriptor to the data contained in the CMMFTransferBuffer .
const TDesC8 & | Data | ( | ) | const [virtual] |
Returns a descriptor to the data contained in the CMMFTransferBuffer .
IMPORT_C void | MapOutBuffer | ( | ) |
Maps the buffer out of the transfer window.
This method should be called in preference to calling MapOutBuffer directly on the RtransferWindow so that the CMMFTransferBuffer knows that it is no longer available.
IMPORT_C CMMFTransferBuffer * | NewL | ( | RTransferWindow & | aTransferWindow, |
TUint | aDataLength = 0 | |||
) | [static] |
This function is not supported under EKA2.
Method to instantiate a CMMFTransferBuffer . This NewL creates a CMMFTransferBuffer .
RTransferWindow & aTransferWindow | This is a valid RTransferWindow that has an RTransferBuffer mapped in. |
TUint aDataLength = 0 | This parameter sets the length of the actual data present in the transferbuffer. This is because the length of actual data may be less than the length of the mapped in transfer buffer. |
void | SetPosition | ( | TUint | aPosition | ) | [virtual] |
Sets the position.
This method is used by components (eg codecs) which read data from a buffer and wish to store a read position marker for further reads.
Note: The position cannot exceed the size of the actual data not the max length.
TUint aPosition | The position. |
void | SetRequestSizeL | ( | TInt | aSize | ) | [virtual] |
Sets the request size.
This function is used in cases where a component (eg. a data source) may not be able or be desirable to write to the entire max length of the buffer (eg. variable bit rate codecs). In this case, the SetRequestSizeL can be set which can be read by the RequestSize() function in the component so that it knows to only write data upto the request size and not fill the buffer up to its max length.
TInt aSize | The request size. |
IMPORT_C RTransferWindow & | TransferWindow | ( | ) |
This function is not supported under EKA2.
Returns a reference to the transfer window currently used by the CMMFtransferBuffer.
IMPORT_C TInt | UpdateTransferWindow | ( | RTransferWindow & | aTransferWindow, |
TUint | aDataLength = 0 | |||
) |
This method is not supported under EKA2.
Modifies the CMMFTransferBuffer by updating the RTransferWindow .
This method is used if the same CMMFTransferBuffer is used throughout eg. if a single CMMFTransferBuffer is created upfront but a different transfer window (or the same transfer window with a different buffer mapped in is used). That is the same CMMFTransferBuffer but the actrual buffer may be different.
Note: If the updated RTransferWindow is new, then the old buffer must be mapped out first by a call to CMMFTransferBuffer::MapOutBuffer() and the RtransferWindow handle closed outside the CMMFTransferBuffer .
RTransferWindow & aTransferWindow | The RTransferWindow to update - can be a new RTransferWindow or the same RTransferWindow with a new RTransferBuffer mapped in. |
TUint aDataLength = 0 | The length of the data. |
Copyright ©2010 Nokia Corporation and/or its subsidiary(-ies).
All rights
reserved. Unless otherwise stated, these materials are provided under the terms of the Eclipse Public License
v1.0.