Symbian Developer Library

SYMBIAN OS V6.1 EDITION FOR C++

[Index] [Glossary] [Previous] [Next]



Introduction to dynamic buffers

A buffer is an area of memory which may contain data. Managing data in buffers can be more or less complex, depending on the requirements:

EPOC provides flat buffers, objects of type CBufFlat, which are used to allocate and manage storage in a single allocated cell

EPOC provides segmented buffers, objects of type CBufSeg, which are used to allocate and manage storage in several alloc cells.

Both types of buffer have a common base class, CBufBase. This class specifies the main aspects of the programming interface. Having a common base class allows the decision as to whether to use flat or segmented buffers to be changed during program development, with minimal impact on code.