class TDesBuf : public TStreamBuf |
A stream buffer that uses a descriptor for its implementation.
A stream of this type is used by RDesWriteStream and RDesReadStream objects. It also has intermediate buffering capabilities.
This is a seekable stream buffer.
When used in write mode, the length of the descriptor is only updated when the stream buffer's SynchL() function is called, i.e. as a result of a call to RWriteStream::CommitL().
RDesWriteStream RDesReadStream RWriteStream::CommitL() MStreamBuf::SynchL()
Public Member Functions | |
---|---|
TDesBuf() | |
IMPORT_C void | Set(TDes8 &, TInt) |
Protected Member Functions | |
---|---|
IMPORT_C TStreamPos | DoSeekL(TMark, TStreamLocation, TInt) |
IMPORT_C void | DoSynchL() |
IMPORT_C void | OverflowL() |
IMPORT_C TInt | UnderflowL(TInt) |
Private Member Functions | |
---|---|
TUint8 * | Base() |
void | Consolidate() |
TDes8 & | Des() |
Inherited Enumerations | |
---|---|
MStreamBuf:TRead | |
MStreamBuf:TWrite |
Private Attributes | |
---|---|
TDes8 * | iDes |
IMPORT_C TStreamPos | DoSeekL | ( | TMark | aMark, |
TStreamLocation | aLocation, | |||
TInt | anOffset | |||
) | [protected, virtual] |
TMark aMark | |
TStreamLocation aLocation | |
TInt anOffset |
IMPORT_C void | DoSynchL | ( | ) | [protected, virtual] |
Synchronises the stream buffer with the stream, leaving if any error occurs.
In effect, this ensures that buffered data is delivered to the stream.
It is called by SynchL().
This implementation is empty, but classes derived from MStreamBuf can provide their own implementation, if necessary.
IMPORT_C void | OverflowL | ( | ) | [protected, virtual] |
Empties the intermediate buffer and resets the start and end points of the write area.
The implementation of this function depends on the way the stream itself is implemented. For example, the in-memory streams have simple implementations.
IMPORT_C void | Set | ( | TDes8 & | aDes, |
TInt | aMode = ERead|EWrite | |||
) |
Sets up the stream to use the specified descriptor.
IMPORT_C TInt | UnderflowL | ( | TInt | aMaxLength | ) | [protected, virtual] |
Re-fills the intermediate buffer and resets the start and end points of the read area.
The implementation of this function depends on the way the stream itself is implemented. For example, the in-memory streams have simple implementations.
TInt aMaxLength | The maximum amount of data required for the intermediate buffer. |
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.