JsonSerializer.SerializeAsyncEnumerable Método
Definición
Importante
Parte de la información hace referencia a la versión preliminar del producto, que puede haberse modificado sustancialmente antes de lanzar la versión definitiva. Microsoft no otorga ninguna garantía, explícita o implícita, con respecto a la información proporcionada aquí.
Sobrecargas
SerializeAsyncEnumerable<TValue>(PipeWriter, IAsyncEnumerable<TValue>, Boolean, JsonSerializerOptions, CancellationToken)
- Source:
- JsonSerializer.Write.Pipe.cs
[System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
public static System.Threading.Tasks.Task SerializeAsyncEnumerable<TValue>(System.IO.Pipelines.PipeWriter utf8Json, System.Collections.Generic.IAsyncEnumerable<TValue> value, bool topLevelValues = false, System.Text.Json.JsonSerializerOptions? options = default, System.Threading.CancellationToken cancellationToken = default);
public static System.Threading.Tasks.Task SerializeAsyncEnumerable<TValue>(System.IO.Pipelines.PipeWriter utf8Json, System.Collections.Generic.IAsyncEnumerable<TValue> value, bool topLevelValues = false, System.Text.Json.JsonSerializerOptions? options = default, System.Threading.CancellationToken cancellationToken = default);
[<System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")>]
[<System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")>]
static member SerializeAsyncEnumerable : System.IO.Pipelines.PipeWriter * System.Collections.Generic.IAsyncEnumerable<'Value> * bool * System.Text.Json.JsonSerializerOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task
static member SerializeAsyncEnumerable : System.IO.Pipelines.PipeWriter * System.Collections.Generic.IAsyncEnumerable<'Value> * bool * System.Text.Json.JsonSerializerOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function SerializeAsyncEnumerable(Of TValue) (utf8Json As PipeWriter, value As IAsyncEnumerable(Of TValue), Optional topLevelValues As Boolean = false, Optional options As JsonSerializerOptions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task
Parámetros de tipo
- TValue
Parámetros
- utf8Json
- PipeWriter
- value
- IAsyncEnumerable<TValue>
- topLevelValues
- Boolean
- options
- JsonSerializerOptions
- cancellationToken
- CancellationToken
Devoluciones
- Atributos
Se aplica a
SerializeAsyncEnumerable<TValue>(PipeWriter, IAsyncEnumerable<TValue>, JsonTypeInfo<TValue>, Boolean, CancellationToken)
- Source:
- JsonSerializer.Write.Pipe.cs
public static System.Threading.Tasks.Task SerializeAsyncEnumerable<TValue>(System.IO.Pipelines.PipeWriter utf8Json, System.Collections.Generic.IAsyncEnumerable<TValue> value, System.Text.Json.Serialization.Metadata.JsonTypeInfo<TValue> jsonTypeInfo, bool topLevelValues = false, System.Threading.CancellationToken cancellationToken = default);
static member SerializeAsyncEnumerable : System.IO.Pipelines.PipeWriter * System.Collections.Generic.IAsyncEnumerable<'Value> * System.Text.Json.Serialization.Metadata.JsonTypeInfo<'Value> * bool * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function SerializeAsyncEnumerable(Of TValue) (utf8Json As PipeWriter, value As IAsyncEnumerable(Of TValue), jsonTypeInfo As JsonTypeInfo(Of TValue), Optional topLevelValues As Boolean = false, Optional cancellationToken As CancellationToken = Nothing) As Task
Parámetros de tipo
- TValue
Parámetros
- utf8Json
- PipeWriter
- value
- IAsyncEnumerable<TValue>
- jsonTypeInfo
- JsonTypeInfo<TValue>
- topLevelValues
- Boolean
- cancellationToken
- CancellationToken
Devoluciones
Se aplica a
SerializeAsyncEnumerable<TValue>(Stream, IAsyncEnumerable<TValue>, Boolean, JsonSerializerOptions, CancellationToken)
[System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")]
[System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")]
public static System.Threading.Tasks.Task SerializeAsyncEnumerable<TValue>(System.IO.Stream utf8Json, System.Collections.Generic.IAsyncEnumerable<TValue> value, bool topLevelValues = false, System.Text.Json.JsonSerializerOptions? options = default, System.Threading.CancellationToken cancellationToken = default);
public static System.Threading.Tasks.Task SerializeAsyncEnumerable<TValue>(System.IO.Stream utf8Json, System.Collections.Generic.IAsyncEnumerable<TValue> value, bool topLevelValues = false, System.Text.Json.JsonSerializerOptions? options = default, System.Threading.CancellationToken cancellationToken = default);
[<System.Diagnostics.CodeAnalysis.RequiresDynamicCode("JSON serialization and deserialization might require types that cannot be statically analyzed and might need runtime code generation. Use System.Text.Json source generation for native AOT applications.")>]
[<System.Diagnostics.CodeAnalysis.RequiresUnreferencedCode("JSON serialization and deserialization might require types that cannot be statically analyzed. Use the overload that takes a JsonTypeInfo or JsonSerializerContext, or make sure all of the required types are preserved.")>]
static member SerializeAsyncEnumerable : System.IO.Stream * System.Collections.Generic.IAsyncEnumerable<'Value> * bool * System.Text.Json.JsonSerializerOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task
static member SerializeAsyncEnumerable : System.IO.Stream * System.Collections.Generic.IAsyncEnumerable<'Value> * bool * System.Text.Json.JsonSerializerOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function SerializeAsyncEnumerable(Of TValue) (utf8Json As Stream, value As IAsyncEnumerable(Of TValue), Optional topLevelValues As Boolean = false, Optional options As JsonSerializerOptions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task
Parámetros de tipo
- TValue
Parámetros
- utf8Json
- Stream
- value
- IAsyncEnumerable<TValue>
- topLevelValues
- Boolean
- options
- JsonSerializerOptions
- cancellationToken
- CancellationToken
Devoluciones
- Atributos
Se aplica a
SerializeAsyncEnumerable<TValue>(Stream, IAsyncEnumerable<TValue>, JsonTypeInfo<TValue>, Boolean, CancellationToken)
public static System.Threading.Tasks.Task SerializeAsyncEnumerable<TValue>(System.IO.Stream utf8Json, System.Collections.Generic.IAsyncEnumerable<TValue> value, System.Text.Json.Serialization.Metadata.JsonTypeInfo<TValue> jsonTypeInfo, bool topLevelValues = false, System.Threading.CancellationToken cancellationToken = default);
static member SerializeAsyncEnumerable : System.IO.Stream * System.Collections.Generic.IAsyncEnumerable<'Value> * System.Text.Json.Serialization.Metadata.JsonTypeInfo<'Value> * bool * System.Threading.CancellationToken -> System.Threading.Tasks.Task
Public Function SerializeAsyncEnumerable(Of TValue) (utf8Json As Stream, value As IAsyncEnumerable(Of TValue), jsonTypeInfo As JsonTypeInfo(Of TValue), Optional topLevelValues As Boolean = false, Optional cancellationToken As CancellationToken = Nothing) As Task
Parámetros de tipo
- TValue
Parámetros
- utf8Json
- Stream
- value
- IAsyncEnumerable<TValue>
- jsonTypeInfo
- JsonTypeInfo<TValue>
- topLevelValues
- Boolean
- cancellationToken
- CancellationToken