The Platform::Collections namespace contains the Map, MapView, Vector, and VectorView classes. These classes are concrete implementations of the corresponding interfaces that are defined in the Windows::Foundation::Collections namespace. The concrete collection types are not portable across the ABI (for example when a Javascript or C# program calls into a C++ component), but they are implicitly convertible to their corresponding interface types. For example, if you implement a public method that populates and returns a collection, then use Platform::Collections::Vector to implement the collection internally and use Windows::Foundation::Collections::IVector as the return type. For more information, see Collections and Creating Windows Runtime Components in C++.
You can construct a Platform::Collections::Vector from a std::vector and a Platform::Collections::Map from a std::map.
In addition, the Platform::Collections namespace provides support for back insert and input iterators, and Vector and VectorView iterators.
You must include (#include) the collection.h header to use the types in the Platform::Collections namespace.
#include <collection.h>
using namespace Platform::Collections;This namespace contains the following members.
Metadata: platform.winmd
Namespace: Platform::Collections
Compiler option: /ZW
