diff -r 43e37759235e -r 51a74ef9ed63 Symbian3/SDK/Source/GUID-7DDEE87B-7056-5AAA-91A1-33D3D0D50041.dita --- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Symbian3/SDK/Source/GUID-7DDEE87B-7056-5AAA-91A1-33D3D0D50041.dita Wed Mar 31 11:11:55 2010 +0100 @@ -0,0 +1,38 @@ + + + + + +Array +of packed elements, flat arrayDescribes arrays of packed elements in a flat. +

This is a CArrayPakFlat<class T> object whose +elements can have different lengths but are physically contiguous within a +flat array buffer. Each element is preceded by a TInt value +to record the length of that element.

+

A flat buffer always occupies a single cell allocated from the heap and +is always extended by the process of reallocation. A flat array buffer is +implemented using a CBufFlat object.

+

The following diagram illustrates how elements are organised within the +array buffer:

+ + + +

This kind of array is suitable for a small number of objects or for a moderately +large but fixed maximum number of objects. It is not suitable for large arrays +with a high turnover of elements.

+

A packed array has the advantage over a variable flat array in having a +smaller memory overhead for each element. The disadvantage is that the elements +and their preceding TInt values occupy a single cell which +has a higher risk of reallocation failure in times of low memory availability.

+

This class is immediately derived from the abstract template +base class CArrayPak<class T> which is itself derived +from the abstract non-templated base class CArrayPakBase.

+
See also

Using +Dynamic Buffers.

+
\ No newline at end of file