13.1.9.1 Sequence Element Mapping

The operator[] functions are used to access or modify the sequence element. These operators return a reference to the sequence element. The OMG IDL sequence base type is mapped to the appropriate C++ data type.

For basic data types, see the following table. For object references, TypeCode references, and strings, the base type is mapped to a generated _ForSeq_var class. The _ForSeq_var class provides the capability to update a string or an object that is stored within the sequence. This generated class has the same member functions and signatures as the corresponding var class. However, this _ForSeq_var class honors the setting of the release parameter in the sequence constructor. The distinction is that the _ForSeq_var class lets users specify the Release flag, thereby allowing users to control the freeing of memory.

All other data types are mapped as shown in the following table.