Sprache

DbSet<TEntity>.GetAsyncEnumerator(CancellationToken) Methode

Definition

Gibt einen IAsyncEnumerator<T> Wert zurück, der beim Aufzählen asynchron eine Abfrage für die Datenbank ausführt.

public virtual System.Collections.Generic.IAsyncEnumerator<TEntity> GetAsyncEnumerator(System.Threading.CancellationToken cancellationToken = default);
abstract member GetAsyncEnumerator : System.Threading.CancellationToken -> System.Collections.Generic.IAsyncEnumerator<'Entity (requires 'Entity : null)>
override this.GetAsyncEnumerator : System.Threading.CancellationToken -> System.Collections.Generic.IAsyncEnumerator<'Entity (requires 'Entity : null)>
Public Overridable Function GetAsyncEnumerator (Optional cancellationToken As CancellationToken = Nothing) As IAsyncEnumerator(Of TEntity)

Parameter

cancellationToken
CancellationToken

Eine CancellationToken , die zum Abbrechen der asynchronen Iteration verwendet werden kann.

Gibt zurück

IAsyncEnumerator<TEntity>

Die Abfrageergebnisse.

Hinweise

Weitere Informationen und Beispiele finden Sie unter Abfragen von Daten mit EF Core .

Gilt für: