ConcurrentQueue<T> 构造函数

定义

初始化 ConcurrentQueue<T> 类的新实例。

重载

名称 说明
ConcurrentQueue<T>()

初始化 ConcurrentQueue<T> 类的新实例。

ConcurrentQueue<T>(IEnumerable<T>)

初始化包含从指定集合复制的元素的 ConcurrentQueue<T> 类的新实例。

ConcurrentQueue<T>()

初始化 ConcurrentQueue<T> 类的新实例。

public:
 ConcurrentQueue();
public ConcurrentQueue();
Public Sub New ()

另请参阅

适用于

ConcurrentQueue<T>(IEnumerable<T>)

初始化包含从指定集合复制的元素的 ConcurrentQueue<T> 类的新实例。

public:
 ConcurrentQueue(System::Collections::Generic::IEnumerable<T> ^ collection);
public ConcurrentQueue(System.Collections.Generic.IEnumerable<T> collection);
new System.Collections.Concurrent.ConcurrentQueue<'T> : seq<'T> -> System.Collections.Concurrent.ConcurrentQueue<'T>
Public Sub New (collection As IEnumerable(Of T))

参数

collection
IEnumerable<T>

其元素复制到新 ConcurrentQueue<T>元素的集合。

例外

参数 collection 为 null。

另请参阅

适用于