HttpContentJsonExtensions.ReadFromJsonAsAsyncEnumerable Méthode

Définition

Surcharges

ReadFromJsonAsAsyncEnumerable<TValue>(HttpContent, CancellationToken)

Lit le contenu HTTP et retourne la valeur qui résulte de la désérialisation du contenu au format JSON dans une opération énumérable asynchrone.

ReadFromJsonAsAsyncEnumerable<TValue>(HttpContent, JsonSerializerOptions, CancellationToken)

Lit le contenu HTTP et retourne la valeur qui résulte de la désérialisation du contenu au format JSON dans une opération énumérable asynchrone.

ReadFromJsonAsAsyncEnumerable<TValue>(HttpContent, JsonTypeInfo<TValue>, CancellationToken)

Lit le contenu HTTP et retourne la valeur qui résulte de la désérialisation du contenu au format JSON dans une opération énumérable asynchrone.

ReadFromJsonAsAsyncEnumerable<TValue>(HttpContent, CancellationToken)

Source:
HttpContentJsonExtensions.AsyncEnumerable.cs
Source:
HttpContentJsonExtensions.AsyncEnumerable.cs

Lit le contenu HTTP et retourne la valeur qui résulte de la désérialisation du contenu au format JSON dans une opération énumérable asynchrone.

public static System.Collections.Generic.IAsyncEnumerable<TValue?> ReadFromJsonAsAsyncEnumerable<TValue> (this System.Net.Http.HttpContent content, System.Threading.CancellationToken cancellationToken = default);
static member ReadFromJsonAsAsyncEnumerable : System.Net.Http.HttpContent * System.Threading.CancellationToken -> System.Collections.Generic.IAsyncEnumerable<'Value>
<Extension()>
Public Function ReadFromJsonAsAsyncEnumerable(Of TValue) (content As HttpContent, Optional cancellationToken As CancellationToken = Nothing) As IAsyncEnumerable(Of TValue)

Paramètres de type

TValue

Type cible vers lequel désérialiser.

Paramètres

content
HttpContent
cancellationToken
CancellationToken

Retours

IAsyncEnumerable<T> qui représente le corps de la réponse désérialisée.

Exceptions

Le content est null.

Le jeton d’annulation a été annulé. Cette exception est stockée dans la tâche retournée.

S’applique à

ReadFromJsonAsAsyncEnumerable<TValue>(HttpContent, JsonSerializerOptions, CancellationToken)

Source:
HttpContentJsonExtensions.AsyncEnumerable.cs
Source:
HttpContentJsonExtensions.AsyncEnumerable.cs

Lit le contenu HTTP et retourne la valeur qui résulte de la désérialisation du contenu au format JSON dans une opération énumérable asynchrone.

public static System.Collections.Generic.IAsyncEnumerable<TValue?> ReadFromJsonAsAsyncEnumerable<TValue> (this System.Net.Http.HttpContent content, System.Text.Json.JsonSerializerOptions? options, System.Threading.CancellationToken cancellationToken = default);
static member ReadFromJsonAsAsyncEnumerable : System.Net.Http.HttpContent * System.Text.Json.JsonSerializerOptions * System.Threading.CancellationToken -> System.Collections.Generic.IAsyncEnumerable<'Value>
<Extension()>
Public Function ReadFromJsonAsAsyncEnumerable(Of TValue) (content As HttpContent, options As JsonSerializerOptions, Optional cancellationToken As CancellationToken = Nothing) As IAsyncEnumerable(Of TValue)

Paramètres de type

TValue

Type cible vers lequel désérialiser.

Paramètres

content
HttpContent

Contenu à partir duquel lire.

options
JsonSerializerOptions

Options permettant de contrôler le comportement lors de la désérialisation. Les options par défaut sont celles spécifiées par Web.

cancellationToken
CancellationToken

Retours

IAsyncEnumerable<T> qui représente le corps de la réponse désérialisée.

Exceptions

Le content est null.

Le jeton d’annulation a été annulé. Cette exception est stockée dans la tâche retournée.

S’applique à

ReadFromJsonAsAsyncEnumerable<TValue>(HttpContent, JsonTypeInfo<TValue>, CancellationToken)

Source:
HttpContentJsonExtensions.AsyncEnumerable.cs
Source:
HttpContentJsonExtensions.AsyncEnumerable.cs

Lit le contenu HTTP et retourne la valeur qui résulte de la désérialisation du contenu au format JSON dans une opération énumérable asynchrone.

public static System.Collections.Generic.IAsyncEnumerable<TValue?> ReadFromJsonAsAsyncEnumerable<TValue> (this System.Net.Http.HttpContent content, System.Text.Json.Serialization.Metadata.JsonTypeInfo<TValue> jsonTypeInfo, System.Threading.CancellationToken cancellationToken = default);
static member ReadFromJsonAsAsyncEnumerable : System.Net.Http.HttpContent * System.Text.Json.Serialization.Metadata.JsonTypeInfo<'Value> * System.Threading.CancellationToken -> System.Collections.Generic.IAsyncEnumerable<'Value>
<Extension()>
Public Function ReadFromJsonAsAsyncEnumerable(Of TValue) (content As HttpContent, jsonTypeInfo As JsonTypeInfo(Of TValue), Optional cancellationToken As CancellationToken = Nothing) As IAsyncEnumerable(Of TValue)

Paramètres de type

TValue

Type cible vers lequel désérialiser.

Paramètres

content
HttpContent

Contenu à partir duquel lire.

jsonTypeInfo
JsonTypeInfo<TValue>

JsonTypeInfo utilisé pour contrôler le comportement de désérialisation.

cancellationToken
CancellationToken

Retours

IAsyncEnumerable<T> qui représente le corps de la réponse désérialisée.

Exceptions

Le content est null.

Le jeton d’annulation a été annulé. Cette exception est stockée dans la tâche retournée.

S’applique à