ArrayModelBinder<TElement> Třída

Definice

IModelBinder implementace pro hodnoty vazby matice.

generic <typename TElement>
public ref class ArrayModelBinder : Microsoft::AspNetCore::Mvc::ModelBinding::Binders::CollectionModelBinder<TElement>
public class ArrayModelBinder<TElement> : Microsoft.AspNetCore.Mvc.ModelBinding.Binders.CollectionModelBinder<TElement>
type ArrayModelBinder<'Element> = class
    inherit CollectionModelBinder<'Element>
Public Class ArrayModelBinder(Of TElement)
Inherits CollectionModelBinder(Of TElement)

Parametry typu

TElement

Typ prvků v poli

Dědičnost
ArrayModelBinder<TElement>

Konstruktory

ArrayModelBinder<TElement>(IModelBinder)
Zastaralé.

Tento konstruktor je zastaralý a bude odebrán v budoucí verzi. Doporučená alternativa je přetížení, které také přebírá ILoggerFactory.

Vytvoří nový objekt ArrayModelBinder<TElement>.

ArrayModelBinder<TElement>(IModelBinder, ILoggerFactory)

Vytvoří nový objekt ArrayModelBinder<TElement>.

ArrayModelBinder<TElement>(IModelBinder, ILoggerFactory, Boolean)

Vytvoří nový objekt ArrayModelBinder<TElement>.

ArrayModelBinder<TElement>(IModelBinder, ILoggerFactory, Boolean, MvcOptions)

Vytvoří nový objekt ArrayModelBinder<TElement>.

Vlastnosti

ElementBinder

IModelBinder Získá instance pro prvky kolekce vazeb.

(Zděděno od CollectionModelBinder<TElement>)
Logger

Používá se ILogger k protokolování v tomto pořadači.

(Zděděno od CollectionModelBinder<TElement>)

Metody

AddErrorIfBindingRequired(ModelBindingContext)

ModelError Přidat do ModelState pole if IsBindingRequired.

(Zděděno od CollectionModelBinder<TElement>)
BindModelAsync(ModelBindingContext)

Pokusí se vytvořit vazbu modelu.

(Zděděno od CollectionModelBinder<TElement>)
CanCreateInstance(Type) System.Object.CanCreateInstance(System.Type)
ConvertToCollectionType(Type, IEnumerable<TElement>)

Object Získá přiřaditelné k targetType tomu, který obsahuje členy z collection.

CopyToModel(Object, IEnumerable<TElement>)

Přidá hodnoty z sourceCollection daného .target

CreateEmptyCollection(Type)

Vytvoření přiřaditelného objektu Object targetType.

CreateInstance(Type)

Vytvořte instanci targetType.

(Zděděno od CollectionModelBinder<TElement>)

Platí pro