Symbian Developer Library

SYMBIAN OS V6.1 EDITION FOR C++

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



How to expand the array

ExpandL() constructs a new element at position 1 within a CArrayFixFlat<class T> array. In this example, the new element inserted at position 1 is a TElement type object, constructed using the TElement default constructor. It is essential that a default constructor exists before using this function.

CArrayFixFlat<TElement>* fixflat;
fixflat = new (ELeave) CArrayFixFlat<TElement>(8);
...
fixflat->ExpandL(1);

Use ExtendL() to append the newly constructed TElement at the end of the fixflat array.

fixflat->ExtendL();