#include <mfcstl/collections/carray_adaptors.hpp>
It is used as follows:
CStringArray ar; mfcstl::CArray_iadaptor<CStringArray> arp(ar); // As an MFC CStringArray: ar.Add("String 1"); ar.InsertAt(0, "String 0"); // As an STL container arp.push_back("String 2"); std::list<CString> l; l.push_back("String 3"); l.push_back("String 4"); arp.insert(arp.begin() + 2, l.begin(), l.end()); std::sort(arp.begin(), arp.end());
A | The array class, e.g. CObArray, CArray<long>, etc. |
Member Types | |
typedef parent_class_type::array_type | array_type |
The type of the underlying MFC array. | |
typedef parent_class_type::value_type | value_type |
The value type. | |
typedef parent_class_type::allocator_type | allocator_type |
The allocator type. | |
typedef parent_class_type::reference | reference |
The mutating (non-const) reference type. | |
typedef parent_class_type::const_reference | const_reference |
The non-mutating (const) reference type. | |
typedef parent_class_type::pointer | pointer |
The mutating (non-const) pointer type. | |
typedef parent_class_type::const_pointer | const_pointer |
The non-mutating (const) pointer type. | |
typedef parent_class_type::iterator | iterator |
The mutating (non-const) iterator type. | |
typedef parent_class_type::const_iterator | const_iterator |
The non-mutating (const) iterator type. | |
typedef parent_class_type::size_type | size_type |
The size type. | |
typedef parent_class_type::difference_type | difference_type |
The difference type. | |
typedef CArray_iadaptor< A, T > | class_type |
The instantiation of the current type. | |
Public Member Functions | |
Construction | |
template<typename A2> | |
CArray_iadaptor (A2 &array) | |
template<typename A2> | |
CArray_iadaptor (A2 *pArray) |
typedef parent_class_type::pointer pointer |
typedef parent_class_type::iterator iterator |
typedef CArray_iadaptor<A, T> class_type |