Partager via


DefaultHtmlGenerator.GenerateCheckBox Méthode

Définition

Générez un <élément input type="checkbox ».../> .

public:
 virtual Microsoft::AspNetCore::Mvc::Rendering::TagBuilder ^ GenerateCheckBox(Microsoft::AspNetCore::Mvc::Rendering::ViewContext ^ viewContext, Microsoft::AspNetCore::Mvc::ViewFeatures::ModelExplorer ^ modelExplorer, System::String ^ expression, Nullable<bool> isChecked, System::Object ^ htmlAttributes);
public virtual Microsoft.AspNetCore.Mvc.Rendering.TagBuilder GenerateCheckBox (Microsoft.AspNetCore.Mvc.Rendering.ViewContext viewContext, Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExplorer modelExplorer, string expression, bool? isChecked, object htmlAttributes);
abstract member GenerateCheckBox : Microsoft.AspNetCore.Mvc.Rendering.ViewContext * Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExplorer * string * Nullable<bool> * obj -> Microsoft.AspNetCore.Mvc.Rendering.TagBuilder
override this.GenerateCheckBox : Microsoft.AspNetCore.Mvc.Rendering.ViewContext * Microsoft.AspNetCore.Mvc.ViewFeatures.ModelExplorer * string * Nullable<bool> * obj -> Microsoft.AspNetCore.Mvc.Rendering.TagBuilder
Public Overridable Function GenerateCheckBox (viewContext As ViewContext, modelExplorer As ModelExplorer, expression As String, isChecked As Nullable(Of Boolean), htmlAttributes As Object) As TagBuilder

Paramètres

viewContext
ViewContext

Le ViewContext instance pour l’étendue actuelle.

modelExplorer
ModelExplorer

ModelExplorer pour expression.

expression
String

Nom de l’expression, relatif au modèle actuel.

isChecked
Nullable<Boolean>

État initial de l’élément de case à cocher.

htmlAttributes
Object

Object qui contient les attributs HTML de l’élément . IDictionary<TKey,TValue> Une instance contenant les attributs HTML.

Retours

Instance TagBuilder pour l’élément <input type="checkbox ».../>.

Implémente

S’applique à