concurrent_vector::concurrent_vector 构造函数
构造并发向量。
explicit concurrent_vector(
const allocator_type &_Al = allocator_type()
);
concurrent_vector(
const concurrent_vector& _Vector
);
template<
class M
>
concurrent_vector(
const concurrent_vector<_Ty,
M>& _Vector,
const allocator_type& _Al = allocator_type()
);
concurrent_vector(
concurrent_vector && _Vector
);
explicit concurrent_vector(
size_type _N
);
concurrent_vector(
size_type _N,
const_reference _Item,
const allocator_type& _Al = allocator_type()
);
template<
class _InputIterator
>
concurrent_vector(
_InputIterator_Begin,
_InputIterator_End,
const allocator_type &_Al = allocator_type()
);
参数
M
源向量的分配器类型。_InputIterator
输入迭代器的类型。_Al
要用于此对象的分配器类。_Vector
复制或移动元素的源 concurrent_vector 从对象。_N
concurrent_vector 对象的初始容量。_Item
在构造对象中的元素的值。_Begin
要复制的元素范围中的第一个元素的位置。_End
要复制的元素范围之外的第一个元素的位置。
备注
所有构造函数存储一个分配器对象 _Al 并初始化向量。
第一个构造函数指定空的初始矢量图像和显式指定要使用的分配器类型。
第二个和第三个构造函数指定并发向量 _Vector 的副本。
第四个构造函数指定并发向量 _Vector的移动。
第五个构造函数选件类 _Ty指定数量的连续元素 (_N) 重复的默认值的元素。
第六个构造函数指定 (值 _Item的_N) 元素重复。
最后一个构造函数指定由迭代器范围 [_Begin, _End] 提供的值。
要求
**标头:**concurrent_vector.h
**命名空间:**并发