BlockingCollection<T> Konstruktory

Definice

Inicializuje novou instanci BlockingCollection<T> třídy bez horní hranice.

Přetížení

BlockingCollection<T>()

Inicializuje novou instanci BlockingCollection<T> třídy bez horní hranice.

BlockingCollection<T>(IProducerConsumerCollection<T>)

Inicializuje novou instanci BlockingCollection<T> třídy bez horní hranice a pomocí poskytnuté IProducerConsumerCollection<T> jako její podkladové úložiště dat.

BlockingCollection<T>(Int32)

Inicializuje novou instanci BlockingCollection<T> třídy se zadanou horní mez.

BlockingCollection<T>(IProducerConsumerCollection<T>, Int32)

Inicializuje novou instanci BlockingCollection<T> třídy se zadanou horní mezí a pomocí poskytnutého IProducerConsumerCollection<T> jako podkladového úložiště dat.

BlockingCollection<T>()

Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs

Inicializuje novou instanci BlockingCollection<T> třídy bez horní hranice.

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

Poznámky

Výchozí podkladová kolekce je ConcurrentQueue<T> objekt, který poskytuje chování FIFO (first in, first out).

Viz také

Platí pro

BlockingCollection<T>(IProducerConsumerCollection<T>)

Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs

Inicializuje novou instanci BlockingCollection<T> třídy bez horní hranice a pomocí poskytnuté IProducerConsumerCollection<T> jako její podkladové úložiště dat.

public:
 BlockingCollection(System::Collections::Concurrent::IProducerConsumerCollection<T> ^ collection);
public BlockingCollection (System.Collections.Concurrent.IProducerConsumerCollection<T> collection);
new System.Collections.Concurrent.BlockingCollection<'T> : System.Collections.Concurrent.IProducerConsumerCollection<'T> -> System.Collections.Concurrent.BlockingCollection<'T>
Public Sub New (collection As IProducerConsumerCollection(Of T))

Parametry

collection
IProducerConsumerCollection<T>

Kolekce, která se má použít jako podkladové úložiště dat.

Výjimky

Argument collection je null.

Viz také

Platí pro

BlockingCollection<T>(Int32)

Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs

Inicializuje novou instanci BlockingCollection<T> třídy se zadanou horní mez.

public:
 BlockingCollection(int boundedCapacity);
public BlockingCollection (int boundedCapacity);
new System.Collections.Concurrent.BlockingCollection<'T> : int -> System.Collections.Concurrent.BlockingCollection<'T>
Public Sub New (boundedCapacity As Integer)

Parametry

boundedCapacity
Int32

Ohraničená velikost kolekce.

Výjimky

Hodnota boundedCapacity není kladná hodnota.

Poznámky

Výchozí základní kolekce je ConcurrentQueue<T>.

Viz také

Platí pro

BlockingCollection<T>(IProducerConsumerCollection<T>, Int32)

Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs
Zdroj:
BlockingCollection.cs

Inicializuje novou instanci BlockingCollection<T> třídy se zadanou horní mezí a pomocí poskytnutého IProducerConsumerCollection<T> jako podkladového úložiště dat.

public:
 BlockingCollection(System::Collections::Concurrent::IProducerConsumerCollection<T> ^ collection, int boundedCapacity);
public BlockingCollection (System.Collections.Concurrent.IProducerConsumerCollection<T> collection, int boundedCapacity);
new System.Collections.Concurrent.BlockingCollection<'T> : System.Collections.Concurrent.IProducerConsumerCollection<'T> * int -> System.Collections.Concurrent.BlockingCollection<'T>
Public Sub New (collection As IProducerConsumerCollection(Of T), boundedCapacity As Integer)

Parametry

collection
IProducerConsumerCollection<T>

Kolekce, která se má použít jako podkladové úložiště dat.

boundedCapacity
Int32

Ohraničená velikost kolekce.

Výjimky

Argument collection je null.

Hodnota boundedCapacity není kladná hodnota.

Zadaný objekt collection obsahuje více hodnot, než povoluje boundedCapacity.

Viz také

Platí pro