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
    輸入 Iterator 類型。

  • _Al
    搭配這個物件使用的配置器類別。

  • _Vector
    複製或移動項目的來源 concurrent_vector 物件。

  • _N
    concurrent_vector 物件的初始容量。

  • _Item
    建構物件中的項目的值。

  • _Begin
    在要複製的項目的範圍中之第一個項目的位置。

  • _End
    超出要複製的項目的範圍之第一個項目的位置。

備註

所有的建構函式均會存放配置器物件 _Al 並初始化向量。

第一個建構函式指定空的初始向量和明確指定要使用的中繼型別。

第二個和第三個建構函式指定並行向量 _Vector 的複本。

第四個建構函式指定同時向量 _Vector的移動。

第五個建構函式是類別 _Ty指定的指定數目 (_N) 的迴圈預設值的項目。

第六個建構函式指定值 ( _Item) 的_N項目的複本。

最後一個建構函式會指定 Iterator 範圍 [_Begin, _End) 提供的值。

需求

標頭: concurrent_vector.h

命名空間: concurrency

請參閱

參考

concurrent_vector 類別