InputFormatterContext Construtores

Definição

Sobrecargas

InputFormatterContext(HttpContext, String, ModelStateDictionary, ModelMetadata, Func<Stream,Encoding,TextReader>)

Cria uma nova instância de InputFormatterContext.

InputFormatterContext(HttpContext, String, ModelStateDictionary, ModelMetadata, Func<Stream,Encoding,TextReader>, Boolean)

Cria uma nova instância de InputFormatterContext.

InputFormatterContext(HttpContext, String, ModelStateDictionary, ModelMetadata, Func<Stream,Encoding,TextReader>)

Origem:
InputFormatterContext.cs
Origem:
InputFormatterContext.cs
Origem:
InputFormatterContext.cs

Cria uma nova instância de InputFormatterContext.

public:
 InputFormatterContext(Microsoft::AspNetCore::Http::HttpContext ^ httpContext, System::String ^ modelName, Microsoft::AspNetCore::Mvc::ModelBinding::ModelStateDictionary ^ modelState, Microsoft::AspNetCore::Mvc::ModelBinding::ModelMetadata ^ metadata, Func<System::IO::Stream ^, System::Text::Encoding ^, System::IO::TextReader ^> ^ readerFactory);
public InputFormatterContext (Microsoft.AspNetCore.Http.HttpContext httpContext, string modelName, Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary modelState, Microsoft.AspNetCore.Mvc.ModelBinding.ModelMetadata metadata, Func<System.IO.Stream,System.Text.Encoding,System.IO.TextReader> readerFactory);
new Microsoft.AspNetCore.Mvc.Formatters.InputFormatterContext : Microsoft.AspNetCore.Http.HttpContext * string * Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary * Microsoft.AspNetCore.Mvc.ModelBinding.ModelMetadata * Func<System.IO.Stream, System.Text.Encoding, System.IO.TextReader> -> Microsoft.AspNetCore.Mvc.Formatters.InputFormatterContext
Public Sub New (httpContext As HttpContext, modelName As String, modelState As ModelStateDictionary, metadata As ModelMetadata, readerFactory As Func(Of Stream, Encoding, TextReader))

Parâmetros

httpContext
HttpContext

O HttpContext para a operação atual.

modelName
String

O nome do modelo.

modelState
ModelStateDictionary

O ModelStateDictionary para erros de gravação.

metadata
ModelMetadata

O ModelMetadata do modelo a ser desserializado.

readerFactory
Func<Stream,Encoding,TextReader>

Um delegado que pode criar um TextReader para o corpo da solicitação.

Aplica-se a

InputFormatterContext(HttpContext, String, ModelStateDictionary, ModelMetadata, Func<Stream,Encoding,TextReader>, Boolean)

Origem:
InputFormatterContext.cs
Origem:
InputFormatterContext.cs
Origem:
InputFormatterContext.cs

Cria uma nova instância de InputFormatterContext.

public:
 InputFormatterContext(Microsoft::AspNetCore::Http::HttpContext ^ httpContext, System::String ^ modelName, Microsoft::AspNetCore::Mvc::ModelBinding::ModelStateDictionary ^ modelState, Microsoft::AspNetCore::Mvc::ModelBinding::ModelMetadata ^ metadata, Func<System::IO::Stream ^, System::Text::Encoding ^, System::IO::TextReader ^> ^ readerFactory, bool treatEmptyInputAsDefaultValue);
public InputFormatterContext (Microsoft.AspNetCore.Http.HttpContext httpContext, string modelName, Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary modelState, Microsoft.AspNetCore.Mvc.ModelBinding.ModelMetadata metadata, Func<System.IO.Stream,System.Text.Encoding,System.IO.TextReader> readerFactory, bool treatEmptyInputAsDefaultValue);
new Microsoft.AspNetCore.Mvc.Formatters.InputFormatterContext : Microsoft.AspNetCore.Http.HttpContext * string * Microsoft.AspNetCore.Mvc.ModelBinding.ModelStateDictionary * Microsoft.AspNetCore.Mvc.ModelBinding.ModelMetadata * Func<System.IO.Stream, System.Text.Encoding, System.IO.TextReader> * bool -> Microsoft.AspNetCore.Mvc.Formatters.InputFormatterContext
Public Sub New (httpContext As HttpContext, modelName As String, modelState As ModelStateDictionary, metadata As ModelMetadata, readerFactory As Func(Of Stream, Encoding, TextReader), treatEmptyInputAsDefaultValue As Boolean)

Parâmetros

httpContext
HttpContext

O HttpContext para a operação atual.

modelName
String

O nome do modelo.

modelState
ModelStateDictionary

O ModelStateDictionary para erros de gravação.

metadata
ModelMetadata

O ModelMetadata do modelo a ser desserializado.

readerFactory
Func<Stream,Encoding,TextReader>

Um delegado que pode criar um TextReader para o corpo da solicitação.

treatEmptyInputAsDefaultValue
Boolean

Um valor para a TreatEmptyInputAsDefaultValue propriedade .

Aplica-se a