BlockingCollection<T>.IEnumerable<T>.GetEnumerator Metoda
Definicja
Ważne
Niektóre informacje odnoszą się do produktu w wersji wstępnej, który może zostać znacząco zmodyfikowany przed wydaniem. Firma Microsoft nie udziela żadnych gwarancji, jawnych lub domniemanych, w odniesieniu do informacji podanych w tym miejscu.
Udostępnia element IEnumerator<T> dla elementów w kolekcji.
virtual System::Collections::Generic::IEnumerator<T> ^ System.Collections.Generic.IEnumerable<T>.GetEnumerator() = System::Collections::Generic::IEnumerable<T>::GetEnumerator;
System.Collections.Generic.IEnumerator<T> IEnumerable<T>.GetEnumerator();
abstract member System.Collections.Generic.IEnumerable<T>.GetEnumerator : unit -> System.Collections.Generic.IEnumerator<'T>
override this.System.Collections.Generic.IEnumerable<T>.GetEnumerator : unit -> System.Collections.Generic.IEnumerator<'T>
Function GetEnumerator () As IEnumerator(Of T) Implements IEnumerable(Of T).GetEnumerator
Zwraca
Element IEnumerator<T> dla elementów w kolekcji.
Implementuje
Wyjątki
Element BlockingCollection<T> został usunięty.
Uwagi
W przeciwieństwie do GetConsumingEnumerablemetody zwraca BlockingCollection<T>.IEnumerable<T>.GetEnumerator standardowy moduł wyliczający, który nie modyfikuje bazowej kolekcji. Jeśli inne wątki są dodawane lub usuwane elementy współbieżnie po wywołaniu modułu GetEnumerator, elementy zwrócone przez moduł wyliczający mogą nie reprezentować bieżącego stanu kolekcji.