次の方法で共有


concurrent_queue::concurrent_queue コンストラクター

同時実行キューを構築します。

explicit concurrent_queue(
   const allocator_type &_Al = allocator_type()
);

concurrent_queue(
   const concurrent_queue& _OtherQ,
   const allocator_type &_Al = allocator_type()
);

concurrent_queue(
   concurrent_queue&& _OtherQ,
   const allocator_type &_Al = allocator_type()
);

template<
   typename _InputIterator
>
concurrent_queue(
   _InputIterator_Begin,
   _InputIterator_End
);

パラメーター

  • _InputIterator
    値の範囲を指定する入力反復子の型。

  • _Al
    このオブジェクトに対して使用するアロケーター クラス。

  • _OtherQ
    要素のコピー元または移動元の concurrent_queue オブジェクト。

  • _Begin
    コピーする要素範囲内の最初の要素の位置。

  • _End
    コピーする要素範囲を超える最初の要素の位置。

解説

すべてのコンストラクターは、アロケーター オブジェクト _Al を格納し、キューを初期化します。

1 つ目のコンストラクターは、空の初期キューを指定し、使用するアロケーターの型を明示的に指定します。

2 つ目のコンストラクターは、同時実行キュー _OtherQ のコピーを指定します。

3 番目のコンストラクターは、同時実行キュー _OtherQの移動を指定します。

4 番目のコンストラクターは、反復子範囲[_Begin、_End) で指定される値を指定します。

必要条件

ヘッダー: concurrent_queue.h

名前空間: concurrency

参照

関連項目

concurrent_queue クラス